Skip to content

Package.from_dict(obj.to_dict()).to_xml() messes up vocab types #33

@slbayer

Description

@slbayer

To recreate, do this:

import maec
obj = maec.parse_xml_instance("maec_4.1_examples/package_manual_analysis_example.xml")["api"]
print maec.package.package.Package.from_dict(obj.to_dict()).to_xml().encode('utf8')

(the final encode() is because I'm printing to an ASCII terminal; it isn't going to affect the problem).

In the output, search for BAD_XSI_TYPE, which occurs all over the place.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions