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

urispace wird bei import nicht erkannt, vokabular wird dann fehlerhaft in skosmos angezeigt #92

Open
FelixFrizzy opened this issue May 24, 2024 · 1 comment

Comments

@FelixFrizzy
Copy link
Collaborator

Der Fehler liegt daran, dass in dem skosmos config.ttl file dann sowas steht wie

    skosmos:mainConceptScheme <http> ;
    void:sparqlEndpoint <http://fuseki-dev:3030/tadirah_notworking/sparql> ;
    void:uriSpace "http" .

Es muss aber sowohl für skosmos:mainConceptScheme als auch für void:uriSpace was gesetzt werden. Urispace bleibt wahrscheinlich leer weil die urispace detection recht obskur sein könnte. Das wurde von den Studis last minute kurz vor finaler (!) Abgabe noch hinzugefügt und ich muss erstmal schauen was da getrieben wurde.
Quick"fix" ist die manuelle bearbeitung des config.ttl files

comment 1 from FK

Problem liegt hier:

evoks/vocabularies/models.py

def find_urispace(subjects):

    prefix = subjects[0]
    for word in subjects:
        if len(prefix) > len(word):
            prefix, word = word, prefix

        while len(prefix) > 0:
            if word[:len(prefix)] == prefix:
                break
            else:
                prefix = prefix[:-1]
    return prefix

Wenn das keinen urispace findet gibt die funktion einfach einen leeren String zurück und das Vokabular kann nicht angezeigt werden. Das ist natürlich Unsinn

comment 2 from FK

fix in arbeit in branch urispace_detection. was jetzt funktioniert ist der import von tadirah.rdf.
was noch nicht funktioniert ist, wenn ich bei tadirah ein prefix angebe (xmlns:tadirah="https://vocabs.dariah.eu/tadirah/"), dann wird es in Skosmos nicht richtig angezeigt

@FelixFrizzy FelixFrizzy self-assigned this May 24, 2024
@FelixFrizzy
Copy link
Collaborator Author

Related with #93

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant