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

Bump astral-sh/setup-uv from 4 to 5 #190

Merged
merged 2 commits into from
Jan 16, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .envrc

This file was deleted.

6 changes: 3 additions & 3 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ jobs:
sudo chmod +x ${{ github.workspace }}/bin/minizinc
minizinc --version
- name: Install uv
uses: astral-sh/setup-uv@v4
uses: astral-sh/setup-uv@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
Expand All @@ -60,7 +60,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v4
uses: astral-sh/setup-uv@v5
- name: Set up Python
uses: actions/setup-python@v5
with:
Expand All @@ -79,7 +79,7 @@ jobs:
steps:
- uses: actions/checkout@v4
- name: Install uv
uses: astral-sh/setup-uv@v4
uses: astral-sh/setup-uv@v5
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
Expand Down
8 changes: 5 additions & 3 deletions src/minizinc/instance.py
Original file line number Diff line number Diff line change
Expand Up @@ -342,9 +342,11 @@ async def diverse_solutions(
with inst.branch() as child:
# Add constraints to the model that sets the decision variables to the reference solution, if provided
if reference_solution:
if isinstance(reference_solution, Result) and is_dataclass(
reference_solution.solution
) and not isinstance(reference_solution.solution, type):
if (
isinstance(reference_solution, Result)
and is_dataclass(reference_solution.solution)
and not isinstance(reference_solution.solution, type)
):
solution_obj = asdict(reference_solution.solution)
else:
assert isinstance(reference_solution, dict)
Expand Down
Loading