ventsyv Posted July 4, 2009 Share Posted July 4, 2009 Every now and then I get an "invalid destination file" error when I try to compile. Seems to occur when the file already exists, the compiler fails to overwrite it. I think I've seen that happen even when the file does not exist, it all seems to be very random. Any ideas ?? Link to comment Share on other sites More sharing options...
PsaltyDS Posted July 5, 2009 Share Posted July 5, 2009 Every now and then I get an "invalid destination file" error when I try to compile. Seems to occur when the file already exists, the compiler fails to overwrite it. I think I've seen that happen even when the file does not exist, it all seems to be very random. Any ideas ??Take notes when it happens and get a cleaner description of when it fails. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
Duhhh Posted August 14, 2009 Share Posted August 14, 2009 This happens to me quite often. I haven't been able to figure out what triggers it, and I've tried to duplicate a set of steps that would help me figure out the cause (without success). Once it happens, I have to reboot to clear the problem. It happens from the shell, from the GUI Aut2exe and from the command line. When it happens, the destination file IS there, although it's much larger than expected. When I dismiss the error dialog, the destination file disappears. I tried all compression levels, pack vs. nopack, and it still fails. I even tried compiling a new script, and it usually fails as well (sometimes, compiling a different script will work, but usually not). The only way to get things working again is to reboot. I was hoping that the compiler left a process hung, but running PSTAT before & after the failure didn't offer a clue. It seems easier to recreate from the windows shell, but I have recreated it with both the cmdline and GUI compiler as well. If anyone has an idea on how to trap more info, let me know. I'm running XP SP3, and Autoit 3.3.0.0. Link to comment Share on other sites More sharing options...
Developers Jos Posted August 14, 2009 Developers Share Posted August 14, 2009 (edited) This happens to me quite often. I haven't been able to figure out what triggers it, and I've tried to duplicate a set of steps that would help me figure out the cause (without success). Once it happens, I have to reboot to clear the problem. It happens from the shell, from the GUI Aut2exe and from the command line. When it happens, the destination file IS there, although it's much larger than expected. When I dismiss the error dialog, the destination file disappears. I tried all compression levels, pack vs. nopack, and it still fails. I even tried compiling a new script, and it usually fails as well (sometimes, compiling a different script will work, but usually not). The only way to get things working again is to reboot.I was hoping that the compiler left a process hung, but running PSTAT before & after the failure didn't offer a clue.It seems easier to recreate from the windows shell, but I have recreated it with both the cmdline and GUI compiler as well.If anyone has an idea on how to trap more info, let me know. I'm running XP SP3, and Autoit 3.3.0.0.Are you using UPX and did you check if either UPX or Aut2Exe is still running?The needed reboot could suggest that the file is still open by one of these programs or the program itself is still running.Jos Edited August 14, 2009 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Duhhh Posted August 14, 2009 Share Posted August 14, 2009 After getting the error, I did look for UPX or Aut2Exe, and neither was running (no change in the procs running before and after the error. I just tried to recreate it again. Using the Aut2Exe GUI, I compiled a script with LOW compression and NO UPX. It compiled. I then went to Windows explorer, and using the context menu for the same script, I compiled it, and got an error. I then restarted Aut2Exe and retried the same compile (low compression, no UPX, No X64, No console) and it fails. If I rename the output file, it still fails. So, even though the error seems to indicate that the destination file is locked (as if the compiled script was still running), this isn't the case. For non-UPX, does the compiler write out the uncompressed script, and then re-open it to compress it? That seems to be the point at which it fails. I just ran 4 compiles using Aut2exe (same script, different settings). They all worked. Then I compiled from the shell, and it failed. The settings, and resulting file size are as follows (the failed file disappears once I dismiss the dialog): Compile w/o UPX, compression 0 = file size 714867 compile w/o UPX, compression 4 = file size 684767 compile with UPX, compression 0 = file size 392307 compile with UPX, compression 4 = file size 362207 compile with windows explorer (fails) file size 612864 For that test, I rebooted, and ran nothing else. I didn't run the script after each compile, I just renamed it. Can I get a "debug" version of Aut2exe that can dump out diagnostic messages along the way? That might help figure this out. Link to comment Share on other sites More sharing options...
Developers Jos Posted August 15, 2009 Developers Share Posted August 15, 2009 Have you tried disabling the AV check for the target directory? SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Duhhh Posted August 15, 2009 Share Posted August 15, 2009 Virus scan is guilty. I turned off my auto scan, and did a dozen compiles, they all worked. I turned the scan back on, and the first compile failed. I turned scan back off, and it worked. I know I've seen this with two different AV programs, so I'm wondering why more people haven't seen this. I guess a fix would be to add a spinloop on the failure - if it keeps failing after a couple of seconds, then it's probably dead, but chances are the failure will go away once the scanner releases the file. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now