# Renaming file sometimes fails

**URL:** <https://forum.katalon.com/t/renaming-file-sometimes-fails/64543>\
**Category:** Bug Report\
**Tags:** bugs-report, katalon-studio\
**Created:** [April 23, 2022, 12:33am UTC](https://forum.katalon.com/t/renaming-file-sometimes-fails/64543 "2022-04-23T00:33:28Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![sbrod](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/sbrod/32/20464_2.png) [@sbrod](https://forum.katalon.com/u/sbrod)\
**Post date:** [April 23, 2022, 12:33am UTC](https://forum.katalon.com/t/renaming-file-sometimes-fails/64543/1 "2022-04-23T00:33:28Z")

</div>

#### Please let us know what you are using Katalon Studio for?

1. I have currently applied Katalon Studio in my project
2. I’m learning automated test with Katalon Studio

#### How would your work be affected if this issue has not been resolved?

1. It doesn’t affect much, but I believe Katalon team should have this ticket resolved

#### Operating System

Windows 10

#### Katalon Studio Version

8.2.0

#### Katalon Studio logs

[log.txt](https://forum.katalon.com/uploads/short-url/bIRyczLJj6qGyFMfX6fLUiR6loj.txt) (14.5 KB)

#### Steps to reproduce:

Hard to provide because it’s not consistent. Renaming files works more often than not, but certain files will refuse to be renamed (including the classes within them and any references to them). But, to the best that I can, here are the steps:

1. find a keyword script to rename
2. right click, select rename
3. enter a new name and click “ok”
4. observe the file’s name not change

#### Expected Behavior:

File renames, including the class within it (for keywords) and any references to it.

#### Actual Behavior:

File does not get renamed, nor does the class within it or any references to it. This issue may be similar to another post I made [here](http://forum.katalon.com/t/refactor-rename-only-works-once/64118). However, this one does not have any consistency to it, except that when a file does not get renamed that file will never be able to be renamed (except manually by editing the file itself). Additionally, unlike the linked issue, this one did have a consistent log presence (MalformedTreeException: Overlapping text edits).

Restarting does not correct the issue. There are also no name conflicts, as the new name I’ve chosen does not appear anywhere in the entire project.

---

<div class="post-metadata">

**Author:** ![kazurayam](https://dub1.discourse-cdn.com/katalon/user_avatar/forum.katalon.com/kazurayam/32/333_2.png) [@kazurayam](https://forum.katalon.com/u/kazurayam)\
**Post date:** [April 23, 2022, 4:35am UTC](https://forum.katalon.com/t/renaming-file-sometimes-fails/64543/2 "2022-04-23T04:35:13Z")

</div>

I concur. Katalon Studio has many faults in renaming files/directories/packages. For example:

> [@Script code vanished when a test case is renamed](http://forum.katalon.com/t/v8-3-0beta-script-code-vanished-when-test-case-is-renamed/63016):
>
> Katalon Studio v8.3.0.beta macOS Monterey 12.2.1 I created a GitHub project where you can see the bug reproduced. step1 I created a script [Test Case/sub/TC1](https://github.com/kazurayam/CodeVanishedWhenTestCaseRenamed/blob/step1/Scripts/sub/TC1/Script1646221324643.groovy), this had no problem step2 I moved the script to [Test Cases/sub/subsub/TC1](https://github.com/kazurayam/CodeVanishedWhenTestCaseRenamed/blob/step2/Scripts/sub/subsub/TC1/Script1646221324643.groovy), this had no problem step3 I renamed the script to [Test Cases/sub/subsub/Main](https://github.com/kazurayam/CodeVanishedWhenTestCaseRenamed/blob/step3/Scripts/sub/subsub/Main/Script1646222028338.groovy) step4 I renamed the script to Test Cases/sub/subsub/Test, Test Cases/sub/subsub/TestTest, Test Cases/sub/subsub/testesttest ---- and found that the script code has vanished. The Git…

---

<div class="post-metadata">

**Author:** ![system](https://europe1.discourse-cdn.com/katalon/original/3X/d/5/d55596ab02785a255798e87ede769734747b30c4.svg) [@system](https://forum.katalon.com/u/system)\
**Post date:** [April 23, 2023, 4:35am UTC](https://forum.katalon.com/t/renaming-file-sometimes-fails/64543/3 "2023-04-23T04:35:14Z")

</div>

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.
