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

YAML error: We don't handle these values: Type: <class 'ruamel.yaml.comments.TaggedScalar'> #4765

Closed
gomin1d opened this issue Oct 27, 2020 · 7 comments · Fixed by translate/translate#4157
Assignees
Labels
bug Something is broken. translate-toolkit Issues which need to be fixed in the translate-toolkit

Comments

@gomin1d
Copy link

gomin1d commented Oct 27, 2020

i add this file with strings:
messages.ru.zip

it has the format according to the documentation:
https://docs.weblate.org/en/latest/formats.html#yaml

weblate:
  hello: ""
  orangutan": ""
  try": ""
  thanks": ""

but when loading it throws an error:

We don't handle these values: Type: <class 'ruamel.yaml.comments.TaggedScalar'> Data: = Previous: weblate->coding.sign.if_variable_equals

image

@gomin1d gomin1d added the question This is more a question for the support than an issue. label Oct 27, 2020
@github-actions
Copy link

This issue looks more like a support question than an issue. We strive to answer these reasonably fast, but purchasing the support subscription is not only more responsible and faster for your business but also makes Weblate stronger. In case your question is already answered, making a donation is the right way to say thank you!

@nijel nijel added bug Something is broken. translate-toolkit Issues which need to be fixed in the translate-toolkit and removed question This is more a question for the support than an issue. labels Oct 27, 2020
@github-actions
Copy link

The issue you've reported needs to be addressed in the translate-toolkit. Please file the issue there, and include links to any relevant specifications about the formats (if applicable).

@nijel
Copy link
Member

nijel commented Oct 27, 2020

It seems that the equals sign should be quoted for some reason.

Changing

coding.sign.if_variable_equals: =

to

coding.sign.if_variable_equals: "="

should fix the parsing.

@nijel nijel changed the title I have an error while adding a yaml file with strings We don't handle these values: Type: <class 'ruamel.yaml.comments.TaggedScalar'> Data: = Previous: weblate->coding.sign.if_variable_equals YAML error: We don't handle these values: Type: <class 'ruamel.yaml.comments.TaggedScalar'> Oct 27, 2020
@nijel
Copy link
Member

nijel commented Oct 27, 2020

The proper fix should be translate/translate#4157

@gomin1d
Copy link
Author

gomin1d commented Oct 27, 2020

Wow thanks

I generated this yaml file using snakeyaml on java
thus it was generated
I didn't think that syntax violations are possible

@gomin1d gomin1d closed this as completed Oct 27, 2020
@github-actions
Copy link

Thank you for your report, the issue you have reported has just been fixed.

  • In case you see a problem with the fix, please comment on this issue.
  • In case you see a similar problem, please open a separate issue.
  • If you are happy with the outcome, don’t hesitate to support Weblate by making a donation.

@nijel nijel self-assigned this Oct 27, 2020
@nijel
Copy link
Member

nijel commented Oct 27, 2020

I don't think it's syntax violation, it's rather issue in the parser. That should be fixed in the next translate-toolkit release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something is broken. translate-toolkit Issues which need to be fixed in the translate-toolkit
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants