# Fix Up Redirections with Python command

**URL:** <https://forums.unrealengine.com/t/fix-up-redirections-with-python-command/1272254>\
**Category:** Editor Scripting\
**Tags:** unreal-engine, question\
**Created:** [August 25, 2023, 2:12pm UTC](https://forums.unrealengine.com/t/fix-up-redirections-with-python-command/1272254 "2023-08-25T14:12:35Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![9Evgeny9](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@9Evgeny9](https://forums.unrealengine.com/u/9Evgeny9)\
**Post date:** [August 25, 2023, 2:12pm UTC](https://forums.unrealengine.com/t/fix-up-redirections-with-python-command/1272254/1 "2023-08-25T14:12:35Z")

</div>

My workflow is following

1. Move asset (by renaming) my\_asset from folder A to folder B.
2. Create asset (by duplicating) with the same name (my\_asset) in folder A.

```auto
unreal.EditorAssetLibrary.rename_asset(assetA_path, assetA_newpath)
unreal.EditorAssetLibrary.duplicate_asset(some_path, assetA_path)

```

Moving asset is successfully, but creating asset is failure.

> LogEditorAssetSubsystem: Error: DuplicateAsset failed: The destination path ‘/Game/MetaHumans/EvgenyZ/Custom\_avatar/Evgeny\_custom.Evgeny\_custom’ is not valid. An asset already exists at this location.

in windows explorer i see “assetA.uasset” file with size of 3kb.  
It Disappears after RMB on folder and “Fix up redirections”. And my workflow can work.

The question is:  
How to execute “Fix up redirections” with Python?

---

<div class="post-metadata">

**Author:** ![Gloynus](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/gloynus/32/578459_2.png) [@Gloynus](https://forums.unrealengine.com/u/Gloynus)\
**Post date:** [December 9, 2024, 1:32pm UTC](https://forums.unrealengine.com/t/fix-up-redirections-with-python-command/1272254/2 "2024-12-09T13:32:02Z")

</div>

You still haven’t been able to find an answer to that question?
