Skip to content

Commit

Permalink
feat: drop Python 3.10 and add Python 3.12 (#478)
Browse files Browse the repository at this point in the history
### Summary of Changes

* Remove support for Python 3.10
* Add support for Python 3.12

---------

Co-authored-by: megalinter-bot <129584137+megalinter-bot@users.noreply.github.com>
  • Loading branch information
lars-reimann and megalinter-bot committed Nov 16, 2023
1 parent 50efd15 commit 5bf0e75
Show file tree
Hide file tree
Showing 14 changed files with 1,743 additions and 1,662 deletions.
2 changes: 1 addition & 1 deletion .github/linters/.ruff.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
ignore-init-module-imports = true
line-length = 120
target-version = "py310"
target-version = "py311"

select = [
"F",
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ jobs:
fail-fast: false
matrix:
python-version:
- "3.10"
- "3.11"
- "3.12"
uses: lars-reimann/.github/.github/workflows/poetry-codecov-reusable.yml@main
with:
working-directory: .
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@ jobs:
fail-fast: false
matrix:
python-version:
- "3.10"
- "3.11"
- "3.12"
uses: lars-reimann/.github/.github/workflows/poetry-codecov-reusable.yml@main
with:
working-directory: .
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
uses: lars-reimann/.github/.github/workflows/poetry-pypi-reusable.yml@main
with:
working-directory: .
python-version: "3.10"
python-version: "3.11"
secrets:
GITHUB_PAT: ${{ secrets.PAT }}
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
3,374 changes: 1,728 additions & 1,646 deletions poetry.lock

Large diffs are not rendered by default.

14 changes: 7 additions & 7 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -13,16 +13,16 @@ packages = [
]

[tool.poetry.dependencies]
python = "^3.10"
python = "^3.11,<3.13"
ipython = "^8.8.0"
levenshtein = ">=0.21.1,<0.24.0"
matplotlib = "^3.6.3"
openpyxl = "^3.1.2"
pandas = "^2.0.0"
pillow = ">=9.5,<11.0"
scikit-learn = "^1.2.0"
seaborn = "^0.12.2"
openpyxl = "^3.1.2"
scikit-image = ">=0.21,<0.23"
levenshtein = ">=0.21.1,<0.24.0"
scikit-learn = "^1.2.0"
seaborn = "^0.13.0"

[tool.poetry.group.dev.dependencies]
pytest = "^7.2.1"
Expand All @@ -34,13 +34,13 @@ mkdocs = "^1.4.2"
mkdocstrings = ">=0.20,<0.23"
mkdocstrings-python = ">=0.8.3,<1.8.0"
mkdocs-autorefs = ">=0.4.1,<0.6.0"
mkdocs-exclude = "^1.0.2"
mkdocs-gen-files = ">=0.4,<0.6"
mkdocs-glightbox = "^0.3.1"
mkdocs-jupyter = ">=0.23,<0.25"
mkdocs-literate-nav = "^0.6.0"
mkdocs-material = "^9.1.2"
mkdocs-section-index = "^0.3.5"
mkdocs-jupyter = ">=0.23,<0.25"
mkdocs-exclude = "^1.0.2"

[build-system]
requires = ["poetry-core>=1.0.0"]
Expand Down
2 changes: 1 addition & 1 deletion readthedocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ version: 2
build:
os: ubuntu-22.04
tools:
python: '3.10'
python: '3.11'
commands:
- pip install poetry
- poetry config virtualenvs.create false
Expand Down
7 changes: 3 additions & 4 deletions src/safeds/data/tabular/containers/_column.py
Original file line number Diff line number Diff line change
Expand Up @@ -145,12 +145,10 @@ def __eq__(self, other: object) -> bool:
return self.name == other.name and self._data.equals(other._data)

@overload
def __getitem__(self, index: int) -> T:
...
def __getitem__(self, index: int) -> T: ...

@overload
def __getitem__(self, index: slice) -> Column[T]:
...
def __getitem__(self, index: slice) -> Column[T]: ...

def __getitem__(self, index: int | slice) -> T | Column[T]:
"""
Expand Down Expand Up @@ -921,6 +919,7 @@ def plot_boxplot(self) -> Image:
ax = sns.boxplot(data=self._data)
ax.set(title=self.name)
ax.set_xticks([])
ax.set_ylabel("")
plt.tight_layout()

buffer = io.BytesIO()
Expand Down
Binary file modified tests/resources/image/snapshot_boxplot.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests/resources/image/snapshot_boxplot_left_rotation.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests/resources/image/snapshot_boxplot_right_rotation.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified tests/resources/image/snapshot_boxplots/one_column.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 5bf0e75

Please sign in to comment.