-
-
Notifications
You must be signed in to change notification settings - Fork 602
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
--explodeAnchors / -X doesn't explode keys (work in 3.3.1 and 3.3.2) #466
Comments
please follow the bug template - there is not enough information in this for me to replicate |
@mikefarah Mike, I updated the issue. Try it now please. |
That's not how you use anchors and aliases, I can't quite work out what you are trying to do, but it needs to be something like: errors:
- &ts_sync_loss ts_sync_loss # this creates a variable for the value 'ts_sync_loss'
properties: *ts_sync_loss # this references that variable |
@mikefarah I don't think you're right. You can try out my example with any of the available validators/parsers: |
Sorry, but we are you keeping this closed @mikefarah? |
Just to clarify things. It transpired that the original YAML was actullay INCORRECT. Specifically, this: errors:
- &ts_sync_loss ts_sync_loss
properties:
*ts_sync_loss: int should read as: errors:
- &ts_sync_loss ts_sync_loss
properties:
*ts_sync_loss : int (note the extra space after Unfortunately for this tool it doesn't make any difference, it still fails. Consider this YAML: devs:
- &dev1 Alice
- &dev2 Bob
- &devop Jane
time:
- name: Project 1
devs:
*dev1 : 120 hours
*devop : 32 hours
- name: Project 2
devs:
*dev2 : 154 hours
*devop : 21 hours It works with these popular YAML parsers:
|
Ok I originally misunderstood the yaml file - now I see that the aliases are for the map keys! I didn't realise you could do that in yaml, neat. Sorry it took me a while. This should be fixable. |
Describe the bug
-X
/--explodeAnchors
doesn't work now in 3.3.2 or 3.3.1 (for theread
command at least).The last version when it worked was 3.3.0.
This should work:
1.yaml
but outputs:
i.e.
ts_sync_loss
is not dereferenced .Command
Version 3.3.0 does work right.
The text was updated successfully, but these errors were encountered: