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

BUG: ztf_functions.py should be importable even when there is no access permission to the s3 bucket #332

Closed
zoghbi-a opened this issue Sep 16, 2024 · 5 comments · Fixed by #333
Assignees
Labels
bug Something isn't working use case: light curves

Comments

@zoghbi-a
Copy link
Contributor

ztf_functions.py accesses a remote bucket during import. This is probably not a good idea as it prone to failure when the permission to the bucket is not setup correctly.

@zoghbi-a zoghbi-a added bug Something isn't working use case: light curves labels Sep 16, 2024
@zoghbi-a zoghbi-a changed the title Imorting ztf_functions.py fails when there no access permission to the s3 bucket BUG: Imorting ztf_functions.py fails when there no access permission to the s3 bucket Sep 16, 2024
@bsipocz bsipocz added the duplicate This issue or pull request already exists label Sep 16, 2024
@bsipocz
Copy link
Member

bsipocz commented Sep 16, 2024

This problem has already been captured in #311. Note, the ZTF access issue cannot be remedied yet as it is not yet have an ODR place.

I would go ahead and close this as a duplicate, but if you have an idea for a suitable workaround, feel free to reopen (I don't think it's any particularly useful to skip ZTF and yet create the light curves when there is no access to the bucket as in practice that dataset is heavily used in all the follow-up notebooks).

@bsipocz bsipocz closed this as completed Sep 16, 2024
@zoghbi-a
Copy link
Contributor Author

zoghbi-a commented Sep 16, 2024

I agree that skipping ztf is not an option. I was thinking just move it from the import section. If that is going to be done as part of #311, then feel free to close this.

@bsipocz
Copy link
Member

bsipocz commented Sep 16, 2024

OK, that makes a lot of sense, reopening it for tracking the python script importability rather than the bucket issue.

@bsipocz bsipocz reopened this Sep 16, 2024
@bsipocz bsipocz changed the title BUG: Imorting ztf_functions.py fails when there no access permission to the s3 bucket BUG: ztf_functions.py should be importable even when there is no access permission to the s3 bucket Sep 16, 2024
@bsipocz bsipocz self-assigned this Sep 16, 2024
@bsipocz bsipocz removed the duplicate This issue or pull request already exists label Sep 16, 2024
@troyraen
Copy link
Contributor

@bsipocz is it ok if I fix this? This module uses multiprocessing internally which complicates this a bit, but I think I see how to lazy load that variable in an efficient way.

@bsipocz
Copy link
Member

bsipocz commented Sep 16, 2024

Sure! I was only planning to move the quoted line into a function body, so it's not touched at import time, but anything would work really.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working use case: light curves
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants