Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Rob Braden updated an issue Puppet / PUP-8547 MRI and JRuby Yaml parsers not compliant with spec wrt. errors Change By: Rob Braden Team: Platform Core Coremunity Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Henrik Lindberg commented on PUP-8547 Re: MRI and JRuby Yaml parsers not compliant with spec wrt. errors I got the impression that PyYaml also uses the same libyaml - so it should have the same behaviour. I pointed this out on the psych issue. Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Henrik Lindberg updated an issue Puppet / PUP-8547 MRI and JRuby Yaml parsers not compliant with spec wrt. errors Change By: Henrik Lindberg Comment: JRuby uses the same Psych package as MRI - so it is bug compatible. Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Henrik Lindberg commented on PUP-8547 Re: MRI and JRuby Yaml parsers not compliant with spec wrt. errors JRuby uses the same Psych package as MRI - so it is bug compatible. Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Andrey Galkin commented on PUP-8547 Re: MRI and JRuby Yaml parsers not compliant with spec wrt. errors Looked at code, psych uses event emitter when parsing. It just ends the document and ignores another document. Here the issue reported back in 2015: https://github.com/ruby/psych/issues/239 I believe, PuppetLabs can influence/help the issue to resolve. Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Andrey Galkin commented on PUP-8547 Re: MRI and JRuby Yaml parsers not compliant with spec wrt. errors I believe, the main problem is PuppetServer which runs in JRuby. So, it seems "snakeyaml" should be used internally by "psych" wrapper. I've tried a quick test of Java version and immediately found that it DOES properly handle invalid documents. Exception in thread "main" expected '', but found BlockMappingStart in 'reader', line 5, column 1: somevar: 3 ^ at org.yaml.snakeyaml.parser.ParserImpl$ParseDocumentStart.produce(ParserImpl.java:225) at org.yaml.snakeyaml.parser.ParserImpl.peekEvent(ParserImpl.java:157) at org.yaml.snakeyaml.parser.ParserImpl.checkEvent(ParserImpl.java:147) at org.yaml.snakeyaml.composer.Composer.getSingleNode(Composer.java:108) at org.yaml.snakeyaml.constructor.BaseConstructor.getSingleData(BaseConstructor.java:120) at org.yaml.snakeyaml.Yaml.loadFromReader(Yaml.java:450)
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Thomas Hallgren commented on PUP-8547 Re: MRI and JRuby Yaml parsers not compliant with spec wrt. errors Andrey Galkin, feel free to suggest what proper YAML parser we could use if you had one in mind. We will need something that uses native code for lex/parse since this is on a performance critical path. Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups "Puppet Bugs" group. To unsubscribe from this group and stop receiving emails from it, send an email to puppet-bugs+unsubscr...@googlegroups.com. To post to this group, send email to puppet-bugs@googlegroups.com. Visit this group at https://groups.google.com/group/puppet-bugs. For more options, visit https://groups.google.com/d/optout.
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Henrik Lindberg updated an issue Puppet / PUP-8547 MRI and JRuby Yaml parsers not compliant with spec wrt. errors Change By: Henrik Lindberg As noted in PUP-8541 the Ruby YAML parser does not detect certain errors that the YAML specification defines as illegal. * keys must be unique and not overwrite* faulty indentation not raising errorThe issues needs to be reported to upstream projects (if they do not already have tickets for these problems). We need to wait for fixes as we must rely on the native implementation of YAML parsing or we would not have good performance.Note that the problems are for invalid YAML that Ruby thinks is valid but for which it produces a bad result. Example - this should be an error:{code:yaml}---somevar: 1somevar: 2{code}Example - this should be an error:{code:yaml}--- #someobj: a: 1 b: 2somevar: 1{code} Add Comment This message was sent by Atlassian JIRA (v7.7.1#77002-sha1:e75ca93) -- You received this message because you are subscribed to the Google Groups
Jira (PUP-8547) MRI and JRuby Yaml parsers not compliant with spec wrt. errors
Title: Message Title Henrik Lindberg created an issue Puppet / PUP-8547 MRI and JRuby Yaml parsers not compliant with spec wrt. errors Issue Type: Bug Assignee: Unassigned Created: 2018/03/14 3:49 AM Priority: Normal Reporter: Henrik Lindberg As noted in PUP-8541 the Ruby YAML parser does not detect certain errors that the YAML specification defines as illegal. keys must be unique and not overwrite faulty indentation not raising error The issues needs to be reported to upstream projects (if they do not already have tickets for these problems). We need to wait for fixes as we must rely on the native implementation of YAML parsing or we would not have good performance. Note that the problems are for invalid YAML that Ruby thinks is valid but it produces a bad result. Add Comment