Skip to content

Drop Python 3.7 #885

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Sep 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:

- name: Install poetry
if: env.PUBLISH == 'true'
run: pipx install "poetry==1.5.1"
run: pipx install "poetry==1.6.1"

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,15 @@ jobs:
tmux-version: [ '2.6', '2.7', '2.8', '3.0a', '3.1b', '3.2a', '3.3a', 'master' ]
# balance ci coverage across supported python/tmux versions with CI speed
include:
- python-version: '3.7'
- python-version: '3.8'
tmux-version: '2.6'
- python-version: '3.7'
- python-version: '3.8'
tmux-version: 'master'
steps:
- uses: actions/checkout@v3

- name: Install poetry
run: pipx install "poetry==1.5.1"
run: pipx install "poetry==1.6.1"

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
Expand Down Expand Up @@ -96,7 +96,7 @@ jobs:
- uses: actions/checkout@v3

- name: Install poetry
run: pipx install "poetry==1.5.1"
run: pipx install "poetry==1.6.1"

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
Expand Down
2 changes: 1 addition & 1 deletion .tool-versions
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
poetry 1.5.1
poetry 1.6.1
python 3.11.5 3.10.13 3.9.18 3.8.18 3.7.17
8 changes: 8 additions & 0 deletions CHANGES
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,14 @@ $ pipx install --suffix=@next 'tmuxp' --pip-args '\--pre' --force

<!-- Maintainers, insert changes / features for the next release here -->

### Breaking changes

- Python 3.7 Dropped (#885)

### Development

- Poetry 1.5.1 -> 1.6.1 (#885)

## tmuxp 1.30.1 (2023-09-09)

_Maintenance only, no bug fixes or new features_
Expand Down
619 changes: 267 additions & 352 deletions poetry.lock

Large diffs are not rendered by default.

9 changes: 4 additions & 5 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,6 @@ classifiers = [
"Environment :: Web Environment",
"Intended Audience :: Developers",
"Programming Language :: Python",
"Programming Language :: Python :: 3.7",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
Expand Down Expand Up @@ -46,7 +45,7 @@ Changes = "https://github.com/tmux-python/tmuxp/blob/master/CHANGES"
tmuxp = 'tmuxp:cli.cli'

[tool.poetry.dependencies]
python = "^3.7"
python = "^3.8"
libtmux = "~0.23.2"
colorama = ">=0.3.9"
PyYAML = "^6.0"
Expand All @@ -58,11 +57,11 @@ sphinx = "*"
aafigure = ">=0.6"
pillow = "*"
furo = "*"
gp-libs = "~0.0.1"
gp-libs = "~0.0.2"
sphinx-autobuild = "*"
sphinx-autodoc-typehints = "*"
sphinx-argparse = "*"
sphinx-inline-tabs = "<2023.4.21" # For Python 3.7 support
sphinx-inline-tabs = "*"
sphinxext-opengraph = "<0.8" # https://github.com/wpilibsuite/sphinxext-opengraph/issues/100
sphinx-copybutton = "*"
sphinxext-rediraffe = "*"
Expand Down Expand Up @@ -156,7 +155,7 @@ module = [
ignore_missing_imports = true

[tool.ruff]
target-version = "py37"
target-version = "py38"
select = [
"E", # pycodestyle
"F", # pyflakes
Expand Down
8 changes: 4 additions & 4 deletions src/tmuxp/cli/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,13 +35,13 @@
logger = logging.getLogger(__name__)

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias
from typing_extensions import TypeAlias

CLIVerbosity: TypeAlias = Literal["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"]
CLISubparserName: TypeAlias = Literal[
CLIVerbosity: TypeAlias = t.Literal["DEBUG", "INFO", "WARNING", "ERROR", "CRITICAL"]
CLISubparserName: TypeAlias = t.Literal[
"ls", "load", "convert", "edit", "import", "shell", "debug-info"
]
CLIImportSubparserName: TypeAlias = Literal["teamocil", "tmuxinator"]
CLIImportSubparserName: TypeAlias = t.Literal["teamocil", "tmuxinator"]


def create_parser() -> argparse.ArgumentParser:
Expand Down
4 changes: 1 addition & 3 deletions src/tmuxp/cli/convert.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,7 @@
from .utils import prompt_yes_no

if t.TYPE_CHECKING:
from typing_extensions import Literal

AllowedFileTypes = Literal["json", "yaml"]
AllowedFileTypes = t.Literal["json", "yaml"]


def create_convert_subparser(
Expand Down
4 changes: 2 additions & 2 deletions src/tmuxp/cli/freeze.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,9 @@
from .utils import prompt, prompt_choices, prompt_yes_no

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias, TypeGuard
from typing_extensions import TypeAlias, TypeGuard

CLIOutputFormatLiteral: TypeAlias = Literal["yaml", "json"]
CLIOutputFormatLiteral: TypeAlias = t.Literal["yaml", "json"]


class CLIFreezeNamespace(argparse.Namespace):
Expand Down
4 changes: 2 additions & 2 deletions src/tmuxp/cli/load.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,9 +26,9 @@
from .utils import prompt_choices, prompt_yes_no, style, tmuxp_echo

if t.TYPE_CHECKING:
from typing_extensions import Literal, NotRequired, TypeAlias, TypedDict
from typing_extensions import NotRequired, TypeAlias, TypedDict

CLIColorsLiteral: TypeAlias = Literal[56, 88]
CLIColorsLiteral: TypeAlias = t.Literal[56, 88]

class OptionOverrides(TypedDict):
detached: NotRequired[bool]
Expand Down
6 changes: 3 additions & 3 deletions src/tmuxp/cli/shell.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,10 +9,10 @@
from .._compat import PY3, PYMINOR

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias
from typing_extensions import TypeAlias

CLIColorsLiteral: TypeAlias = Literal[56, 88]
CLIShellLiteral: TypeAlias = Literal[
CLIColorsLiteral: TypeAlias = t.Literal[56, 88]
CLIShellLiteral: TypeAlias = t.Literal[
"best", "pdb", "code", "ptipython", "ptpython", "ipython", "bpython"
]

Expand Down
4 changes: 2 additions & 2 deletions src/tmuxp/config_reader.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@
import yaml

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias
from typing_extensions import TypeAlias

FormatLiteral = Literal["json", "yaml"]
FormatLiteral = t.Literal["json", "yaml"]

RawConfigData: TypeAlias = t.Dict[t.Any, t.Any]

Expand Down
4 changes: 2 additions & 2 deletions src/tmuxp/shell.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
logger = logging.getLogger(__name__)

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias
from typing_extensions import TypeAlias

CLIShellLiteral: TypeAlias = Literal[
CLIShellLiteral: TypeAlias = t.Literal[
"best", "pdb", "code", "ptipython", "ptpython", "ipython", "bpython"
]

Expand Down
4 changes: 2 additions & 2 deletions src/tmuxp/workspace/finders.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
logger = logging.getLogger(__name__)

if t.TYPE_CHECKING:
from typing_extensions import Literal, TypeAlias
from typing_extensions import TypeAlias

ValidExtensions: TypeAlias = Literal[".yml", ".yaml", ".json"]
ValidExtensions: TypeAlias = t.Literal[".yml", ".yaml", ".json"]


def is_workspace_file(
Expand Down
3 changes: 1 addition & 2 deletions tests/workspace/test_builder.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,8 @@

if t.TYPE_CHECKING:
from libtmux.server import Server
from typing_extensions import Protocol

class AssertCallbackProtocol(Protocol):
class AssertCallbackProtocol(t.Protocol):
def __call__(self, cmd: str, hist: str) -> bool:
...

Expand Down