Skip to content

Commit

Permalink
Merge pull request #830 from aeturrell/version_info
Browse files Browse the repository at this point in the history
added version info; removed safety due to issues with it
  • Loading branch information
aeturrell authored Sep 16, 2024
2 parents 1a35d65 + 321e30f commit 1a964fb
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 197 deletions.
1 change: 0 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@ jobs:
matrix:
include:
- { python-version: 3.9, os: ubuntu-latest, session: "pre-commit" }
- { python-version: 3.9, os: ubuntu-latest, session: "safety" }
- { python-version: 3.9, os: ubuntu-latest, session: "mypy" }
- { python-version: "3.11", os: ubuntu-latest, session: "mypy" }
- { python-version: "3.10", os: ubuntu-latest, session: "mypy" }
Expand Down
14 changes: 7 additions & 7 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
nox.needs_version = ">= 2021.6.6"
nox.options.sessions = (
"pre-commit",
"safety",
# "safety",
"mypy",
"tests",
"typeguard",
Expand Down Expand Up @@ -96,12 +96,12 @@ def precommit(session: Session) -> None:
activate_virtualenv_in_precommit_hooks(session)


@session(python="3.9")
def safety(session: Session) -> None:
"""Scan dependencies for insecure packages."""
requirements = session.poetry.export_requirements()
session.install("safety")
session.run("safety", "check", "--full-report", f"--file={requirements}")
# @session(python="3.9")
# def safety(session: Session) -> None:
# """Scan dependencies for insecure packages."""
# requirements = session.poetry.export_requirements()
# session.install("safety")
# session.run("safety", "check", "--full-report", f"--file={requirements}")


@session(python=python_versions)
Expand Down
192 changes: 4 additions & 188 deletions poetry.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,6 @@ skimpy = "skimpy.__main__:main"
nox = ">=2023.4.22,<2025.0.0"
pytest = ">=7.4,<9.0"
coverage = {extras = ["toml"], version = "^7.2"}
safety = ">=2.3.5,<4.0.0"
mypy = "^1.4"
xdoctest = {extras = ["colors"], version = "^1.1.1"}
pre-commit = "^3.3.1"
Expand Down
7 changes: 7 additions & 0 deletions src/skimpy/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@
# no nothing
pass

from importlib.metadata import PackageNotFoundError, version

try:
__version__ = version("skimpy")
except PackageNotFoundError:
__version__ = "unknown"

NULL_VALUES = {np.nan, "", None}

CASE_STYLES = {
Expand Down

0 comments on commit 1a964fb

Please sign in to comment.