Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with doc/scripts/GMT_movie_progress.sh on Windows #6007

Open
maxrjones opened this issue Nov 15, 2021 · 1 comment
Open

Issues with doc/scripts/GMT_movie_progress.sh on Windows #6007

maxrjones opened this issue Nov 15, 2021 · 1 comment
Labels
bug Something isn't working

Comments

@maxrjones
Copy link
Member

Description of the problem

This test often fails with something like:

Set GMT_SESSION_NAME = 8917
GPL Ghostscript 9.50: Unrecoverable error, exit code 1

When the failing tests are rerun, it fails twice more because the temporary assembly directory (here /tmp/junk) only gets deleted when the commands all run successfully:

 The following tests FAILED:
	126 - doc/scripts/GMT_movie_progress.sh (Failed)
Errors while running CTest
+ ctest --output-on-failure --force-new-ctest-process -j4 --timeout 480 --rerun-failed
Test project D:/a/gmt/gmt/build
    Start 126: doc/scripts/GMT_movie_progress.sh
1/1 Test #126: doc/scripts/GMT_movie_progress.sh ...***Failed    1.70 sec
Set GMT_SESSION_NAME = 53562
Error: ERROR]: Working directory /tmp/junk already exist and -Z was not specified - exiting
ERROR: D:/a/gmt/gmt/build/test/gmtest:82
memtrack errors: 0
exit status: 1

Is there a way to proceed with the cleanup if -Z is set but the script does not execute successfully?

@maxrjones maxrjones added the bug Something isn't working label Nov 15, 2021
@PaulWessel
Copy link
Member

Yes, we should clean up that directory before exiting. I will see if I can add that code to the Return macro.
Another improvement to movie and batch would be to allow for a random working directory. To be backwards compatible we will need a modifier I think, maybe -W+t for temporary directory? This will create things like /tmp/tmp_movie_123456 and I believe this TMPDIR will need to be written to the parameter scripts.

PaulWessel added a commit that referenced this issue Nov 15, 2021
See #6007 for motivation.  This PR moves the creation of the cleanup script up front and once we pass the section where the working dir has been created we no longer Return on error but jump to the end of the program so that we can run the cleanup_script before exiting with the error.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants