Open geostonemarten opened 5 years ago
@geostonemarten Apparently, the constraint comes from ElementTree, the Python XML library. From what I can read in the source code, any namespace that is named ns
followed by a number is reserved.
Ok this is a language limite. Can you overload namespace if ns* is detected in the source file?
@geostonemarten did you mean deleted rather than detected ?
I was getting the error with a file with the following prefixes:
<gml:FeatureCollection
xmlns:lc="urn:x-inspire:specification:gmlas:LandCover:0.0"
xmlns:sr="urn:x-inspire:specification:gmlas:SeaRegions:0.0"
xmlns:nrz="urn:x-inspire:specification:gmlas:NaturalRiskZones:0.0"
xmlns:gco="http://www.isotc211.org/2005/gco"
xmlns:hfp="http://www.w3.org/2001/XMLSchema-hasFacetAndProperty"
xmlns:wfd="urn:x-inspire:specification:gmlas:WaterFrameworkDirective:0.0"
xmlns:gml="http://www.opengis.net/gml/3.2"
xmlns:ns1="http://www.w3.org/1999/xhtml"
xmlns:hy="urn:x-inspire:specification:gmlas:HydroBase:3.0"
xmlns:hy-n="urn:x-inspire:specification:gmlas:HydroNetwork:3.0"
xmlns:gmd="http://www.isotc211.org/2005/gmd"
xmlns:hy-p="urn:x-inspire:specification:gmlas:HydroPhysicalWaters:3.0"
xmlns:net="urn:x-inspire:specification:gmlas:Network:3.2"
xmlns:gsr="http://www.isotc211.org/2005/gsr"
xmlns:gts="http://www.isotc211.org/2005/gts"
xmlns:gn="urn:x-inspire:specification:gmlas:GeographicalNames:3.0"
xmlns:xlink="http://www.w3.org/1999/xlink"
xmlns:gss="http://www.isotc211.org/2005/gss"
xmlns:base="urn:x-inspire:specification:gmlas:BaseTypes:3.2"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
gml:id="_64fcbf57-4712-471b-941a-a32bf099cb3a"
xsi:schemaLocation="urn:x-inspire:specification:gmlas:HydroPhysicalWaters:3.0 http://inspire.ec.europa.eu/schemas/hy-p/3.0/HydroPhysicalWaters.xsd http://www.opengis.net/gml/3.2 http://schemas.opengis.net/gml/3.2.1/deprecatedTypes.xsd">
Changing xmlns:ns1="http://www.w3.org/1999/xhtml" to xmlns:ns_1="http://www.w3.org/1999/xhtml" resolves the issue
Can you overload xml before import for all key use and reserved to your internal use?
What key are reseved?
Stacktrace Python: