AppImage / AppImage/AppImageKit
Tempdir conflict with `--appimage-extract-and-run` on parallel runs
- Dominant language
- No language data
- Stars
- 9.4k
- Forks
- 588
- PR merge metrics
- PR metrics pending
Description
When an appimage is run with `--appimage-extract-and-run`, the path is calculated as `$TMPDIR/appimage_extracted_$MD5DIGEST`. This usually works, but it seems there are problems when the same appimage is run in parallel. Likely there is a race condition where one appimage is still running while the other one is removing its files already.
It seems this happened to me in this CI run: https://github.com/lalten/rules_appimage/actions/runs/3085571024/jobs/4989010345 where I added a testing matrix. I think that caused the same appimage to be run in parallel and led to really weird errors.
I wonder if it makes sense to include the date or maybe even just the pid of the process into the tempdir name as well.
Relevant places in the runtime code:
https://github.com/AppImage/AppImageKit/blob/90704a014727556591e396ae8095131d41374a7e/src/runtime.c#L587
https://github.com/AppImage/AppImageKit/blob/90704a014727556591e396ae8095131d41374a7e/src/runtime.c#L690-L696
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.