Skip to content

Commit

Permalink
Drop support for Pythons older than 3.8
Browse files Browse the repository at this point in the history
  • Loading branch information
akx committed Jun 10, 2024
1 parent e738a27 commit c9339ba
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 7 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,8 @@ jobs:
strategy:
matrix:
python-version:
- '3.7'
- '3.10'
- '3.8'
- '3.12'
steps:
- name: 'Set up Python ${{ matrix.python-version }}'
uses: actions/setup-python@v5
Expand All @@ -32,6 +32,6 @@ jobs:
steps:
- uses: actions/setup-python@v5
with:
python-version: '3.10'
python-version: '3.12'
- uses: actions/checkout@v4
- uses: pre-commit/[email protected]
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
[![codecov](https://codecov.io/gh/valohai/laituri/branch/master/graph/badge.svg)](https://codecov.io/gh/valohai/laituri)

`laituri` is a set of Docker-related Python snippets used at [Valohai](https://valohai.com/).
You can use it with Python >= 3.7.
You can use it with Python >= 3.8.

## Usage

Expand Down
2 changes: 1 addition & 1 deletion laituri/docker/credential_manager/docker_v1.py
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ def docker_login(domain: str, username: str, password: str) -> bool:
log.debug(f"Running `{' '.join(args)}`")
proc = subprocess.Popen(args, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
try:
cmd_input = (password + '\n').encode('utf-8')
cmd_input = f"{password}\n".encode()
stdout, _ = proc.communicate(input=cmd_input, timeout=settings.DOCKER_TIMEOUT)
except subprocess.TimeoutExpired as te:
raise DockerLoginFailed('timed out') from te
Expand Down
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ dynamic = ["version"]
description = "Docker Toolkit for Python"
readme = "README.md"
license = "MIT"
requires-python = ">=3.6"
requires-python = ">=3.8"
authors = [
{ name = "Valohai", email = "[email protected]" },
]
Expand Down Expand Up @@ -45,7 +45,7 @@ strict = true
exclude = "laituri_tests/test_.*"

[tool.ruff]
target-version = "py37"
target-version = "py38"
line-length = 120

[tool.ruff.lint]
Expand All @@ -59,6 +59,7 @@ select = [
"I", # isort
"T", # debugger and print
"TID", # flake8-tidy-imports
"UP", # pyupgrade
"W", # pycodestyle
]
ignore = []
Expand Down

0 comments on commit c9339ba

Please sign in to comment.