Closed jessebrennan closed 3 years ago
Also running into this issue when setting the scheme
By attribute:
In [2]: from furl import furl
In [3]: u = furl('google.com')
In [4]: u
Out[4]: furl('google.com')
In [5]: u.scheme = 'https'
In [6]: u
Out[6]: furl('https:///google.com')
In [7]: str(u)
Out[7]: 'https:///google.com'
Or by set
:
In [2]: from furl import furl
In [3]: u = furl('google.com')
In [4]: u.set(scheme='https')
Out[4]: furl('https:///google.com')
In [5]: str(u)
Out[5]: 'https:///google.com'
@BradenM Thanks for weighing in! Your issue is, luckily, different than @jessebrennan's. It's this one: https://github.com/gruns/furl/issues/85.
In short, without a database of TLDs, furl can't determine whether a string with period(s) in it is a path or a domain.
As for @jessebrennan's original issue, that's definitely a bug. I need some time to look into it. Or, if either of you have time, debugging and/or pull requests most welcome!
Core issue fixed with #130. Huge thank you to Matt Murch. :clap:
I'm not really sure how to articulate this other than the example I encountered when messing around in the console.
I would not have expected this operation to change the value of
f
.