Geospatial bindings don't generate successfully on github version? #28

shongololo opened this Issue Feb 15, 2015 · 5 comments


None yet

2 participants


I've noticed that when trying to generate the geospatial bindings:

The source forge version generates successfully, whereas the github versions (master or development versions) don't? Unfortunately I don't remember the exact error.

pabigot commented Feb 15, 2015

Since the SF master and github master are identical, this is odd. I've just confirmed it works for me on the internal development version, and it worked when I released the master version.

When you remember the exact error and can reproduce it with an up-to-date download from please feel free to re-open this and provide that information.

@pabigot pabigot closed this Feb 15, 2015

Hi, here you go, I downloaded the github version again and this is the error message I receive.

Exception generating bindings: has no category attributeGroupDefinition
Traceback (most recent call last):
File "/Users/shongololo/Downloads/pyxb-master/pyxb/namespace/", line 307, in categoryMap
return self.__categoryMap[category]
KeyError: 'attributeGroupDefinition'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/shongololo/Downloads/pyxb-master/scripts/pyxbgen", line 65, in
modules = generator.bindingModules()
File "/Users/shongololo/Downloads/pyxb-master/pyxb/binding/", line 2865, in bindingModules
File "/Users/shongololo/Downloads/pyxb-master/pyxb/binding/", line 2725, in __resolveComponentDependencies
File "/Users/shongololo/Downloads/pyxb-master/pyxb/namespace/", line 327, in ResolveSiblingNamespaces
if not ns.resolveDefinitions(allow_unresolved=True):
File "/Users/shongololo/Downloads/pyxb-master/pyxb/namespace/", line 223, in resolveDefinitions
File "/Users/shongololo/Downloads/pyxb-master/pyxb/xmlschema/", line 2540, in _resolve
return self.__completeProcessing(self.__pendingDerivationMethod, self.__contentStyle)
File "/Users/shongololo/Downloads/pyxb-master/pyxb/xmlschema/", line 2082, in __completeProcessing
agd = ag_en.attributeGroupDefinition()
File "/Users/shongololo/Downloads/pyxb-master/pyxb/namespace/__init
.py", line 104, in getattr
category_value = ns.categoryMap(name).get(self.localName())
File "/Users/shongololo/Downloads/pyxb-master/pyxb/namespace/", line 309, in categoryMap
raise pyxb.NamespaceError(self, '%s has no category %s' % (self, category))
pyxb.exceptions_.NamespaceError: has no category attributeGroupDefinition
Failed: gml_3_2

pabigot commented Feb 15, 2015

Back in 2012 the official schemas switched to using the W3C version of XLink instead of OpenGIS's non-standard version, and the pyxb generation depends on that being available. You may need to generate the common bindings first, and make sure you use the current schemas bundle from the link I noted above.

This command should generate everything:

maintainer/genbundles @ opengis

The script replaces @ with the schemas for core namespaces used by other complex schemas. You could try just using common but that's not now I build them so I can't say whether it'd work.


This method works, thanks.

pabigot commented Feb 18, 2015

Re-opening to remind me to update the opengis README.txt based on the discoveries in this issue.

@pabigot pabigot reopened this Feb 18, 2015
@pabigot pabigot added a commit that closed this issue Aug 30, 2015
@pabigot close #28: document need for common bindings when building opengis
Back in 2012 the official schemas switched to using the W3C version of
XLink instead of OpenGIS's non-standard version, and the pyxb generation
now depends on that being available.  Enhance the build description to
show how to get them.
@pabigot pabigot closed this in e4dcf70 Aug 30, 2015
@pabigot pabigot added this to the PyXB 1.2.5 milestone Sep 18, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment