Boost C++ Libraries: Ticket #7016: "graphml" value for the "for" attribute of a key shouldn't throw an exception https://svn.boost.org/trac10/ticket/7016 <p> The GraphML specification (<a class="ext-link" href="http://graphml.graphdrawing.org/xmlns/1.1/graphml-structure.xsd"><span class="icon">​</span>http://graphml.graphdrawing.org/xmlns/1.1/graphml-structure.xsd</a>) states that the possible values for the "for" attribute of a key are "all", "graphml", "graph", "node", "edge", "hyperedge", "port" and "endpoint". </p> <p> (Actually the "graphml" value is absent from the documentation of the scheme, but present as a possible value in the .xsd file. I have sent an e-mail to the authors of the specification, mentioning this ambiguity.) </p> <p> If the value is "graphml", the graphml reader in BGL throws an exception : "Attribute for is not valid: graphml". </p> <p> This value should be added to the ones accepted by the BGL reader, otherwise files such as those produced by the yEd graph editor cannot be read. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/7016 Trac 1.4.3 Jeremiah Willcock Thu, 28 Jun 2012 19:00:32 GMT <link>https://svn.boost.org/trac10/ticket/7016#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7016#comment:1</guid> <description> <p> What are the semantics for <code>graphml</code> when it is used as the value of <code>for</code>? I don't see it mentioned anywhere in the spec or in the yFiles documentation other than as just a possible option. How does yEd use <code>for="graphml"</code>? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Will Plano</dc:creator> <pubDate>Tue, 16 Apr 2013 08:51:22 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/7016#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/7016#comment:2</guid> <description> <p> I've just come across this defect, also while trying to parse a yEd file. </p> <p> According to the documentation at graphml.graphdrawing.org/specification/schema_element.xsd.htm the for="graphml" key attribute is for data associated with "the whole collection of graphs described by the content of &lt;graphml&gt;" Since read_graphml only deals with a single graph in the file, I beleive it is correct to silently ignore this section. </p> <p> As for how yEd uses it, it looks like it's for shared resources within the file... </p> <div class="wiki-code"><div class="code"><pre><span class="cp">&lt;?xml version=&quot;1.0&quot; encoding=&quot;UTF-8&quot; standalone=&quot;no&quot;?&gt;</span> ... snip schema definitions for spam filter ... <span class="c">&lt;!--Created by yFiles for Java 2.10--&gt;</span> <span class="nt">&lt;key</span> <span class="na">for=</span><span class="s">&quot;graphml&quot;</span> <span class="na">id=</span><span class="s">&quot;d0&quot;</span> <span class="na">yfiles.type=</span><span class="s">&quot;resources&quot;</span><span class="nt">/&gt;</span> ... snip ... <span class="nt">&lt;data</span> <span class="na">key=</span><span class="s">&quot;d0&quot;</span><span class="nt">&gt;</span> <span class="nt">&lt;y:Resources/&gt;</span> <span class="nt">&lt;/data&gt;</span> <span class="nt">&lt;/graphml&gt;</span> </pre></div></div><p> see the attached patch on the duplicate ticket 7155 </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Jeremiah Willcock</dc:creator> <pubDate>Thu, 18 Apr 2013 20:21:42 GMT</pubDate> <title>status changed; resolution set https://svn.boost.org/trac10/ticket/7016#comment:3 https://svn.boost.org/trac10/ticket/7016#comment:3 <ul> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> (In <a class="changeset" href="https://svn.boost.org/trac10/changeset/83961" title="Applied patch from #7155 to add &#34;graphml&#34; as a value for &#34;for&#34;; fixes ...">[83961]</a>) Applied patch from <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/7155" title="#7155: Feature Requests: Graph's GraphML reader mistreats &lt;key for=&#34;graphml&#34;&gt; as erroneous (closed: fixed)">#7155</a> to add "graphml" as a value for "for"; fixes <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/7155" title="#7155: Feature Requests: Graph's GraphML reader mistreats &lt;key for=&#34;graphml&#34;&gt; as erroneous (closed: fixed)">#7155</a>; fixes <a class="closed ticket" href="https://svn.boost.org/trac10/ticket/7016" title="#7016: Bugs: &#34;graphml&#34; value for the &#34;for&#34; attribute of a key shouldn't throw an ... (closed: fixed)">#7016</a> </p> Ticket