hyperpyyaml: mark broken for ruamel-yaml 0.19#493996
hyperpyyaml: mark broken for ruamel-yaml 0.19#493996GaetanLepage merged 1 commit intoNixOS:masterfrom
Conversation
| # requires ruamel.yaml>=0.17.28,<0.19.0 or tests fail | ||
| (ruamel-yaml.overrideAttrs { | ||
| src = fetchPypi { | ||
| pname = "ruamel.yaml"; | ||
| version = "0.18.16"; | ||
| hash = "sha256-puWHUS88mYsiJdaKofNREcKfrRSu1WGibnP6tynsXlo="; | ||
| }; | ||
| }) |
There was a problem hiding this comment.
Then let's disable the test.
Mixing different releases of the same package in nixpkgs is discouraged as it can cause mismatches in users' environments.
Is hyperpyyaml fundamentally incompatible with 0.19, or is it just a non-crucial test that fails?
There was a problem hiding this comment.
There's only a single test in the test suite, and it appears to be fundamentally incompatible:
============================= test session starts ==============================
platform linux -- Python 3.13.12, pytest-9.0.2, pluggy-1.6.0
rootdir: /build/source
collected 1 item
tests/test_hyperyaml.py F [100%]
=================================== FAILURES ===================================
____________________________ test_load_hyperpyyaml _____________________________
tmpdir = local('/build/pytest-of-nixbld/pytest-0/test_load_hyperpyyaml0')
def test_load_hyperpyyaml(tmpdir):
from hyperpyyaml import (
load_hyperpyyaml,
RefTag,
Placeholder,
dump_hyperpyyaml,
)
# Basic functionality
yaml = """
a: 1
thing: !new:collections.Counter {}
"""
> things = load_hyperpyyaml(yaml)
^^^^^^^^^^^^^^^^^^^^^^
tests/test_hyperyaml.py:17:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
hyperpyyaml/core.py:189: in load_hyperpyyaml
hparams = yaml.load(yaml_stream, Loader=loader)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/nix/store/imindlm08wk8n5d0yhmm0ap3gcymqxdk-python3.13-pyyaml-6.0.3/lib/python3.13/site-packages/yaml/__init__.py:81: in load
return loader.get_single_data()
^^^^^^^^^^^^^^^^^^^^^^^^
/nix/store/aw6yr5gcas5hgzg0nm2gmykfihdkj3vv-python3.13-ruamel-yaml-0.19.1/lib/python3.13/site-packages/ruamel/yaml/constructor.py:117: in get_single_data
node = self.composer.get_single_node()
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
/nix/store/aw6yr5gcas5hgzg0nm2gmykfihdkj3vv-python3.13-ruamel-yaml-0.19.1/lib/python3.13/site-packages/ruamel/yaml/composer.py:77: in get_single_node
document = self.compose_document()
^^^^^^^^^^^^^^^^^^^^^^^
/nix/store/aw6yr5gcas5hgzg0nm2gmykfihdkj3vv-python3.13-ruamel-yaml-0.19.1/lib/python3.13/site-packages/ruamel/yaml/composer.py:100: in compose_document
node = self.compose_node(None, None)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <ruamel.yaml.loader.Loader object at 0x7ffff6128ec0>, parent = None
index = None
def compose_node(self, parent: Any, index: Any) -> Any:
if self.parser.check_event(AliasEvent):
event = self.parser.get_event()
alias = event.anchor
if alias not in self.anchors:
raise ComposerError(
None, None, f'found undefined alias {alias!r}', event.start_mark,
)
return self.return_alias(self.anchors[alias])
self.depth += 1
event = self.parser.peek_event()
> if self.loader.max_depth and self.depth > self.loader.max_depth:
^^^^^^^^^^^^^^^^^^^^^
E AttributeError: 'Loader' object has no attribute 'max_depth'
/nix/store/aw6yr5gcas5hgzg0nm2gmykfihdkj3vv-python3.13-ruamel-yaml-0.19.1/lib/python3.13/site-packages/ruamel/yaml/composer.py:121: AttributeError
There was a problem hiding this comment.
speechbrain/HyperPyYAML#32
Amusing seeing you CC'ed in precisely this PR :D @GaetanLepage
There was a problem hiding this comment.
I'm everywhere haha!
Ok, now it makes sense that I had an impression of déjà vu on this one...
There was a problem hiding this comment.
Mixing different releases of the same package in nixpkgs is discouraged
Not just discouraged, it's simply not allowed within python3Packages.
dotlambda
left a comment
There was a problem hiding this comment.
Let's rather set
meta.broken = lib.versionAtLeast ruamel-yaml.version "0.19";and link to speechbrain/HyperPyYAML#32
064681a to
287a3a8
Compare
|
Well, that's unfortunate. I've marked it as broken as requested. |
|
Any top-level package, i.e., not in |
Things done
The build breaks due toruamel-yamlbeing updated from 0.18 -> 0.19. I tried doing apythonRelaxDeps, but that breaks the tests, so I reverted ruamel-yaml to 0.18.Marking as broken as per speechbrain/HyperPyYAML#32
passthru.tests.nixpkgs-reviewon this PR. See nixpkgs-review usage../result/bin/.