You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
--- a/src/inmanta/env.py+++ b/src/inmanta/env.py@@ -1050,9 +1050,10 @@ class ActiveEnv(PythonEnvironment):
for c in all_constraints:
requirement = c.requirement
req_name = NormalizedName(requirement.name) # requirement is already canonical
+ if requirement.marker and not requirement.marker.evaluate():+ continue
if req_name not in installed_versions or (
not requirement.specifier.contains(installed_versions[req_name], prereleases=True)
- and (not requirement.marker or (requirement.marker and requirement.marker.evaluate()))
):
version_conflict = VersionConflict(
requirement=requirement,
@@ -1126,6 +1127,7 @@ class ActiveEnv(PythonEnvironment):
constraint_violations: set[VersionConflict] = {
VersionConflict(constraint, installed_versions.get(constraint.name, None))
for constraint in all_constraints
+ if not requirement.marker or requirement.marker.evaluate()
if constraint.name not in installed_versions
or not constraint.specifier.contains(installed_versions[constraint.name], prereleases=True)
}
verify bug -> confirmed by running manual compile
fix. evaluate() may or may not require a parameter -> see other call to the method in env.py
The text was updated successfully, but these errors were encountered:
)
# Description
closes#8405
# Self Check:
Strike through any lines that are not applicable (`~~line~~`) then check the box
- [x] Attached issue to pull request
- [x] Changelog entry
- [x] Type annotations are present
- [x] Code is clear and sufficiently documented
- [x] No (preventable) type errors (check using make mypy or make mypy-diff)
- [ ] Sufficient test cases (reproduces the bug/tests the requested feature)
- [x] Correct, in line with design
- [ ] End user documentation is included or an issue is created for end-user documentation (add ref to issue here: )
- [ ] If this PR fixes a race condition in the test suite, also push the fix to the relevant stable branche(s) (see [test-fixes](https://internal.inmanta.com/development/core/tasks/build-master.html#test-fixes) for more info)
evaluate()
may or may not require a parameter -> see other call to the method inenv.py
The text was updated successfully, but these errors were encountered: