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

Improvements to process locking #2764

Merged
merged 17 commits into from
Jun 10, 2023
Merged

Conversation

EricClaeys
Copy link
Collaborator

  • Improve the way process locking is done and the aborted messages.
  • The files listing the aborted processes are all in a sub-directory in allsky/tmp.
  • Create a global make_thumbnail() function rather than using the one defined in a scripts/*.sh file. More scripts will use this via another PR.
  • Many other changes that aren't related to process locking, but hey, I was already editing the files...

* Use new "--caused-by" argument to one_instance().
* Specify the time to wait for one_instance() so it doesn't wait too long.
* Set AS_TEMPERATURE_C if not already set and there's a temperature.txt file.
* Only call darkCapture.sh if needed.
* Use new arguments to timelapse.sh.
* Accept new "--caused-by" argument.
* Don't bother checking that the process in the PID_FILE is the specified one.  --process-name is no longer needed.
* Use new $ALLSKY_ABORTS_DIR.
* We're only called if taking dark frames, so no need to check.  This changed indentation.
* saveImage.sh updates AS_TEMPERATURE_C as needed so we don't need to.
* Accept new --lock, --output, and --images argument.
* Updated usage message.
* Updated usage checks.
* Only check for valid DATE and DATE_DIR is needed.
* Accept new --lock, --output, and --images argument.
* Updated usage message.
* Updated usage checks.
* Only check for valid DATE and DATE_DIR is needed.
…rectories.

Also, make sure the PID_FILE is removed.
The prior way of creating the SEQUENCE_DIR files was to use gawk and a couple sub-shells.  The new way which is simpler (and hopefully faster) uses a "while read" loop.
* Pass output timelapse file name to timelapse.sh.
* Use global make_thumbnail() instead of our own version.
* Show preferred "--" arguments instead of "-".
* Change some indentation to make code easier to read.
@EricClaeys EricClaeys merged commit a532b34 into dev Jun 10, 2023
@EricClaeys EricClaeys deleted the Improvements-to-process-locking branch June 10, 2023 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant