cc-archive / cc-link-checker

Automated link checker for legalcode and license URLs
MIT License
9 stars 13 forks source link

update to python 3.9 and update python packages #155

Closed TimidRobot closed 2 years ago

TimidRobot commented 2 years ago

Fixes

Fixes #146, fixes #151, fixes #153, fixes #154

Description

update to python 3.9 and update python packages

Technical Details

pipenv run pip list
Package            Version   Editable project location
------------------ --------- ----------------------------------------------
attrs              21.4.0
beautifulsoup4     4.10.0
black              22.1.0
certifi            2021.10.8
charset-normalizer 2.0.12
click              8.0.4
flake8             4.0.1
gevent             21.12.0
greenlet           1.1.2
grequests          0.6.0
idna               3.3
importlib-metadata 4.11.2
iniconfig          1.1.1
isort              5.10.1
junit-xml          1.9
link-checker       0.1.0     /Users/tim/CreativeCommons/git/cc-link-checker
lxml               4.8.0
mccabe             0.6.1
mypy-extensions    0.4.3
packaging          21.3
pathspec           0.9.0
pip                22.0.3
platformdirs       2.5.1
pluggy             1.0.0
py                 1.11.0
pycodestyle        2.8.0
pyflakes           2.4.0
pyparsing          3.0.7
pytest             7.0.1
requests           2.27.1
setuptools         60.9.3
six                1.16.0
soupsieve          2.3.1
tomli              2.0.1
typing_extensions  4.1.1
urllib3            1.26.8
wheel              0.37.1
zipp               3.7.0
zope.event         4.5.0
zope.interface     5.4.0

Tests

pipenv run pytest -vv
=============================== test session starts ================================
platform darwin -- Python 3.9.10, pytest-7.0.1, pluggy-1.0.0 -- [REDACTED]
cachedir: .pytest_cache
rootdir: [REDACTED]/cc-link-checker
collected 29 items                                                                 

link_checker/tests/test_link_checker.py::test_parser_shared PASSED           [  3%]
link_checker/tests/test_link_checker.py::test_parser_shared_licenses PASSED  [  6%]
link_checker/tests/test_link_checker.py::test_parser_shared_rdf PASSED       [ 10%]
link_checker/tests/test_link_checker.py::test_parser_shared_reporting PASSED [ 13%]
link_checker/tests/test_utils.py::test_get_github_legalcode PASSED           [ 17%]
link_checker/tests/test_utils.py::test_create_base_link[by-nc-nd_2.0] PASSED [ 20%]
link_checker/tests/test_utils.py::test_create_base_link[by-nc-nd_4.0_cs] PASSED [ 24%]
link_checker/tests/test_utils.py::test_create_base_link[by-nc-nd_3.0_rs_sr-Latn] PASSED [ 27%]
link_checker/tests/test_utils.py::test_create_base_link[samplingplus_1.0] PASSED [ 31%]
link_checker/tests/test_utils.py::test_create_base_link[samplingplus_1.0_br] PASSED [ 34%]
link_checker/tests/test_utils.py::test_create_base_link[zero_1.0] PASSED     [ 37%]
link_checker/tests/test_utils.py::test_output_write PASSED                   [ 41%]
link_checker/tests/test_utils.py::test_output_issues_summary PASSED          [ 44%]
link_checker/tests/test_utils.py::test_create_absolute_link[./license-https://www.demourl.com/dir1/license] PASSED [ 48%]
link_checker/tests/test_utils.py::test_create_absolute_link[../-https://www.demourl.com/] PASSED [ 51%]
link_checker/tests/test_utils.py::test_create_absolute_link[/index-https://www.demourl.com/index] PASSED [ 55%]
link_checker/tests/test_utils.py::test_create_absolute_link[//demo.url-https://demo.url] PASSED [ 58%]
link_checker/tests/test_utils.py::test_create_absolute_link[https://creativecommons.org-https://creativecommons.org] PASSED [ 62%]
link_checker/tests/test_utils.py::test_get_scrapable_links PASSED            [ 65%]
link_checker/tests/test_utils.py::test_exception_handler PASSED              [ 68%]
link_checker/tests/test_utils.py::test_map_links_file PASSED                 [ 72%]
link_checker/tests/test_utils.py::test_write_response PASSED                 [ 75%]
link_checker/tests/test_utils.py::test_get_memoized_result PASSED            [ 79%]
link_checker/tests/test_utils.py::test_memoize_result PASSED                 [ 82%]
link_checker/tests/test_utils.py::test_request_text[https://www.google.com:82-Timeout] PASSED [ 86%]
link_checker/tests/test_utils.py::test_request_text[http://doesnotexist.google.com-ConnectionError] PASSED [ 89%]
link_checker/tests/test_utils.py::test_request_local_text PASSED             [ 93%]
link_checker/tests/test_utils.py::test_output_test_summary[3-map_links0] PASSED [ 96%]
link_checker/tests/test_utils.py::test_output_test_summary[0-map_links1] PASSED [100%]

================================ 29 passed in 9.65s ================================

Checklist

- [x] My pull request has a descriptive title (not a vague title like `Update index.md`). - [x] My pull request targets the *default* branch of the repository (`main` or `master`). - [x] My commit messages follow [best practices][best_practices]. - [x] My code follows the established code style of the repository. - [ ] I added or updated tests for the changes I made (if applicable). - [x] I added or updated documentation (if applicable). - [x] I tried running the project locally and verified that there are no visible errors. [best_practices]:https://gist.github.com/robertpainsi/b632364184e70900af4ab688decf6f53 ## Developer Certificate of Origin

For the purposes of this DCO, "license" is equivalent to "license or public domain dedication," and "open source license" is equivalent to "open content license or public domain dedication."

Developer Certificate of Origin ``` Developer Certificate of Origin Version 1.1 Copyright (C) 2004, 2006 The Linux Foundation and its contributors. 1 Letterman Drive Suite D4700 San Francisco, CA, 94129 Everyone is permitted to copy and distribute verbatim copies of this license document, but changing it is not allowed. Developer's Certificate of Origin 1.1 By making a contribution to this project, I certify that: (a) The contribution was created in whole or in part by me and I have the right to submit it under the open source license indicated in the file; or (b) The contribution is based upon previous work that, to the best of my knowledge, is covered under an appropriate open source license and I have the right under that license to submit that work with modifications, whether created in whole or in part by me, under the same open source license (unless I am permitted to submit under a different license), as indicated in the file; or (c) The contribution was provided directly to me by some other person who certified (a), (b) or (c) and I have not modified it. (d) I understand and agree that this project and the contribution are public and that a record of the contribution (including all personal information I submit with it, including my sign-off) is maintained indefinitely and may be redistributed consistent with this project or the open source license(s) involved. ```