Gentoo Archives: gentoo-portage-dev

From: "W. Trevor King" <wking@×××××××.us>
To: gentoo-portage-dev@l.g.o
Cc: "W. Trevor King" <wking@×××××××.us>
Subject: [gentoo-portage-dev] [PATCH v2 0/3] Initial fetch() refactoring
Date: Sun, 19 Jan 2014 22:14:50
Message-Id: cover.1390169448.git.wking@tremily.us
In Reply to: Re: [gentoo-portage-dev] [PATCH 0/3] Initial fetch() refactoring by "W. Trevor King"
1 Following Sebastian's pyflakes and testing suggestions turned up a few
2 bugs in the _get_uris patch. Changes since v1:
3
4 Patch #1:
5
6 * Fixed:
7
8 """<summary>
9
10 to:
11
12 """
13 <summary>
14
15 and converted some from tabs to spaces where I'd missed them in v1.
16
17 Patch #3:
18
19 * Fixed docstrings as for patch #1.
20 * Fix 'myuri' → 'uri' in _get_file_uri_tuples.
21 * Fix 'cmirr' → 'm_uri' in _expand_mirror's urlunparse calls.
22 * Fix 'cmirr' → 'locmirr' in _expand_mirror's third_party_mirrors branch.
23 * Move “No known mirror” error from _get_uris to _expand_mirror.
24 * Calculate 'restrict', 'restrict_fetch', 'restrict_mirror', and
25 'force_mirror' in _get_uris.
26 * Remove 'force_mirror' from fetch, because it's only used in _get_uris.
27 * Fix 'custom_mirrors' → 'custommirrors' in _get_uris invocation.
28
29 After these changes, runtests.sh passes with only TODO messages on
30 Python 2.7, 3.2, and 3.3, although I'm not sure how thoroughly the
31 test suite covers fetch. There are also a few unrelated:
32
33 /usr/lib64/python3.3/xml/etree/ElementTree.py:1726:
34 DeprecationWarning: This method of XMLParser is deprecated.
35 Define doctype() method on the TreeBuilder target.
36 parser.feed(data)
37
38 warnings in the 3.3 results.
39
40 For folks who prefer Git fetches to the emailed patches, my current
41 series is at:
42
43 git://tremily.us/portage.git fetch-refactor
44
45 For those who prefer Git diffs to the above “changes since v1”, the v1
46 version of this series is tagged in my repository as
47 fetch-refactor-v1.
48
49 Sebastian, I'd normally cc you directly on v2, but I'm not sure what
50 the Portage team's conventions are here. Let me know if there is a
51 convention, or if you have a personal preference on direct mail vs the
52 list. I think projects that encourage cc-ing tend to have reasonable
53 numbers of NNTP readers, and I don't know where the
54 gentoo-portage-dev@ population falls on that issue.
55
56 W. Trevor King (3):
57 pym/portage/package/ebuild/fetch.py: Factor out
58 _get_checksum_failure_max_tries
59 pym/portage/package/ebuild/fetch.py: Factor out _get_fetch_resume_size
60 pym/portage/package/ebuild/fetch.py: Factor out _get_uris
61
62 pym/portage/package/ebuild/fetch.py | 318 +++++++++++++++++++++---------------
63 1 file changed, 189 insertions(+), 129 deletions(-)
64
65 --
66 1.8.5.2.8.g0f6c0d1

Replies