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

Chore(deps): bump pydantic from 1.10.9 to 2.6.2 #234

Merged
merged 3 commits into from
Mar 3, 2024

Conversation

dependabot[bot]
Copy link
Contributor

@dependabot dependabot bot commented on behalf of github Feb 26, 2024

Bumps pydantic from 1.10.9 to 2.6.2.

Release notes

Sourced from pydantic's releases.

v2.6.2 2024-02-23

v2.6.2 (2024-02-23)

What's Changed

Packaging

Fixes

Full Changelog: pydantic/pydantic@v2.6.1...v2.6.2/

v2.6.1 2024-02-05

v2.6.1 (2024-02-05)

What's Changed

Packaging

Fixes

Full Changelog: pydantic/pydantic@v2.6.0...v2.6.1/

v2.6.0 2024-01-29

v2.6.0 (2024-01-29)

GitHub release

The code released in v2.6.0 is practically identical to that of v2.6.0b1.

What's Changed

Packaging

... (truncated)

Changelog

Sourced from pydantic's changelog.

v2.6.2 (2024-02-23)

GitHub release

What's Changed

Packaging

Fixes

v2.6.1 (2024-02-05)

GitHub release

What's Changed

Packaging

Fixes

v2.6.0 (2024-01-23)

GitHub release

The code released in v2.6.0 is practically identical to that of v2.6.0b1.

What's Changed

Packaging

... (truncated)

Commits
  • 511d862 fixing test
  • 0a2eee8 fix number
  • 8668927 Upgrade pydantic-core to 2.16.3 (#8879)
  • 18433ee prep for 2.6.2, reformatting
  • cf822bd prep for 2.6.1 release
  • fa8acbb Version bump for pydantic 2.16.2 (#8717)
  • 2d812a8 Reverting problematic fix from 2.6 release, fixing schema building bug (#8718)
  • 8e790d5 Fix unsupported types bug with plain validator (#8710)
  • aac1069 Fix regression in core schema generation for indirect definition references (...
  • 43327d8 Fix inheriting annotations in dataclasses (#8679)
  • Additional commits viewable in compare view

Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options

You can trigger Dependabot actions by commenting on this PR:

  • @dependabot rebase will rebase this PR
  • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
  • @dependabot merge will merge this PR after your CI passes on it
  • @dependabot squash and merge will squash and merge this PR after your CI passes on it
  • @dependabot cancel merge will cancel a previously requested merge and block automerging
  • @dependabot reopen will reopen this PR if it is closed
  • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
  • @dependabot show <dependency name> ignore conditions will show all of the ignore conditions of the specified dependency
  • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
  • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)

Summary by CodeRabbit

  • Refactor
    • Enhanced .gitignore configurations for better file management.
    • Updated Pydantic model configurations for improved data handling.
    • Modified class methods and decorators in CLI types for enhanced validation processes.
    • Improved Kubernetes types with inheritance and type adjustments for better data structure management.
    • Updated JSON serialization process for more efficient data handling.

Bumps [pydantic](https://github.com/pydantic/pydantic) from 1.10.9 to 2.6.2.
- [Release notes](https://github.com/pydantic/pydantic/releases)
- [Changelog](https://github.com/pydantic/pydantic/blob/main/HISTORY.md)
- [Commits](pydantic/pydantic@v1.10.9...v2.6.2)

---
updated-dependencies:
- dependency-name: pydantic
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
@dependabot dependabot bot added dependencies Pull requests that update a dependency file python Pull requests that update Python code labels Feb 26, 2024
Copy link

coderabbitai bot commented Feb 26, 2024

Walkthrough

The recent updates encompass a range of improvements, including enhancements to file ignoring patterns, modification of Pydantic model configurations, updates to class method decorators and parameters in CLI types, inheritance and default value adjustments in Kubernetes types, and a refinement in JSON serialization logic. These changes aim to increase flexibility, maintainability, and efficiency across the codebase.

Changes

Files Change Summary
.gitignore Modified to ignore files starting with .testmondata.
komposer/types/... Updated Pydantic model configurations; replaced validator with field_validator; modified method parameters and decorators.
komposer/types/kubernetes.py Added ABC inheritance, modified default values and type unions.
komposer/utils.py Altered JSON serialization logic to use model_dump_json.

🐇✨
In code's vast garden, changes bloom,
Where models grow and functions groom.
.gitignore's seeds, sown with care,
Types and utils, improved, fair.
Oh, how the bytes dance and weave,
In this digital tapestry we conceive.
🌟🐰

Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share

Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit-tests for this file.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit tests for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository from git and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit tests.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger a review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • The JSON schema for the configuration file is available here.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/coderabbit-overrides.v2.json

CodeRabbit Discord Community

Join our Discord Community to get help, request features, and share feedback.

Repository owner deleted a comment from coderabbitai bot Mar 3, 2024
@expobrain
Copy link
Owner

@coderabbitai review

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review Status

Actionable comments generated: 0

Configuration used: CodeRabbit UI

Commits Files that changed from the base of the PR and between 2fc3507 and 4e2b087.
Files ignored due to path filters (2)
  • poetry.lock is excluded by: !**/*.lock
  • pyproject.toml is excluded by: !**/*.toml
Files selected for processing (5)
  • .gitignore (1 hunks)
  • komposer/types/base.py (1 hunks)
  • komposer/types/cli.py (2 hunks)
  • komposer/types/kubernetes.py (4 hunks)
  • komposer/utils.py (1 hunks)
Files skipped from review due to trivial changes (1)
  • .gitignore
Additional comments: 9
komposer/types/base.py (2)
  • 12-12: The introduction of model_config = ConfigDict(frozen=True) in ImmutableBaseModel correctly sets the model to be immutable. This is a good practice for models that should not change after creation, enhancing the predictability and safety of the code.
  • 16-16: The addition of model_config = ConfigDict(frozen=True, alias_generator=to_camel) in CamelCaseImmutableBaseModel not only makes the model immutable but also specifies an alias generator for field names. This is a significant improvement for consistency in JSON representation, especially when integrating with systems that use camelCase naming conventions.
komposer/utils.py (1)
  • 68-68: The modification to use model_dump_json(by_alias=True) instead of json.loads for serializing Pydantic models to JSON is a significant improvement. This method respects model configurations such as aliasing, which is crucial for maintaining consistency in serialized data, especially when working with external systems or APIs that expect specific naming conventions.
komposer/types/cli.py (3)
  • 47-48: Replacing validator with field_validator for project_name in Context class is a precise change that aligns with Pydantic's recommendations for field-specific validations. This ensures that the validation logic is tightly coupled with the specific field it's intended for, improving readability and maintainability.
  • 55-56: The use of field_validator for branch_name and making the method a class method is appropriate. It ensures that the validation logic is applied directly to the branch_name field and allows for the use of class-level logic, which is beneficial for validations that do not depend on instance-specific data.
  • 62-63: Similarly, applying field_validator to repository_name and converting the method to a class method is a good practice. It centralizes the validation logic for repository_name, making the code more organized and easier to understand.
komposer/types/kubernetes.py (3)
  • 3-3: Importing ABC from abc and modifying the Item class to inherit from ABC is a strategic decision that enforces the abstract nature of Item. This ensures that Item serves as a base class and cannot be instantiated directly, which is a good practice for clarity and preventing misuse in a class hierarchy.
  • 121-121: Setting a default value of None for value in the EnvironmentVariable class is a thoughtful change. It allows for the creation of environment variables without explicitly setting a value, which can be useful in scenarios where the value is to be determined or populated later.
  • 259-259: Changing the type of items in the List class to a union of specific types (ConfigMap, Deployment, Service, Ingress) is an excellent improvement. It enhances type safety by ensuring that only instances of these types can be added to the items list, reducing the risk of runtime errors and improving code readability.

@expobrain expobrain merged commit 2059668 into main Mar 3, 2024
6 checks passed
@expobrain expobrain deleted the dependabot/pip/pydantic-2.6.2 branch March 3, 2024 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file python Pull requests that update Python code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant