Skip to content

Commit

Permalink
[MAINT] Update pydantic to >=2.0 (#985)
Browse files Browse the repository at this point in the history
Co-authored-by: sophia <scastellarin@quansight.com>
  • Loading branch information
peytondmurray and soapy1 authored Nov 22, 2024
1 parent 794e2ae commit 20d849b
Show file tree
Hide file tree
Showing 13 changed files with 222 additions and 148 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ def action_solve_lockfile(
lockfile_filename = pathlib.Path.cwd() / "conda-lock.yaml"

with environment_filename.open("w") as f:
json.dump(specification.dict(), f)
json.dump(specification.model_dump(), f)

context.log.info(
"Note that the output of `conda config --show` displayed below only reflects "
Expand Down Expand Up @@ -82,7 +82,7 @@ def action_save_lockfile(
):
# Note: this calls dict on specification so that the version field is
# part of the output
lockfile = specification.dict()["lockfile"]
lockfile = specification.model_dump()["lockfile"]
lockfile_filename = pathlib.Path.cwd() / "conda-lock.yaml"

with lockfile_filename.open("w") as f:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def action_install_specification(
):
environment_filename = pathlib.Path.cwd() / "environment.yaml"
with environment_filename.open("w") as f:
json.dump(specification.dict(), f)
json.dump(specification.model_dump(), f)

command = [
conda_command,
Expand Down
Loading

0 comments on commit 20d849b

Please sign in to comment.