diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index e16c8ab1..1d7e5b32 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -24,7 +24,7 @@ repos: - id: end-of-file-fixer - id: trailing-whitespace - repo: https://github.com/tox-dev/pyproject-fmt - rev: v2.16.2 + rev: v2.21.0 hooks: - id: pyproject-fmt - repo: https://github.com/abravalheri/validate-pyproject @@ -44,7 +44,7 @@ repos: entry: isort --profile=black name: isort (python) - repo: https://github.com/psf/black-pre-commit-mirror - rev: 26.1.0 + rev: 26.3.1 hooks: - id: black - repo: https://github.com/tonybaloney/perflint @@ -60,7 +60,7 @@ repos: additional_dependencies: - black - repo: https://github.com/codespell-project/codespell - rev: v2.4.1 + rev: v2.4.2 hooks: - id: codespell args: [--toml pyproject.toml] diff --git a/docs/data-processing/apis/fastapi/example.rst b/docs/data-processing/apis/fastapi/example.rst index 3ef4dff6..80bbf201 100644 --- a/docs/data-processing/apis/fastapi/example.rst +++ b/docs/data-processing/apis/fastapi/example.rst @@ -16,7 +16,6 @@ Create a file :file:`main.py` with: from fastapi import FastAPI - app = FastAPI() @@ -77,7 +76,6 @@ Now we modify the file ``main.py`` to receive a body from a ``PUT`` request: from fastapi import FastAPI - app = FastAPI() diff --git a/docs/data-processing/postgresql/db-api.rst b/docs/data-processing/postgresql/db-api.rst index a7ce1992..646e93a5 100644 --- a/docs/data-processing/postgresql/db-api.rst +++ b/docs/data-processing/postgresql/db-api.rst @@ -82,12 +82,10 @@ Cursor .. code-block:: python cursor = conn.cursor() - cursor.execute( - """ + cursor.execute(""" SELECT column1, column2 FROM tableA - """ - ) + """) for column1, column2 in cursor.fetchall(): print(column1, column2) diff --git a/docs/data-processing/postgresql/sqlalchemy.rst b/docs/data-processing/postgresql/sqlalchemy.rst index cd2c2450..c281ca9a 100644 --- a/docs/data-processing/postgresql/sqlalchemy.rst +++ b/docs/data-processing/postgresql/sqlalchemy.rst @@ -44,7 +44,6 @@ Database connection from sqlalchemy import create_engine - engine = create_engine("postgresql:///example", echo=True) Data model @@ -56,7 +55,6 @@ Data model from sqlalchemy.ext.declarative import declarative_base from sqlalchemy.orm import relationship - Base = declarative_base() diff --git a/docs/data-processing/serialisation-formats/toml/index.rst b/docs/data-processing/serialisation-formats/toml/index.rst index 928512cc..5a6425f9 100644 --- a/docs/data-processing/serialisation-formats/toml/index.rst +++ b/docs/data-processing/serialisation-formats/toml/index.rst @@ -39,7 +39,6 @@ Overview import toml - config = toml.load("pyproject.toml") .. seealso:: diff --git a/docs/data-processing/serialisation-formats/toml/pyproject.toml b/docs/data-processing/serialisation-formats/toml/pyproject.toml index 732e8efc..7812d682 100644 --- a/docs/data-processing/serialisation-formats/toml/pyproject.toml +++ b/docs/data-processing/serialisation-formats/toml/pyproject.toml @@ -1,7 +1,6 @@ # SPDX-FileCopyrightText: 2022 Veit Schiele # # SPDX-License-Identifier: BSD-3-Clause - [tool.black] line-length = 79 @@ -14,6 +13,5 @@ lines_between_types = 1 multi_line_output = 3 not_skip = "__init__.py" use_parentheses = true - known_first_party = [ "MY_FIRST_MODULE", "MY_SECOND_MODULE" ] known_third_party = [ "mpi4py", "numpy", "requests" ] diff --git a/docs/performance/index.rst b/docs/performance/index.rst index f51088ec..6a07a192 100644 --- a/docs/performance/index.rst +++ b/docs/performance/index.rst @@ -52,7 +52,6 @@ We can create sample data with: from sklearn.datasets import make_blobs - points, labels_true = make_blobs( n_samples=1000, centers=3, random_state=0, cluster_std=0.60 ) @@ -133,7 +132,6 @@ algorithm: from sklearn.cluster import KMeans - KMeans(10).fit_predict(points) * `dask_ml.cluster.KMeans @@ -143,7 +141,6 @@ algorithm: from dask_ml.cluster import KMeans - KMeans(10).fit(points).predict(points) The best that could be said against these existing solutions is that they could diff --git a/pyproject.toml b/pyproject.toml index 5b87b2d3..5b1aeb08 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -20,7 +20,7 @@ classifiers = [ ] dependencies = [] urls."Bug Tracker" = "https://github.com/cusyio/Python4DataScience/issues" -urls."Homepage" = "https://github.com/cusyio/Python4DataScience/" +urls.Homepage = "https://github.com/cusyio/Python4DataScience/" [dependency-groups] dev = [