[GH-ISSUE #1] Rerunning Builds fails due to file conflict #3

Closed
opened 2026-02-26 12:20:09 +03:00 by kerem · 3 comments
Owner

Originally created by @CSec0ps on GitHub (Feb 22, 2018).
Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/1

Nice work with this project! I've encountered a problem though which occurs if you rerun the build, and it's because it tries to move the executable without checking if it's already present in output/. Consequently, it hits the following exception:

image

Which occurs at line 44 in the moveProject() method of run.py, here:

image

You could automatically clear the exe everytime from output/ which would solve the problem.. but I can see some cases where you might want the user to confirm this so previous builds aren't lost.

Originally created by @CSec0ps on GitHub (Feb 22, 2018). Original GitHub issue: https://github.com/brentvollebregt/auto-py-to-exe/issues/1 Nice work with this project! I've encountered a problem though which occurs if you rerun the build, and it's because it tries to move the executable without checking if it's already present in output/. Consequently, it hits the following exception: ![image](https://user-images.githubusercontent.com/22727993/36538187-56cf3312-17ca-11e8-876f-9b4b5571658a.png) Which occurs at line 44 in the moveProject() method of run.py, here: ![image](https://user-images.githubusercontent.com/22727993/36538234-7f38f022-17ca-11e8-9cc4-e354df076cf6.png) You could automatically clear the exe everytime from output/ which would solve the problem.. but I can see some cases where you might want the user to confirm this so previous builds aren't lost.
kerem closed this issue 2026-02-26 12:20:09 +03:00
Author
Owner

@brentvollebregt commented on GitHub (Feb 22, 2018):

I knew of this but haven't quite had time to implement. I have two methods to fix this in my head:

  • Warn the user of a file conflict when hitting the compile button and overwrite (provide a dialog which allows to cancel)
  • Rename the output file/folder with something like '(1)', '(2)' or appending the date/time.

Which do you feel would be most suitable?

<!-- gh-comment-id:367831854 --> @brentvollebregt commented on GitHub (Feb 22, 2018): I knew of this but haven't quite had time to implement. I have two methods to fix this in my head: - Warn the user of a file conflict when hitting the compile button and overwrite (provide a dialog which allows to cancel) - Rename the output file/folder with something like '(1)', '(2)' or appending the date/time. Which do you feel would be most suitable?
Author
Owner

@CSec0ps commented on GitHub (Feb 22, 2018):

I'd say the first. Personally, I tend to run a build then make a few changes, run another build etc. so I could see the latter option resulting in a directory with a significant amount of exes.

The advantage of having a GUI however is that you could implement both, or combine the current setup with one or both of those methods, and let the user decide ;-)

<!-- gh-comment-id:367833320 --> @CSec0ps commented on GitHub (Feb 22, 2018): I'd say the first. Personally, I tend to run a build then make a few changes, run another build etc. so I could see the latter option resulting in a directory with a significant amount of exes. The advantage of having a GUI however is that you could implement both, or combine the current setup with one or both of those methods, and let the user decide ;-)
Author
Owner

@brentvollebregt commented on GitHub (Feb 23, 2018):

Hopefully my latest commit 957daf66dd has fixed this.
Thank you very much for reporting this.

<!-- gh-comment-id:367880231 --> @brentvollebregt commented on GitHub (Feb 23, 2018): Hopefully my latest commit 957daf66dd78127ea0c07d1e2b8247557123ccdc has fixed this. Thank you very much for reporting this.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/auto-py-to-exe#3
No description provided.