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

IP with port doesn't open as URL anymore #5125

Closed
The-Compiler opened this issue Dec 1, 2019 · 2 comments · Fixed by #5139
Closed

IP with port doesn't open as URL anymore #5125

The-Compiler opened this issue Dec 1, 2019 · 2 comments · Fixed by #5139
Labels
bug: behavior Something doesn't work as intended, but doesn't crash. priority: 0 - high Issues which are currently the primary focus.
Milestone

Comments

@The-Compiler
Copy link
Member

Since 5008b3b, opening something like 192.168.0.118:8083 causes a search instead of opening the IP as URL.

@arza-zara could you please take a look?

@The-Compiler The-Compiler added priority: 0 - high Issues which are currently the primary focus. bug: behavior Something doesn't work as intended, but doesn't crash. labels Dec 1, 2019
@The-Compiler The-Compiler added this to the v1.9.0 milestone Dec 1, 2019
@The-Compiler
Copy link
Member Author

We do this currently:

    if not utils.raises(ValueError, ipaddress.ip_address, urlstr):
        # Valid IPv4/IPv6 address
        return True

which catches cases like 192.168.0.118 but not 192.168.0.118:8083. Maybe we should just use url.host() (or host) instead of urlstr there?

@arza-zara
Copy link
Member

Maybe we should just use url.host()

I guess so, except host() converts some stuff to IP addresses, so I added an additional substring check. isNull() check seemed unnecessary so I removed it. See #5139.

user202729 pushed a commit to user202729/qutebrowser that referenced this issue Jan 30, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug: behavior Something doesn't work as intended, but doesn't crash. priority: 0 - high Issues which are currently the primary focus.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants