Skip to content
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

Wrong OIDs not detected #393

Open
signedav opened this issue Nov 6, 2023 · 0 comments
Open

Wrong OIDs not detected #393

signedav opened this issue Nov 6, 2023 · 0 comments

Comments

@signedav
Copy link

signedav commented Nov 6, 2023

  • Wenn im I32OID fälschlicherweise STANDARDOID stehen, wird dies nicht erkannt.
  • Falsche OIDs in Klassen erweiterter Topics, werden nicht erkannt.

Im folgenden Modell hätten die Objekte folgende OIDs:

  • AnyOIDMadness_V1.Business.Gebaeude -> STANDARDOID
  • AnyOIDMadness_V1.Spass.Gebaeude -> I32OID
  • AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn sofern im Basket von AnyOIDMadness_V1.Business -> STANDARDOID
  • AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn sofern im Basket von AnyOIDMadness_V1.Spass -> I32OID
INTERLIS 2.3;

MODEL AnyOIDBaseMadness_V1 (en) AT "https://modelbaker.ch/" VERSION "2023-11-03" =

    TOPIC Konstruktionen (ABSTRACT)=
        OID AS INTERLIS.ANYOID;

        CLASS Gebaeude (ABSTRACT)=
            Name : TEXT*99;
        END Gebaeude;

        CLASS BesitzerIn =
            Nachname : TEXT*99;
        END BesitzerIn;
    END Konstruktionen;

END AnyOIDBaseMadness_V1.

MODEL AnyOIDMadness_V1 (en) AT "https://modelbaker.ch/" VERSION "2023-11-03" =
    IMPORTS AnyOIDBaseMadness_V1;

    TOPIC Business EXTENDS AnyOIDBaseMadness_V1.Konstruktionen =
        OID AS INTERLIS.STANDARDOID;

        CLASS Gebaeude (EXTENDED)=
            Firma : TEXT*99;
        END Gebaeude;
    END Business;

    TOPIC Spass EXTENDS AnyOIDBaseMadness_V1.Konstruktionen =
        OID AS INTERLIS.I32OID;
        CLASS Gebaeude (EXTENDED)=
            Typ : TEXT*99;
        END Gebaeude;
    END Spass;

END AnyOIDMadness_V1.

I entered:

  • In every instance I entered one correct and one wrong OID, the only one that is recognized is the I32OID value 2000in AnyOIDMadness_V1.Business.Gebaeude.
<?xml version="1.0" encoding="UTF-8"?><TRANSFER xmlns="http://www.interlis.ch/INTERLIS2.3">
<HEADERSECTION SENDER="ili2gpkg-5.0.0-20f2bb62307ba6329a125fc6f10965ad9a4e6300" VERSION="2.3"><MODELS><MODEL NAME="AnyOIDBaseMadness_V1" VERSION="2023-11-03" URI="https://modelbaker.ch"></MODEL><MODEL NAME="AnyOIDMadness_V1" VERSION="2023-11-03" URI="https://modelbaker.ch"></MODEL></MODELS></HEADERSECTION>
<DATASECTION>
<AnyOIDMadness_V1.Business BID="e725f3a7-2575-4477-be2c-074b3e77d078">
<AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn TID="3000"><Nachname>Dave</Nachname></AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn>
<AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn TID="ch00000130000001"><Nachname>Quentin</Nachname></AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn>
<AnyOIDMadness_V1.Business.Gebaeude TID="2000"><Name>Büro1</Name><Firma>OPENGIS.ch</Firma></AnyOIDMadness_V1.Business.Gebaeude>
<AnyOIDMadness_V1.Business.Gebaeude TID="ch00000120000001"><Name>Büro2</Name><Firma>OPENGIS.CH</Firma></AnyOIDMadness_V1.Business.Gebaeude>
</AnyOIDMadness_V1.Business>
<AnyOIDBaseMadness_V1.Konstruktionen BID="0238d32c-2856-480e-add8-5e29ab430c02">
</AnyOIDBaseMadness_V1.Konstruktionen>
<AnyOIDMadness_V1.Spass BID="ed2fe711-751d-4e65-85f0-be0996e31811">
<AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn TID="4000"><Nachname>Selma</Nachname></AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn>
<AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn TID="ch00000140000001"><Nachname>Petushki</Nachname></AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn>
<AnyOIDMadness_V1.Spass.Gebaeude TID="1000"><Name>Hüpf1</Name><Typ>Hüpfburg</Typ></AnyOIDMadness_V1.Spass.Gebaeude>
<AnyOIDMadness_V1.Spass.Gebaeude TID="ch00000100000001"><Name>Hüpf2</Name><Typ>Hüpfburg</Typ></AnyOIDMadness_V1.Spass.Gebaeude>
</AnyOIDMadness_V1.Spass>
</DATASECTION>
</TRANSFER>

Tested with ili2db 5.0.0 and ilivalidator 1.13.3

Info: ilivalidator-1.13.3-a83faf21d19d577c7d9c3c822212dc020509b3d6
Info: ili2c-5.3.2-6fb5df2877070aeb16c7b39a206a61e2518682c8
Info: iox-ili-1.21.18-11c92f590bbe67df7af2051dad58b246996d14eb
Info: java.version 18.0.2-ea
Info: User <dave>
Info: Start date 2023-11-06 15:48
Info: maxMemory 4005888 KB
Info: dataFile </home/dave/qgis_projects/residence_test/anyoid_export.xtf>
Info: modeldir <%ITF_DIR;http://models.interlis.ch/;%JAR_DIR/ilimodels;/home/dave/dev/opengisch/QgisModelBakerLibrary/tests/testdata/ilimodels>
Info: modelNames <AnyOIDBaseMadness_V1>
Info: lookup model <AnyOIDBaseMadness_V1> 2.3 in repository </home/dave/qgis_projects/residence_test/>
Info: lookup model <AnyOIDBaseMadness_V1> 2.3 in repository <http://models.interlis.ch/>
Info: lookup model <AnyOIDBaseMadness_V1> 2.3 in repository </home/dave/tools/ilitools/ilivalidator/ilimodels/>
Warning: Folder /home/dave/tools/ilitools/ilivalidator/ilimodels doesn't exist; ignored
Info: lookup model <AnyOIDBaseMadness_V1> 2.3 in repository </home/dave/dev/opengisch/QgisModelBakerLibrary/tests/testdata/ilimodels/>
Info: ilifile </home/dave/dev/opengisch/QgisModelBakerLibrary/tests/testdata/ilimodels/AnyOIDMadness_V1.ili>
Info: validate data...
Info: assume unknown external objects
Info: first validation pass...
Error: line 7: AnyOIDMadness_V1.Business.Gebaeude: tid 2000: value <2000> is not a valid OID
Info: second validation pass...
Info: object count 8 (structured elements 0)
Info: /home/dave/qgis_projects/residence_test/anyoid_export.xtf: AnyOIDBaseMadness_V1.Konstruktionen BID=0238d32c-2856-480e-add8-5e29ab430c02
Info: /home/dave/qgis_projects/residence_test/anyoid_export.xtf: AnyOIDMadness_V1.Business BID=e725f3a7-2575-4477-be2c-074b3e77d078
Info:       2 objects in CLASS AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn
Info:       2 objects in CLASS AnyOIDMadness_V1.Business.Gebaeude
Info: /home/dave/qgis_projects/residence_test/anyoid_export.xtf: AnyOIDMadness_V1.Spass BID=ed2fe711-751d-4e65-85f0-be0996e31811
Info:       2 objects in CLASS AnyOIDBaseMadness_V1.Konstruktionen.BesitzerIn
Info:       2 objects in CLASS AnyOIDMadness_V1.Spass.Gebaeude
Info: ...validation failed
Info: End date 2023-11-06 15:48 validation took 00h:00m:00s.0396ms
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant