Skip to content

Commit

Permalink
Merge pull request #106 from elliot-100/profile-module-shadows-builtin
Browse files Browse the repository at this point in the history
`profile` module shadows Python built-in
  • Loading branch information
elliot-100 authored Feb 10, 2025
2 parents 22e2a7d + cd354f3 commit 8ffd676
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 15 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,18 @@ and this project tries to adhere to [Semantic Versioning](https://semver.org/spe
Historic and pre-release versions aren't necessarily included.


## UNRELEASED - TBC

### Changed

- Rename `profile` module as it shadowed a Python built-in
- Update dev dependency: ruff, and its config

### Removed

- Remove unused dev dependency: pdoc


## [0.11.0] - 2024-10-23

### Added
Expand Down
2 changes: 1 addition & 1 deletion britishcycling_clubs/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
get_manager_member_counts,
manager_url_via_login,
)
from britishcycling_clubs.profile import (
from britishcycling_clubs.profile_ import (
ProfileInfo,
get_profile_info,
profile_url,
Expand Down
File renamed without changes.
30 changes: 17 additions & 13 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,7 @@ requests = ">=2.23.1"
playwright = ">=1.39.0"

[tool.poetry.group.dev.dependencies]
pdoc = ">=14.6.0"
ruff = ">=0.5.7"
ruff = "~0.9.5"

[tool.poetry.group.test.dependencies]
mypy = ">=1.11.1"
Expand All @@ -39,19 +38,24 @@ target-version = "py38" # Ruff doesn't respect Python version in [tool.poetry.d
[tool.ruff.lint]
select = ["ALL"]

# Ignore rules that conflict with Ruff formatter:
# COM812 Trailing comma missing
# ISC001 Implicitly concatenated string literals on one line
ignore = ["COM812", "ISC001"]
ignore = [
# Rules that conflict with Ruff formatter:
"COM812", # Trailing comma missing
"ISC001", # Implicitly concatenated string literals on one line
# Other:
"RUF022", # `__all__` is not sorted
]

[tool.ruff.lint.per-file-ignores]
# Ignore rules that aren't relevant/useful in tests:
# PLR2004 Magic value used in comparison
# S101 Use of assert detected
"**/{tests}/*" = ["PLR2004", "S101"]
# Ignore rules that aren't relevant/useful in example scripts:
# T203 `pprint` found
"example*.py" = ["T203"]
# Rules that aren't relevant/useful in tests:
"**/{tests}/*" = [
"PLR2004", # Magic value used in comparison
"S101", # Use of assert detected
]
# Rules that aren't relevant/useful in example scripts:
"example*.py" = [
"T203", # T203 `pprint` found
]

[tool.ruff.lint.pydocstyle]
convention = "numpy"
Expand Down
2 changes: 1 addition & 1 deletion tests/test_profile.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from bs4 import BeautifulSoup

from britishcycling_clubs import profile_url
from britishcycling_clubs.profile import (
from britishcycling_clubs.profile_ import (
_club_name_from_profile,
_total_members_from_profile,
)
Expand Down

0 comments on commit 8ffd676

Please sign in to comment.