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

fix utils.py to not load contents as file paths #217

Merged
merged 5 commits into from
Apr 6, 2024

Conversation

JaeTLDR
Copy link
Contributor

@JaeTLDR JaeTLDR commented Apr 5, 2024

Looks like PyLode is attempting to open a file with ontology however if this is a serialised graph the server can error trying to load this file
image

I have added a small simple detection logic however it may be simpler to pass the ontology variable to RDFLib and get it to do the path vs graph and the file type detection rather than rolling its own. Additionally i noticed a lack of strip() on the imput, this may cause errors with the data type detection not firing corretly

@edmondchuc
Copy link
Collaborator

Thanks, I've refactored the code a bit and added a test.

@edmondchuc edmondchuc merged commit c1ad9f3 into RDFLib:master Apr 6, 2024
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

Successfully merging this pull request may close these issues.

2 participants