diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index ddf3a8c..e6c1da1 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,6 +1,6 @@ name: CI -on: [ push, pull_request ] +on: [push, pull_request] permissions: contents: read @@ -14,14 +14,14 @@ jobs: python-version: ["3.10", "3.11", "3.12", "3.13"] env: DISPLAY: ':99.0' - steps: - - uses: actions/checkout@v4 + steps: + - uses: actions/checkout@v6 - name: Install system packages run: | sudo apt update sudo apt install libxkbcommon-x11-0 libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-randr0 libxcb-render-util0 libxcb-xinerama0 libxcb-xfixes0 x11-utils libgl1 libegl1 libdbus-1-3 libxcb-cursor0 libgtk-3-0 - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: ${{ matrix.python-version }} cache: 'pip' @@ -45,18 +45,18 @@ jobs: pytest env: PYTEST_DEBUG_TEMPROOT: /tmp_pytest - + ruff: name: Ruff runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v4 + steps: + - uses: actions/checkout@v6 - name: Set up Python - uses: actions/setup-python@v5 + uses: actions/setup-python@v6 with: python-version: '3.10' - name: Install pip and ruff - run: | + run: | python -m pip install --upgrade pip pip install ruff - name: Run Ruff diff --git a/typstwriter/editor.py b/typstwriter/editor.py index e760ad1..0b2e823 100644 --- a/typstwriter/editor.py +++ b/typstwriter/editor.py @@ -712,7 +712,7 @@ def __init__(self, parent): self.syntax_combo_box = QtWidgets.QComboBox() for name in sorted(syntax_highlighting.available_lexers(), key=str.lower): self.syntax_combo_box.addItem(name) - self.syntax_combo_box.textActivated.connect(lambda text: self.syntax_changed.emit(text)) + self.syntax_combo_box.textActivated.connect(self.syntax_changed.emit) self.Layout.addStretch() self.Layout.addWidget(self.syntax_combo_box) diff --git a/typstwriter/mainwindow.py b/typstwriter/mainwindow.py index 59efe03..948f0e0 100644 --- a/typstwriter/mainwindow.py +++ b/typstwriter/mainwindow.py @@ -148,7 +148,7 @@ def __init__(self): self.CompilerConnector.compilation_finished.connect(self.editor.clear_errors) self.CompilerConnector.error_report.connect(self.editor.apply_errors) state.main_file.Signal.connect(lambda s: self.CompilerConnector.stop()) - state.main_file.Signal.connect(lambda s: self.CompilerOptions.main_changed(s)) + state.main_file.Signal.connect(lambda s: self.CompilerOptions.main_changed(s)) # noqa: PLW0108 state.main_file.Signal.connect(lambda s: self.PDFWidget.open(util.pdf_path(s))) # For now only display errors