-
-
Notifications
You must be signed in to change notification settings - Fork 168
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Exterminate offensive references from the project
This change doesn't edit the test semantics, nor does it make any functional changes. It removes references to the ruscist culture that are as triggering to a lot of people as using "slave/master", "blacklist/whitelist" terminology. In particular, this gets rid of a link to the website that exists to justify ethnic cleansing in Crimea and genocides in Ukraine, being sponsored by the government of the terrorist state of muscovy. Ref #955 (comment)
- Loading branch information
Showing
8 changed files
with
182 additions
and
169 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -54,8 +54,8 @@ But for *non-ascii* case *encoding* is applied. | |
|
||
.. doctest:: | ||
|
||
>>> str(URL('http://εμπορικόσήμα.eu/путь/這裡')) | ||
'http://xn--jxagkqfkduily1i.eu/%D0%BF%D1%83%D1%82%D1%8C/%E9%80%99%E8%A3%A1' | ||
>>> str(URL('http://εμπορικόσήμα.eu/шлях/這裡')) | ||
'http://xn--jxagkqfkduily1i.eu/%D1%88%D0%BB%D1%8F%D1%85/%E9%80%99%E8%A3%A1' | ||
|
||
The same is true for *user*, *password*, *query* and *fragment* parts of URL. | ||
|
||
|
@@ -70,11 +70,11 @@ Use :meth:`~URL.human_repr` for getting human readable representation: | |
|
||
.. doctest:: | ||
|
||
>>> url = URL('http://εμπορικόσήμα.eu/путь/這裡') | ||
>>> url = URL('http://εμπορικόσήμα.eu/шлях/這裡') | ||
>>> str(url) | ||
'http://xn--jxagkqfkduily1i.eu/%D0%BF%D1%83%D1%82%D1%8C/%E9%80%99%E8%A3%A1' | ||
'http://xn--jxagkqfkduily1i.eu/%D1%88%D0%BB%D1%8F%D1%85/%E9%80%99%E8%A3%A1' | ||
>>> url.human_repr() | ||
'http://εμπορικόσήμα.eu/путь/這裡' | ||
'http://εμπορικόσήμα.eu/шлях/這裡' | ||
|
||
|
||
.. note:: | ||
|
@@ -120,8 +120,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
>>> URL('http://[email protected]').user | ||
'john' | ||
>>> URL('http://андрей@example.com').user | ||
'андрей' | ||
>>> URL('http://бажан@example.com').user | ||
'бажан' | ||
>>> URL('http://example.com').user is None | ||
True | ||
|
||
|
@@ -133,8 +133,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://андрей@example.com').raw_user | ||
'%D0%B0%D0%BD%D0%B4%D1%80%D0%B5%D0%B9' | ||
>>> URL('http://довбуш@example.com').raw_user | ||
'%D0%B4%D0%BE%D0%B2%D0%B1%D1%83%D1%88' | ||
>>> URL('http://example.com').raw_user is None | ||
True | ||
|
||
|
@@ -147,7 +147,7 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
>>> URL('http://john:[email protected]').password | ||
'pass' | ||
>>> URL('http://андрей:пароль@example.com').password | ||
>>> URL('http://степан:пароль@example.com').password | ||
'пароль' | ||
>>> URL('http://example.com').password is None | ||
True | ||
|
@@ -265,8 +265,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
>>> URL('http://example.com/path/to').path | ||
'/path/to' | ||
>>> URL('http://example.com/путь/сюда').path | ||
'/путь/сюда' | ||
>>> URL('http://example.com/шлях/сюди').path | ||
'/шлях/сюди' | ||
>>> URL('http://example.com').path | ||
'/' | ||
|
||
|
@@ -287,8 +287,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь/сюда?ключ=знач').raw_path_qs | ||
'/%D0%BF%D1%83%D1%82%D1%8C/%D1%81%D1%8E%D0%B4%D0%B0?%D0%BA%D0%BB%D1%8E%D1%87=%D0%B7%D0%BD%D0%B0%D1%87' | ||
>>> URL('http://example.com/шлях/сюди?ключ=знач').raw_path_qs | ||
'/%D1%88%D0%BB%D1%8F%D1%85/%D1%81%D1%8E%D0%B4%D0%B8?%D0%BA%D0%BB%D1%8E%D1%87=%D0%B7%D0%BD%D0%B0%D1%87' | ||
|
||
.. versionadded:: 0.15 | ||
|
||
|
@@ -298,8 +298,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь/сюда').raw_path | ||
'/%D0%BF%D1%83%D1%82%D1%8C/%D1%81%D1%8E%D0%B4%D0%B0' | ||
>>> URL('http://example.com/шлях/сюди').raw_path | ||
'/%D1%88%D0%BB%D1%8F%D1%85/%D1%81%D1%8E%D0%B4%D0%B8' | ||
|
||
|
||
.. attribute:: URL.query_string | ||
|
@@ -333,8 +333,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
>>> URL('http://example.com/path#fragment').fragment | ||
'fragment' | ||
>>> URL('http://example.com/path#якорь').fragment | ||
'якорь' | ||
>>> URL('http://example.com/path#якір').fragment | ||
'якір' | ||
>>> URL('http://example.com/path').fragment | ||
'' | ||
|
||
|
@@ -344,8 +344,8 @@ There are two kinds of properties: *decoded* and *encoded* (with | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/path#якорь').raw_fragment | ||
'%D1%8F%D0%BA%D0%BE%D1%80%D1%8C' | ||
>>> URL('http://example.com/path#якір').raw_fragment | ||
'%D1%8F%D0%BA%D1%96%D1%80' | ||
|
||
|
||
|
||
|
@@ -361,8 +361,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
>>> URL('http://example.com/path/to').parts | ||
('/', 'path', 'to') | ||
>>> URL('http://example.com/путь/сюда').parts | ||
('/', 'путь', 'сюда') | ||
>>> URL('http://example.com/шлях/сюди').parts | ||
('/', 'шлях', 'сюди') | ||
>>> URL('http://example.com').parts | ||
('/',) | ||
|
||
|
@@ -373,8 +373,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь/сюда').raw_parts | ||
('/', '%D0%BF%D1%83%D1%82%D1%8C', '%D1%81%D1%8E%D0%B4%D0%B0') | ||
>>> URL('http://example.com/шлях/сюди').raw_parts | ||
('/', '%D1%88%D0%BB%D1%8F%D1%85', '%D1%81%D1%8E%D0%B4%D0%B8') | ||
|
||
.. attribute:: URL.name | ||
|
||
|
@@ -384,8 +384,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
>>> URL('http://example.com/path/to').name | ||
'to' | ||
>>> URL('http://example.com/путь/сюда').name | ||
'сюда' | ||
>>> URL('http://example.com/шлях/сюди').name | ||
'сюди' | ||
>>> URL('http://example.com/path/').name | ||
'' | ||
|
||
|
@@ -395,8 +395,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь/сюда').raw_name | ||
'%D1%81%D1%8E%D0%B4%D0%B0' | ||
>>> URL('http://example.com/шлях/сюди').raw_name | ||
'%D1%81%D1%8E%D0%B4%D0%B8' | ||
|
||
.. attribute:: URL.suffix | ||
|
||
|
@@ -406,8 +406,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
>>> URL('http://example.com/path/to.txt').suffix | ||
'.txt' | ||
>>> URL('http://example.com/путь.сюда').suffix | ||
'.сюда' | ||
>>> URL('http://example.com/шлях.сюди').suffix | ||
'.сюди' | ||
>>> URL('http://example.com/path').suffix | ||
'' | ||
|
||
|
@@ -417,8 +417,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь.сюда').raw_suffix | ||
'.%D1%81%D1%8E%D0%B4%D0%B0' | ||
>>> URL('http://example.com/шлях.сюди').raw_suffix | ||
'.%D1%81%D1%8E%D0%B4%D0%B8' | ||
|
||
.. attribute:: URL.suffixes | ||
|
||
|
@@ -428,8 +428,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
>>> URL('http://example.com/path/to.tar.gz').suffixes | ||
('.tar', '.gz') | ||
>>> URL('http://example.com/путь.тут.да').suffixes | ||
('.тут', '.да') | ||
>>> URL('http://example.com/шлях.тут.ось').suffixes | ||
('.тут', '.ось') | ||
>>> URL('http://example.com/path').suffixes | ||
() | ||
|
||
|
@@ -439,8 +439,8 @@ For *path* and *query* *yarl* supports additional helpers: | |
|
||
.. doctest:: | ||
|
||
>>> URL('http://example.com/путь.тут.да').raw_suffixes | ||
('.%D1%82%D1%83%D1%82', '.%D0%B4%D0%B0') | ||
>>> URL('http://example.com/шлях.тут.ось').raw_suffixes | ||
('.%D1%82%D1%83%D1%82', '.%D0%BE%D1%81%D1%8C') | ||
|
||
|
||
.. attribute:: URL.query | ||
|
@@ -546,8 +546,8 @@ section generates a new :class:`URL` instance. | |
|
||
>>> URL('http://user:[email protected]').with_user('new_user') | ||
URL('http://new_user:[email protected]') | ||
>>> URL('http://user:[email protected]').with_user('вася') | ||
URL('http://%D0%B2%D0%B0%D1%81%D1%8F:[email protected]') | ||
>>> URL('http://user:[email protected]').with_user('олекса') | ||
URL('http://%D0%BE%D0%BB%D0%B5%D0%BA%D1%81%D0%B0:[email protected]') | ||
>>> URL('http://user:[email protected]').with_user(None) | ||
URL('http://example.com') | ||
|
||
|
@@ -739,8 +739,8 @@ section generates a new :class:`URL` instance. | |
|
||
>>> URL('http://example.com/path#frag').with_fragment('anchor') | ||
URL('http://example.com/path#anchor') | ||
>>> URL('http://example.com/path#frag').with_fragment('якорь') | ||
URL('http://example.com/path#%D1%8F%D0%BA%D0%BE%D1%80%D1%8C') | ||
>>> URL('http://example.com/path#frag').with_fragment('якір') | ||
URL('http://example.com/path#%D1%8F%D0%BA%D1%96%D1%80') | ||
>>> URL('http://example.com/path#frag').with_fragment(None) | ||
URL('http://example.com/path') | ||
|
||
|
@@ -755,8 +755,8 @@ section generates a new :class:`URL` instance. | |
|
||
>>> URL('http://example.com/path/to?arg#frag').with_name('new') | ||
URL('http://example.com/path/new') | ||
>>> URL('http://example.com/path/to').with_name('имя') | ||
URL('http://example.com/path/%D0%B8%D0%BC%D1%8F') | ||
>>> URL('http://example.com/path/to').with_name("ім'я") | ||
URL('http://example.com/path/%D1%96%D0%BC%27%D1%8F') | ||
|
||
.. method:: URL.with_suffix(suffix) | ||
|
||
|
@@ -769,8 +769,8 @@ section generates a new :class:`URL` instance. | |
|
||
>>> URL('http://example.com/path/to?arg#frag').with_suffix('.doc') | ||
URL('http://example.com/path/to.doc') | ||
>>> URL('http://example.com/path/to').with_suffix('.cуффикс') | ||
URL('http://example.com/path/to.c%D1%83%D1%84%D1%84%D0%B8%D0%BA%D1%81') | ||
>>> URL('http://example.com/path/to').with_suffix('.cуфікс') | ||
URL('http://example.com/path/to.c%D1%83%D1%84%D1%96%D0%BA%D1%81') | ||
|
||
.. attribute:: URL.parent | ||
|
||
|
@@ -816,9 +816,9 @@ The path is encoded if needed. | |
URL('http://example.com/path/to/subpath') | ||
>>> url.parts | ||
('/', 'path', 'to', 'subpath') | ||
>>> url = URL('http://example.com/path?arg#frag') / 'сюда' | ||
>>> url = URL('http://example.com/path?arg#frag') / 'сюди' | ||
>>> url | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B0') | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B8') | ||
|
||
.. method:: URL.joinpath(*other, encoded=False) | ||
|
||
|
@@ -835,12 +835,12 @@ The path is encoded if needed. | |
URL('http://example.com/path/to/subpath') | ||
>>> url.parts | ||
('/', 'path', 'to', 'subpath') | ||
>>> url = URL('http://example.com/path?arg#frag').joinpath('сюда') | ||
>>> url = URL('http://example.com/path?arg#frag').joinpath('сюди') | ||
>>> url | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B0') | ||
>>> url = URL('http://example.com/path').joinpath('%D1%81%D1%8E%D0%B4%D0%B0', encoded=True) | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B8') | ||
>>> url = URL('http://example.com/path').joinpath('%D1%81%D1%8E%D0%B4%D0%B8', encoded=True) | ||
>>> url | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B0') | ||
URL('http://example.com/path/%D1%81%D1%8E%D0%B4%D0%B8') | ||
|
||
.. versionadded:: 1.9 | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.