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

Api refactoring #208

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

Api refactoring #208

wants to merge 3 commits into from

Conversation

wintamute
Copy link

What do these changes do?

This PR adds a new low-level and high-level API, as discussed in #203

Currently only Images and Containers are implemented

Are there changes in behavior for the user?

All existing code is untouched, so there should be no changes in existing code

Related issue number

#203

Checklist

  • I think the code is well written
  • Unit tests for the changes exist
  • Documentation reflects the changes
  • If you provide code modification, please add yourself to CONTRIBUTORS.txt
    • The format is <Name> <Surname>.
    • Please keep alphabetical order, the file is sorted by names.
  • Add a new news fragment into the changes folder
    • name it <issue_id>.<type> for example (588.bug)
    • if you don't have an issue_id change it to the pr id after creating the pr
    • ensure type is one of the following:
      • .feature: Signifying a new feature.
      • .bugfix: Signifying a bug fix.
      • .doc: Signifying a documentation improvement.
      • .removal: Signifying a deprecation or removal of public API.
      • .misc: A ticket has been closed, but it is not of interest to users.
    • Make sure to use full sentences with correct case and punctuation, for example: "Fix issue with non-ascii contents in doctest text files."

@barrachri
Copy link

@wintamute sorry for the delay, I will try to give you a feedback during the next week!

@wintamute
Copy link
Author

@barrachri OK, I was planning on pushing another commit, fixing flake issues and one py3.5 incompatibility, it also took me longer than expected. But any feedback is appreciated

@CLAassistant

This comment has been minimized.

@achimnol
Copy link
Member

achimnol commented May 21, 2024

I think the overall rationale of the approach looks sane:

  • Having explicit DTO (data-transfer objects) with explicit schema
  • Introducing hierarchical sub-package structure to better group the codes

though it's now 2024 and we need to apply new conventions such as the black code style, etc.

I'd like to keep the direction for the future, using pydantic or msgspec to add typed DTOs. However, my time resources are limited in the times other than PyCon, so it is welcome to resubmit the PR with latest CI conformance and updated practices.

Thanks!

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.

5 participants