aboutsummaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* extractor.py: Replace sslfetch with plain requestsHEAD2.5.0masterMichał Górny2024-05-281-16/+10
| | | | | | | | | sslfetch was a thin NIH wrapper around requests, and it is unmaintained. Closes: https://bugs.gentoo.org/932145 Signed-off-by: Michał Górny <mgorny@gentoo.org> Closes: https://github.com/gentoo/mirrorselect/pull/1 Signed-off-by: Sam James <sam@gentoo.org>
* Rerun `pyupgrade` with `--py39-plus`2.4.0Sam James2023-08-072-13/+10
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Rerun `autopep8` with `--aggressiveSam James2023-08-073-13/+8
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Run `autopep8`Sam James2023-08-072-10/+11
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Reformat with `black`Sam James2023-08-077-1193/+1379
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Modernise shebangSam James2023-08-074-12/+8
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Drop old URLsSam James2023-08-071-5/+0
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Drop Python 2 supportSam James2023-08-072-30/+12
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* Run `pyupgrade`Sam James2023-08-076-27/+19
| | | | Signed-off-by: Sam James <sam@gentoo.org>
* extractor.py: cleanup py2 compatSam James2023-08-071-7/+2
| | | | | Bug: https://bugs.gentoo.org/911183 Signed-off-by: Sam James <sam@gentoo.org>
* extractor.py: parse proto from the uriPeter Levine2023-08-071-1/+17
| | | | | | | | | | | The protocol can be parsed from the URI so we can get rid of the protocol tag altogether. Bug: https://bugs.gentoo.org/911183 Suggested-by: Florian Schmaus <flow@gentoo.org> Suggested-by: Sam James <sam@gentoo.org> Signed-off-by: Peter Levine <plevine457@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
* main: Fix --all option parsingSam James2023-07-061-3/+8
| | | | | | | | | Avoid --all erroring out with "ERROR: Choose at most one of -s or -a". Bug: https://bugs.gentoo.org/872218 Fixes: 7caac017833b01e13028658effc502430c56d770 Thanks-to: <xpenev@gmail.com> Signed-off-by: Sam James <sam@gentoo.org>
* Some py2 compat. cleanupBrian Dolbec2022-06-231-1/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* main.py: Add indented backslash capability to multilne GENTOO_MIRRORSBrian Dolbec2022-05-311-1/+1
| | | | | | | | | For multiple mirrors, use backslashes list additional mirrors with indents for clarity. Gentoo-bug-url: https://bugs.gentoo.org/543814 Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* configs.py: Add missing https:// to the re.compileBrian Dolbec2022-05-311-1/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* configs.py: Remove py2 codeBrian Dolbec2022-05-311-4/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* Remove remaining SYNC codeBrian Dolbec2022-05-312-9/+4
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* selectors.py: Change general exception output to print_warnBrian Dolbec2022-05-311-2/+2
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* version.py: Bump base version to 2.3.0 before releaseBrian Dolbec2022-05-301-1/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* selectors.py: Fix bug 698528 clear screen on dialog exitBrian Dolbec2022-05-301-0/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* main.py: Fix bug 600572 Remove SYNC variable usageBrian Dolbec2022-05-301-5/+5
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* selectors.py: Bug 800149. Add general exception for any other server errorBrian Dolbec2022-05-301-0/+5
| | | | | | | | Catch any other server errors so that mirrorselect will ignore that server without crashing. It will also output the error and request it to be reported. Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* Apply bug 730994 https filtering patchBrian Dolbec2022-05-302-3/+6
| | | | | Author: Peter Levine Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* Remove obsolete __future__ import of print_functionBrian Dolbec2022-05-303-8/+0
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* selectors.py: Fix bug 771963 incorrect comparisonBrian Dolbec2022-05-301-2/+2
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* main.py: Add a -a, -s combo sanity checkBrian Dolbec2020-06-031-0/+3
| | | | | | | | | | This is to prevent all mirrors from being added to make.conf when the -s option is also enabled. The -a option takes priority in the code, so there is never any selection done. This options check will error out when both options are enabled. Reported by: toralf on #gentoo-dev Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* write_make_conf: fix infinite loop (bug 698470)Zac Medico2019-10-241-0/+2
| | | | | | Fixes: 42238f4ff13a ("write_make_conf: support multi-line GENTOO_MIRRORS (bug 543814)") Bug: https://bugs.gentoo.org/698470 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* Update version for 2.2.5 release2.2.6Zac Medico2019-07-161-1/+1
| | | | Signed-off-by: Zac Medico <zmedico@gentoo.org>
* netselect: make netselect ipv6 support optionalZac Medico2019-07-121-4/+11
| | | | | | | | | | | | Since netselect with ipv6 support does not work on a system where ipv6 is disabled, use a NETSELECT_SUPPORTS_IPV4_IPV6 variable to optionally enable the use of netselect -4/-6 options. The ebuild will use sed to set NETSELECT_SUPPORTS_IPV4_IPV6 = True when USE=ipv6 is enabled, and will have a dependency like RDEPEND=">=net-analyzer/netselect-0.4[ipv6(+)?]". Bug: https://bugs.gentoo.org/688214 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* Update version for 2.2.5 release2.2.5Zac Medico2019-05-271-1/+1
| | | | Signed-off-by: Zac Medico <zmedico@gentoo.org>
* get_filesystem_mirrors: fix DeprecationWarning: invalid escape sequence \Zac Medico2019-05-271-1/+1
| | | | Signed-off-by: Zac Medico <zmedico@gentoo.org>
* netselect: use -4/-6 options (bug 582508)Zac Medico2019-05-271-3/+12
| | | | | | | Requires >=net-analyzer/netselect-0.4[ipv6(+)]. Bug: https://bugs.gentoo.org/582508 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* write_make_conf: support multi-line GENTOO_MIRRORS (bug 543814)Zac Medico2019-05-271-6/+27
| | | | | | | Use shlex to support multi-line GENTOO_MIRRORS assignments. Bug: https://bugs.gentoo.org/543814 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* Update version for 2.2.4 release2.2.4Zac Medico2019-02-131-1/+1
| | | | Signed-off-by: Zac Medico <zmedico@gentoo.org>
* selectors.py: Give urllib hostname info (bug 604968)Michel Ganguin2019-02-131-2/+8
| | | | | | | | | | | | Give urllib hostname info such that: * it will not fail when using HTTPS because of hostname mismatch (CertificateError) * it will not fail when the server is a virtualhost * it will not fail when the server validates ssl SNI Bug: https://bugs.gentoo.org/566778 Bug: https://bugs.gentoo.org/604968 Bug: https://bugs.gentoo.org/639156 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* selectors.py: handle ssl.CertificateError (bug 639156)Xiami2019-02-131-1/+1
| | | | | Bug: https://bugs.gentoo.org/639156 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* selectors.py: handle ssl.CertificateError (bug 604968)Daniel Harding2019-02-121-1/+2
| | | | | Bug: https://bugs.gentoo.org/604968 Signed-off-by: Zac Medico <zmedico@gentoo.org>
* Update version for 2.2.3 releaseZac Medico2019-01-231-2/+2
| | | | Signed-off-by: Zac Medico <zmedico@gentoo.org>
* Mirrorselect: add 'exclude' option to allow excluding hosts from mirrors list.i.Dark_Templar2018-05-261-0/+7
|
* main.py: Remove obsolete 'SYNC' option2.2.3Brian Dolbec2017-07-181-4/+1
| | | | Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* main.py: fix isinstance(hosts[i], bytes)Zac Medico2017-02-201-1/+1
| | | | Fixes: c91509d823c2 ("main.py: Fix Bytes error in hosts list bug 610016")
* extractor.py: Add climit param for >=ssl-fetch-0.4Brian Dolbec2017-02-201-1/+1
|
* main.py: Fix Bytes error in hosts list bug 610016zakalwe2017-02-201-2/+3
| | | | | | | The code was only checking the first host which was not a bytes instance in that case. This resulted in the remaining host entries to not be decoded. Signed-off-by: Brian Dolbec <dolsen@gentoo.org>
* deeptime: cancel alarm signal before handling socket.error (bug 523312)Zac Medico2016-11-131-10/+12
| | | | | | | | In order to avoid a race condition, the alarm signal must be cancelled before socket.error is handled. X-Gentoo-Bug: 523312 X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=523312
* Add missed output mode function assignment.Brian Dolbec2015-01-271-0/+1
|
* update version with latest release as a baseBrian Dolbec2015-01-261-1/+1
|
* Update for ssl-fetch api changeBrian Dolbec2015-01-261-0/+1
|
* Ssl-fetch renamed args-* to kwargs-*Brian Dolbec2014-05-281-2/+2
|
* Update for recent ssl-fetch changesBrian Dolbec2014-05-281-1/+9
|
* selectors.py: Add IncompleteRead exception2.2.1Brian Dolbec2014-05-041-3/+11
| | | Improve output formatting.