andygrove opened a new issue, #365:
URL: https://github.com/apache/datafusion-spark/issues/365
### Describe the bug
`parse_url` treats a URL with a port above 65535 as invalid. Spark parses it
with `java.net.URI`, which does not check the port's range, so it returns the
requested part.
### To Reproduce
```sql
SELECT parse_url('http://spark.apache.org:99999/path', 'HOST');
```
datafusion-spark returns `NULL` with ANSI mode off, and raises `InvalidPort`
with ANSI mode on.
Spark 4.2.0 returns `spark.apache.org` in both modes.
### Expected behavior
`spark.apache.org`, as in Spark. The other parts, such as `PATH` and
`AUTHORITY`, should also match Spark for such a URL.
### Additional context
Raised in the review of #340. The records are in `url/parse_url.slt`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]