Closed jcberquist closed 6 years ago
In order to successfully build I replaced
args = loader.construct_mapping(node)
with
ret = ruamel.yaml.comments.CommentedMap()
loader.construct_mapping(node, ret)
args = dict(ret.items())
While that works (in the sense that a build completes), I have no idea whether it is a real solution.
This is a weird bug -- weird because that code path is actually working most of the time. I don't know why it would work in some cases but not others.
In any case, I've released v3.0.4 with basically the fix you suggested. That should be correct.
Ideally, version 3 should be perfectly backward-compatible, although one or two things are deprecated. Thanks (and apologies) for finding the bug!
Thanks for the quick fix!
I am trying out the latest version of YAML-Macros and given the following source:
I see the following error:
Looking at
constructor.py
I see severalconstruct_mapping
methods in the various classes. Theconstruct_mapping
method that is getting called in the trace above is the one in theRoundTripConstructor
which seems to need a map passed in, and also doesn't return anything (meaningargs
will always beNone
after line 58).I know a lot of work has gone into YAML-Macros recently, so is there something I need to change on my end?