diff --git a/tests/test_download.py b/tests/test_download.py index 097ae813..1159e436 100644 --- a/tests/test_download.py +++ b/tests/test_download.py @@ -419,7 +419,7 @@ class SingletonTestServer(ub.NiceRepr): independent IPython session. CommandLine: - xdoctest -m /home/joncrall/code/ubelt/tests/test_download.py SingletonTestServer + xdoctest -m tests/test_download.py SingletonTestServer Note: We rely on python process close mechanisms to clean this server up. @@ -463,7 +463,7 @@ def __init__(self): def find_free_port(): """ References: - https://stackoverflow.com/questions/1365265/on-localhost-how-do-i-pick-a-free-port-number + .. [SO1365265] https://stackoverflow.com/questions/1365265/on-localhost-how-do-i-pick-a-free-port-number """ with closing(socket.socket(socket.AF_INET, socket.SOCK_STREAM)) as s: s.bind(('', 0)) diff --git a/tests/test_hash.py b/tests/test_hash.py index 4490d709..62ef7fee 100644 --- a/tests/test_hash.py +++ b/tests/test_hash.py @@ -18,7 +18,7 @@ def _benchmark(): On 64-bit processors sha512 may be faster than sha256 References: - https://crypto.stackexchange.com/questions/26336/sha512-faster-than-sha256 + .. [SE26336] https://crypto.stackexchange.com/questions/26336/sha512-faster-than-sha256 """ result = ub.AutoOrderedDict() algos = ['sha1', 'sha256', 'sha512'] @@ -463,10 +463,10 @@ def test_compatible_hash_bases(): WITH PADDING AND VIA BYTE FORM, NOT INTEGER FORM. References: - https://stackoverflow.com/questions/43920799/convert-byte-to-base64-and-ascii-in-python - https://github.com/multiformats/multibase - https://stackoverflow.com/questions/6916805/why-does-a-base64-encoded-string-have-an-sign-at-the-end - https://github.com/semente/python-baseconv + .. [SO43920799] https://stackoverflow.com/questions/43920799/convert-byte-to-base64-and-ascii-in-python + .. [MultiBase] https://github.com/multiformats/multibase + .. [SO6916805] https://stackoverflow.com/questions/6916805/why-does-a-base64-encoded-string-have-an-sign-at-the-end + .. [SementeBaseConv] https://github.com/semente/python-baseconv """ import pytest pytest.skip('FIXME THIS ISSUE IS NOT RESOLVE YET.') diff --git a/ubelt/_win32_links.py b/ubelt/_win32_links.py index 77894c17..143108eb 100644 --- a/ubelt/_win32_links.py +++ b/ubelt/_win32_links.py @@ -2,13 +2,12 @@ For dealing with symlinks, junctions, and hard-links on windows. References: - https://stackoverflow.com/questions/18883892/batch-file-windows-cmd-exe-test-if-a-directory-is-a-link-symlink - - https://stackoverflow.com/questions/21561850/python-test-for-junction-point-target - http://timgolden.me.uk/python/win32_how_do_i/see_if_two_files_are_the_same_file.html - https://stackoverflow.com/questions/6260149/os-symlink-support-in-windows - https://msdn.microsoft.com/en-us/library/windows/desktop/aa365006(v=vs.85).aspx - https://superuser.com/a/902082/215232 + .. [SO18883892] https://stackoverflow.com/questions/18883892/batch-file-windows-cmd-exe-test-if-a-directory-is-a-link-symlink + .. [SO21561850] https://stackoverflow.com/questions/21561850/python-test-for-junction-point-target + .. [WinTwoFilesSame] http://timgolden.me.uk/python/win32_how_do_i/see_if_two_files_are_the_same_file.html + .. [SO6260149] https://stackoverflow.com/questions/6260149/os-symlink-support-in-windows + .. [WinDesktopAA365006] https://msdn.microsoft.com/en-us/library/windows/desktop/aa365006(v=vs.85).aspx + .. [SU902082] https://superuser.com/a/902082/215232 Weird Behavior: - [ ] In many cases using the win32 API seems to result in privilege errors diff --git a/ubelt/progiter.py b/ubelt/progiter.py index 87d274ea..5806c83c 100644 --- a/ubelt/progiter.py +++ b/ubelt/progiter.py @@ -362,7 +362,7 @@ class ProgIter(_TQDMCompat, _BackwardsCompat): tqdm - https://pypi.python.org/pypi/tqdm References: - http://datagenetics.com/blog/february12017/index.html + .. [DatagenProgBars] http://datagenetics.com/blog/february12017/index.html Example: >>> # doctest: +SKIP diff --git a/ubelt/util_colors.py b/ubelt/util_colors.py index 6aa2b21c..4742a662 100644 --- a/ubelt/util_colors.py +++ b/ubelt/util_colors.py @@ -137,7 +137,7 @@ def _rich_highlight(text, lexer_name): # nocover Alternative rich-based highlighter References: - https://github.com/Textualize/rich/discussions/3076 + .. [RichDiscuss3076] https://github.com/Textualize/rich/discussions/3076 """ from rich.syntax import Syntax from rich.console import Console diff --git a/ubelt/util_dict.py b/ubelt/util_dict.py index ef7d5534..69742259 100644 --- a/ubelt/util_dict.py +++ b/ubelt/util_dict.py @@ -394,7 +394,7 @@ def dict_union(*args): dictionary union (or any other dictionary set operator). References: - https://stackoverflow.com/questions/38987/merge-two-dict + .. [SO38987] https://stackoverflow.com/questions/38987/merge-two-dict SeeAlso: :func:`collections.ChainMap` - a standard python builtin data structure diff --git a/ubelt/util_indexable.py b/ubelt/util_indexable.py index cbf8c624..3096833d 100644 --- a/ubelt/util_indexable.py +++ b/ubelt/util_indexable.py @@ -217,7 +217,7 @@ def throw(self, typ, val=None, tb=None): # type: ignore StopIteration References: - https://docs.python.org/3/reference/expressions.html#generator.throw + .. [GeneratorThrow] https://docs.python.org/3/reference/expressions.html#generator.throw """ raise StopIteration diff --git a/ubelt/util_str.py b/ubelt/util_str.py index 1a27a7ec..67e20c13 100644 --- a/ubelt/util_str.py +++ b/ubelt/util_str.py @@ -192,7 +192,7 @@ def ensure_unicode(text): str References: - [SO_12561063] http://stackoverflow.com/questions/12561063/extract-data-from-file + .. [SO_12561063] http://stackoverflow.com/questions/12561063/extract-data-from-file Example: >>> from ubelt.util_str import *