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

Clean up ORAS code #701

Open
5 tasks
isc-shuliu opened this issue Jan 10, 2025 · 0 comments
Open
5 tasks

Clean up ORAS code #701

isc-shuliu opened this issue Jan 10, 2025 · 0 comments
Labels

Comments

@isc-shuliu
Copy link
Collaborator

There is some code in ORAS that can be further improved for clarity.

  • Method naming: I think Python methods don't have to use the "Py" suffix. They are first class methods just like ObjectScript methods. Thoughts?
  • Argument naming. Some arguments are misleading, such as package are sometimes actually a concatenation of package:tag. Also, tag and version are no longer synonyms after V0.10.x fix translate semver tags #700. We need to be explicit about that.
  • Inconsistent return type. Some python methods can return either a tuple or a comma-separated string based on an input flag. This is convenient for now but harder to maintain in the future.
  • Redirection of stdout/stderr can wrapped with context managers for readability
  • Misc changes. Some code be made more pythonic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant