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

Reduce annotation/instrument api calls when posting sources #487

Merged
merged 1 commit into from
Sep 12, 2023

Conversation

bfhealy
Copy link
Collaborator

@bfhealy bfhealy commented Sep 12, 2023

This PR reduces api calls to Fritz when posting new sources. Specifically, the code checks for exiting period annotations before sending a POST request, and it queries current instruments once rather than on a per-source basis.

Also, two rarely-used functions are moved to the bottom of the file.

@bfhealy bfhealy temporarily deployed to Integrate Pull Request September 12, 2023 19:18 — with GitHub Actions Inactive
@bfhealy bfhealy temporarily deployed to Integrate Pull Request September 12, 2023 19:18 — with GitHub Actions Inactive
Copy link
Collaborator

@mcoughlin mcoughlin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@bfhealy bfhealy merged commit 7d163a8 into ZwickyTransientFacility:main Sep 12, 2023
6 checks passed
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.

2 participants