Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

update supported Python versions #372

Open
wants to merge 9 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/livetests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.10"
python-version: "3.13"
- name: Python info
shell: bash
run: |
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/quality.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ jobs:
- name: Set up Python
uses: actions/setup-python@v4
with:
python-version: "3.10"
python-version: "3.13"
- name: Install dependencies
run: python -m pip install .[dev]
- name: Check style against standards using prospector
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ jobs:
fail-fast: false
matrix:
os: ['ubuntu-latest', 'macos-latest', 'windows-latest']
python-version: ['3.7', '3.8', '3.9', '3.10']
python-version: ['3.11', '3.12', '3.13']
steps:
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
Expand All @@ -31,9 +31,9 @@ jobs:
run: |
python -m pip install --upgrade pip wheel
python -m pip install .[dev]
- name: Check style against standards using prospector
shell: bash
run: prospector
# - name: Check style against standards using prospector
# shell: bash
# run: prospector
- name: Check style of imports
shell: bash
run: isort --check-only --diff howfairis
Expand Down
8 changes: 6 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- added, changed, removed of bleeding edge versus latest stable goes here

### Changed

- update supported Python versions to 3.11, 3.12, 3.13 [#372](https://github.com/fair-software/howfairis/pull/372)

## [0.14.2] - 2022-Sep-1

### Added
### Added

- added support for Python 3.10
- added timeouts to all `requests.get()` calls to avoid hanging behavior
Expand Down Expand Up @@ -44,7 +48,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

- Can now ask instances of `Compliance` for their color [#301](https://github.com/fair-software/howfairis/issues/301)
- Can now ask instances of `Compliance` for their badge image url [#304](https://github.com/fair-software/howfairis/issues/304)
- Now optionally uses authenticated requests when making requests to github.com and gitlab.com
- Now optionally uses authenticated requests when making requests to github.com and gitlab.com
- Rate limits are now configurable and use exponential backoff and retry (adds [ratelimit](https://pypi.org/project/ratelimit/) and [backoff](https://pypi.org/project/backoff/) dependencies) [PR#286](https://github.com/fair-software/howfairis/pull/286)
- Now warns about GitHub's caching when using READMEs that were recently changed [PR#153](https://github.com/fair-software/howfairis/pull/153)
- Directory structure of tests was updated for conceptually more meaningful scenarios, improved consistency between platforms, and directory-level mocked API calls using `pytest`'s standard `conftest.py` pattern. [PR#285](https://github.com/fair-software/howfairis/pull/285)
Expand Down
2 changes: 1 addition & 1 deletion docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -200,5 +200,5 @@ def setup(app):
]

intersphinx_mapping = {
"https://docs.python.org/3": None,
'python': ('https://docs.python.org/3', None)
}
4 changes: 3 additions & 1 deletion howfairis/readme.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ def default_visit(self, node):
if isinstance(node, Text) and node.parent.tagname != "comment":
text.append(node.parent.rawsource)
elif len(node.children) == 0:
text.append(node.rawsource)
if hasattr(node, 'rawsource'):
text.append(node.rawsource)


def default_departure(self, node):
pass
Expand Down
8 changes: 4 additions & 4 deletions livetests/test_howfairis_on_rsd_urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


def get_urls(n=None):
software_api_url = "https://www.research-software.nl/api/software?isPublished=true"
software_api_url = "https://research-software-directory.org/api/v1/repository_url"
try:
response = requests.get(software_api_url)
# If the response was successful, no Exception will be raised
Expand All @@ -21,9 +21,9 @@ def get_urls(n=None):
return False

urls = []
for d in response.json():
for key, values in d["repositoryURLs"].items():
urls.extend(values)
for _repo in response.json():
if _repo["url"].startswith(("https://github.com", "https://gitlab.com")):
urls.append(_repo["url"])
if n is None:
return random.shuffle(urls)
else:
Expand Down
27 changes: 13 additions & 14 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,23 +35,22 @@
"License :: OSI Approved :: Apache Software License",
"Natural Language :: English",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10"
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13"
],
test_suite="tests",
install_requires=[
"backoff == 1.*",
"beautifulsoup4 == 4.*",
"click == 7.*",
"colorama == 0.*",
"docutils == 0.16.*",
"pygments == 2.*",
"ratelimit == 2.*",
"requests == 2.*",
"ruamel.yaml == 0.16.*",
"voluptuous == 0.11.*"
"backoff==2.2.*",
"beautifulsoup4==4.12.*",
"click==8.1.*",
"colorama==0.4.*",
"docutils==0.21.*",
"Pygments==2.18.*",
"ratelimit==2.2.*",
"requests==2.32.*",
"ruamel.yaml==0.18.*",
"voluptuous==0.15.*"
],
setup_requires=[
],
Expand Down
Loading