morbac / xmltools

XML Tools plugin for Notepad++
GNU General Public License v3.0
257 stars 57 forks source link

`noNamespaceSchemaLocation` not found in case of domain redirection #212

Open MarAlder opened 4 months ago

MarAlder commented 4 months ago

Maybe this relates partly to #134:

We provide users of our CPACS data model with permanent links to XSD files via GitHub pages. Our domain www.cpacs.de redirects to the corresponding GitHub page.

In order to keep the schema location as constant as possible (i.e. independent of a provider change), we would like to specify the schema location via the www domain (see here).

Unfortunately, xmltools does not recognize the schema location if it is behind the forwarding of the www domain. Other editors, e.g. VSCode (+ XML Red hat extension) or Eclipse (+ XML extension) support this. As the majority of our users are very fond of Notepad++, I would like to ask whether this can be fixed?

The expected behavior is that this should work, but it does not in Notepad++ and xmltools:

<?xml version="1.0" encoding="UTF-8"?>
<cpacs xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:noNamespaceSchemaLocation="https://www.cpacs.de/schema/v3_5_0/cpacs_schema.xsd">

grafik

This example finds the XSD, but we want to avoid direct link to github pages (as the provider could potentially change):

<?xml version="1.0" encoding="UTF-8"?>
<cpacs xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xsi:noNamespaceSchemaLocation="https://dlr-sl.github.io/cpacs-website/schema/v3_5_0/cpacs_schema.xsd">

Attached is a minimal example for testing: example.zip

(tagging @Cliersch)