Repository navigation
Fix dependencies #553
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
Fix dependencies #553
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
This file was deleted.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -16,6 +16,7 @@ | |
|
|
||
| IAEA_URL = r"https://github.com/IAEA-NDS/open-benchmarks/archive/main.zip" | ||
| RAW_DATA_GITHUB_URL = r"https://github.com/JADE-V-V/JADE-RAW-RESULTS/archive/main.zip" | ||
| GITLAB_TIMEOUT = 30 # seconds | ||
|
|
||
|
|
||
| def _fetch_from_git( | ||
|
|
@@ -90,13 +91,22 @@ def fetch_from_gitlab( | |
| extracted_folder: Pathlike | bool | ||
| path to the extracted folder. False if the download was not successful. | ||
| """ | ||
| gl = gitlab.Gitlab(url=url, private_token=authorization_token, ssl_verify=False) | ||
| gl = gitlab.Gitlab( | ||
| url=url, | ||
| private_token=authorization_token, | ||
| ssl_verify=False, | ||
| timeout=GITLAB_TIMEOUT, | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Handle timeouts during the full GitLab fetch. The new timeout applies to project listing and archive download, but the
|
||
| ) | ||
| try: | ||
| gl.auth() | ||
| except gitlab.exceptions.GitlabAuthenticationError as e: | ||
| logger.error("Gitlab authentication failed") | ||
| logger.error(e) | ||
| return False | ||
| except requests.exceptions.RequestException as e: | ||
| logger.error(f"Could not connect to {url}") | ||
| logger.error(e) | ||
| return False | ||
|
|
||
| # select the correct project | ||
| found = False | ||
|
|
@@ -125,6 +135,7 @@ def _install_data(fetch_folder: str | os.PathLike, install_folder: str | os.Path | |
| os.path.join(install_folder, item), | ||
| ) | ||
|
|
||
|
|
||
| def _install_standard_folder_structure( | ||
| extracted_folder: str | os.PathLike, | ||
| inputs_root: PathLike, | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Presume intentional.. but should we pin to a version to avoid drift in linting etc?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah it was intentional since ruff iterates pretty fast on v0.X releases... let's see, if it starts to be an issue we'll cap it.