I'm trying to add various tags to my Bio::Phylo object using Bio::Phylo's Dictionary and Annotation objects, and then output the object to NeXML using the Bio::Phylo::IO object.
When I try to create tags with the name "node_color" the script is failing; when I create the same tags with the name "nodecolor" it runs fine.
Tracing back to the problem, it looks like the XMLWritable::set_tag method requires only alphanumeric characters in the tag name. This is far too stringent:
See the XML naming rules from w3schools: