-
Notifications
You must be signed in to change notification settings - Fork 97
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
#89 StringURI now handles validation of valid URIs which aren't URLs #90
#89 StringURI now handles validation of valid URIs which aren't URLs #90
Conversation
Second commit adds |
Are all of these allowed according to OAS3 spec ? |
According to the Json Schema definition, when something is type
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM 👍
Are you happy to add a dependency to the other package at that specific version? Won't it cause problems for someone who already has a dependency on (for example) league/uri: "6.2"
?
I'm not really sure how libraries generally address this sort of thing. It looks like 6.0.0
has the same API, so it should be OK to change the dependency to 6.*
. But you couldn't have your library and also install league/uri
at version 5, for example (the API is different there).
As an alternative, I could adapt the code from the URI library and re-implement it in this library without the additional dependency. The obvious downside is that there is then more code for you to maintain, and it would be harder to keep up with upstream changes if it emerged that there was an issue with the parser in the URI lib.
This is not how libraries should be used for sure. No one wants to maitain two libs with same code instead of one |
Hi @scaytrase, what else needs to happen before this PR can be merged? Thanks for your support :) |
Oh, sorry, thanks for reminding. I'll check it asap |
At the moment this won't pass build, the first commit only contains failing tests. I copied the list of valid and invalid URIs from the
league/uri
package's tests. See: https://github.com/thephpleague/uri/blob/master/tests/UriStringTest.php