summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Peterson <benjamin@python.org>2014-09-11 17:00:08 -0400
committerBenjamin Peterson <benjamin@python.org>2014-09-11 17:00:08 -0400
commite4c848983ef9bc79802aa0c8d7ba4c8c78685c65 (patch)
treef78ccf6a47f8ac76ef92dd3de6e7ea75e3ed8bce
parentdd219bfd247287287646a9c00687ec67ddc5a9a9 (diff)
downloadsix-e4c848983ef9bc79802aa0c8d7ba4c8c78685c65.tar.gz
add a bunch of urlparse uses_* moves
-rw-r--r--CHANGES2
-rw-r--r--documentation/index.rst5
-rw-r--r--six.py5
3 files changed, 12 insertions, 0 deletions
diff --git a/CHANGES b/CHANGES
index 01c78c4..4bce92b 100644
--- a/CHANGES
+++ b/CHANGES
@@ -6,6 +6,8 @@ This file lists the changes in each six version.
Development version
-------------------
+- Add six.urllib.parse.uses_(fragment|netloc|params|query|relative).
+
- Issue #88: Fix add_metaclass when the class has __slots__ containing
"__weakref__" or "__dict__".
diff --git a/documentation/index.rst b/documentation/index.rst
index e2bdcc3..9acea50 100644
--- a/documentation/index.rst
+++ b/documentation/index.rst
@@ -615,6 +615,11 @@ Contains functions from Python 3's :mod:`py3:urllib.parse` and Python 2's:
* :func:`py2:urlparse.urlsplit`
* :func:`py2:urlparse.urlunsplit`
* :func:`py2:urlparse.splitquery`
+* :func:`py2:urlparse.uses_fragment`
+* :func:`py2:urlparse.uses_netloc`
+* :func:`py2:urlparse.uses_params`
+* :func:`py2:urlparse.uses_query`
+* :func:`py2:urlparse.uses_relative`
and :mod:`py2:urllib`:
diff --git a/six.py b/six.py
index 304f618..12a071b 100644
--- a/six.py
+++ b/six.py
@@ -322,6 +322,11 @@ _urllib_parse_moved_attributes = [
MovedAttribute("splitquery", "urllib", "urllib.parse"),
MovedAttribute("splittag", "urllib", "urllib.parse"),
MovedAttribute("splituser", "urllib", "urllib.parse"),
+ MovedAttribute("uses_fragment", "urlparse", "urllib.parse"),
+ MovedAttribute("uses_netloc", "urlparse", "urllib.parse"),
+ MovedAttribute("uses_params", "urlparse", "urllib.parse"),
+ MovedAttribute("uses_query", "urlparse", "urllib.parse"),
+ MovedAttribute("uses_relative", "urlparse", "urllib.parse"),
]
for attr in _urllib_parse_moved_attributes:
setattr(Module_six_moves_urllib_parse, attr.name, attr)