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

Allow parentheses in uri #1280

Merged
merged 7 commits into from Apr 24, 2021
Merged

Allow parentheses in uri #1280

merged 7 commits into from Apr 24, 2021

Conversation

fredrik-aschehoug
Copy link
Contributor

Fixes: Allow URI's containing parentheses to be split correctly.

I could not find any documentation stating that parentheses are not allowed in the name part of the URI. I noticed that in my serialized graphs, URI's containing parentheses did not serialize properly. Yago3 for example uses parentheses extensively.

Please excuse me if my assumption that parentheses are allowed is wrong.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.008%) to 75.515% when pulling a5f3964 on fredrik-aschehoug:allow_parantheses_in_URI into 1b77d03 on RDFLib:master.

@nicholascar
Copy link
Member

Yes, "(" & ")" are indeed allowed, they are sub-delims, that is used for delimitation in some places within the URI but not everywhere. See the URI syntax https://tools.ietf.org/html/rfc3986#section-3.3:

pchar         = unreserved / pct-encoded / sub-delims / ":" / "@"

Since the theory checks out, the PR passes all tests and you've supplied new tests, I'm happy to approve this.

@nicholascar nicholascar merged commit dc72a1b into RDFLib:master Apr 24, 2021
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.

None yet

3 participants