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

Add try-except blocks to handle JSON decoding errors in Zenodo scripts. #560

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

github-actions[bot]
Copy link
Contributor

This message was generated by git-bob (version: 0.16.0, model: github_models:gpt-4o, log), an experimental AI-based assistant. It can make mistakes and has limitations. Check its messages carefully.

To resolve issue #559, I have added try-except blocks to handle potential JSON decoding errors, allowing processes in for-loops to continue even if an error occurs. Specifically, in scripts/auto-add-from-zenodo-communities.py, a try-except block was introduced around the response.json() call to handle requests.exceptions.JSONDecodeError. Similarly, in scripts/generate_link_lists.py, an except block for json.JSONDecodeError ensures graceful handling by returning an empty dictionary if decoding fails.

closes #559

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.

Error in script.
0 participants