-
-
Notifications
You must be signed in to change notification settings - Fork 62
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
Document cannot be decoded #491
Comments
Can you share the xsd? If you switch on the config
@dataclass
class Smil(SmilSmilContent):
class Meta:
name = "smil"
namespace = "http://www.w3.org/ns/SMIL"
class SmilHeadContent:
class Meta:
name = "SMIL.head.content"
meta: List[Meta] = field( # There is an actual dataclass with name Meta
default_factory=list,
metadata={
"name": "meta",
"type": "Element",
}
) |
There is no namespace for the name conflict switch to branch issue-491 |
When searching for this, I noticed a namespace prefix in my generateDS session. That explains why it works. Maybe a command line argument to specify it makes sense. |
generateDS allows to switch the default namespace of the schema under what context? The schema is supposed to be a binding contract, either the schema is wrong or the xml. |
As mentioned, I generated the XSD from a DTD. Likely that should have a namespace.
|
GenerateDS has an option namespace prefix, this can be specified. I guess it overrides the default.
|
Yeah I suggest fixing the schema instead or the conversion from the DTD, the fix for the name conflict is merged on master #492 |
Added targetNamespace, most of the problems have been resolved. The remaining ConverterWarning's are likely generated between chair and keyboard. |
I am trying to move more projects from generateDS towards xsdata. For the SMIL standard I am using a DTD that is converted via trang to an XSD. I have attempted to use the optimize-datatypes branch and master branch. Both of them generate code, but neither of them allow me to parse a document. The structure remains "empty".
smil.py.txt
broadcast.smil.txt
The text was updated successfully, but these errors were encountered: