Skip to content
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
3 changes: 2 additions & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
fail-fast: false
matrix:
os: [ "ubuntu-latest", "macos-latest" ]
python-version: [ "3.8", "3.9", "3.10", "3.11", "3.12" ]
python-version: [ "3.10", "3.11", "3.12" ]
exclude:
- os: "macos-latest"
runs-on: ${{ matrix.os }}
Expand All @@ -43,5 +43,6 @@ jobs:
- name: Upload coverage
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
file: ./coverage.xml
fail_ci_if_error: true
277 changes: 154 additions & 123 deletions poetry.lock

Large diffs are not rendered by default.

2 changes: 0 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,6 @@ classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Intended Audience :: Developers",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
Expand Down
4 changes: 0 additions & 4 deletions src/ctl/util/git.py
Original file line number Diff line number Diff line change
Expand Up @@ -950,7 +950,6 @@ def __enter__(self):
Sets up the repository, fetches and pulls.
"""


self.context_token = current_ephemeral_git_context.set(self)
self.state_token = ephemeral_git_context_state.set(self.state)

Expand Down Expand Up @@ -1045,8 +1044,6 @@ def __exit__(self, exc_type, exc_val, exc_tb):

return False # re-raise any exception



@property
def git_manager(self):
return self.state.git_manager
Expand All @@ -1067,7 +1064,6 @@ def active(self):
def log(self):
return self.git_manager.log


def reset(self, from_origin: bool = True):
"""
Resets the repository
Expand Down
2 changes: 1 addition & 1 deletion tests/test_plugin_semver2.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ def test_tag_pyproject(tmpdir, ctlr):

plugin.tag(version="2.0.0", repo="dummy_repo", prerelease="rc")

with open(pyproject_path, "r") as f:
with open(pyproject_path) as f:
pyproject = tomlkit.load(f)
assert pyproject["tool"]["poetry"]["version"] == "2.0.0-rc.1"

Expand Down
2 changes: 1 addition & 1 deletion tests/test_plugin_version.py
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ def test_tag_pyproject(tmpdir, ctlr):

plugin.tag(version="2.0.0", repo="dummy_repo")

with open(pyproject_path, "r") as f:
with open(pyproject_path) as f:
pyproject = tomlkit.load(f)
assert pyproject["tool"]["poetry"]["version"] == "2.0.0"

Expand Down
4 changes: 3 additions & 1 deletion tests/test_util_git_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

import pytest
import yaml
from git import Repo, GitCommandError
from git import GitCommandError, Repo
from ogr.abstract import PRStatus

from ctl.util.git import (
Expand Down Expand Up @@ -418,6 +418,8 @@ def test_git_manager_sync_with_new_branch(git_repo, clone_dir):
def test_git_manager_sync_with_merge(git_repo, clone_dir):
remote_dir, git_repo = git_repo
git_manager = GitManager(url=f"file://{remote_dir}", directory=clone_dir)
git_manager.repo.git.config("user.email", "test@example.com")
git_manager.repo.git.config("user.name", "Test User")
git_manager.switch_branch("test", create=True)
git_manager.require_remote_branch()

Expand Down
4 changes: 1 addition & 3 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,12 @@ norecursedirs = .ctl .tox .venv data gen

[gh-actions]
python =
3.8: py38
3.9: py39
3.10: py310
3.11: py311
3.12: py312

[tox]
envlist = py38,py39,py310,py311,py312
envlist = py310,py311,py312
isolated_build = True

[tox:.package]
Expand Down
Loading