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

Image not available when uploading to server #942

Merged
merged 1 commit into from
Jan 19, 2022
Merged

Image not available when uploading to server #942

merged 1 commit into from
Jan 19, 2022

Conversation

stefanbrenner
Copy link
Contributor

The current image gets moved into ${WORKING_DIR}/${FULL_FILENAME} before it is uploaded to the server. During the upload the image then cannot be found and an error is thrown.

Solutions

  • I just copied (instead of moved) the image away into ${WORKING_DIR}/${FULL_FILENAME}
  • another solution would be to set ${IMAGE_TO_USE} to ${WORKING_DIR}/${FULL_FILENAME} but then the timestamp within the filename is lost.

@AndreasLMeg
Copy link
Collaborator

@stefanbrenner: Thank you, @EricClaeys should make the review.
(bug since yesterday ? #939 (comment))

@linuxkidd linuxkidd merged commit 6b51744 into AllskyTeam:master Jan 19, 2022
@linuxkidd
Copy link
Collaborator

thx @stefanbrenner .. appreciate finding and fixing this.

@linuxkidd linuxkidd mentioned this pull request Jan 19, 2022
@linuxkidd linuxkidd linked an issue Jan 19, 2022 that may be closed by this pull request
@hpservertech
Copy link

Confirmed as working now

@EricClaeys
Copy link
Collaborator

@linuxkidd, @AndreasLMeg, @hpservertech, @stefanbrenner
Although doing a cp "${IMAGE_TO_USE}" "${WORKING_DIR}/${FULL_FILENAME}" works, it's not an ideal solution since it executes another cp when only a mv is eventually needed. And since SD cards have a limited number of writes, we're trying to minimize writes.

For the case where daytime images ARE saved, the original code's

mv "${IMAGE_TO_USE}" "${WORKING_DIR}/${FULL_FILENAME}"

worked since the subsequent upload used $FINAL_FILE (the one in allsky/images/DATE).

I'm working on an update to saveImage.sh that will avoid the "cp". When it's ready for testing, I'll let you know.

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.

8.3 Upload issue
5 participants