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 json_load method to StoredFile #1485

Merged
merged 6 commits into from
Nov 14, 2024
Merged

Conversation

jberends
Copy link
Member

@jberends jberends commented Nov 14, 2024

Fixes #

Checklist:

  • My code follows the pykechain style
    • I added type hinting to all functions
    • I added documentation for all public functions
    • I locally used tox to check for dists and docs errors
    • My code passes the pep8 and flake8 linting checks and no warnings
    • I removed unused imports, using Code > Optimize Imports in PyCharm
    • I used black to format the new code
  • I have added tests that prove my fix is effective or that my feature works
    • I committed fresh test cassettes
    • I have proper test coverage (don't decline the coverage of the test)
  • I asked another teammate to review the code
  • I update the Changelog.md with the appropriate changes.

Jochem Berends added 3 commits November 14, 2024 15:32
Introduced a new `SOURCE` size to `StoredFileSize` enum and updated the `_download` method to accommodate this new size. Additionally, added a `json_load` method to `StoredFile` to download and deserialize JSON data, ensuring compatibility with attachment properties.
This commit introduces a new test cassette for the `TestStoredFilesDownload.test_upload_and_download_of_json_file` test case. The cassette records HTTP interactions for the JSON file upload and download process, aiding in consistent and reliable test results.
The `json_load()` method entry was updated to include issue reference #1485 in the UNRELEASED section. This helps in tracking the change and linking it to the discussed issue for better documentation.
@jberends jberends self-assigned this Nov 14, 2024
@jberends jberends changed the title Add SOURCE size and json_load method to StoredFile Add json_load method to StoredFile Nov 14, 2024
jberends and others added 3 commits November 14, 2024 15:56
Updated the docstring in the `_download` method for clarity and conciseness. This change ensures that the description aligns better with standard documentation practices and improves readability.
@jberends jberends merged commit ac37528 into main Nov 14, 2024
8 checks passed
@jberends jberends deleted the add-json-download-of-stored-file branch November 14, 2024 15:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

align the StoredFile interface with the AttachmentProperty file interface.
1 participant