Skip to content

fix(core): accept only a positive session id for kill #52

fix(core): accept only a positive session id for kill

fix(core): accept only a positive session id for kill #52

Workflow file for this run

name: Build Linux
on:
push:
branches: [main, linux]
paths:
- "linux/**"
- ".github/workflows/build-linux.yml"
pull_request:
branches: [main, linux]
paths:
- "linux/**"
- ".github/workflows/build-linux.yml"
schedule:
- cron: "13 14 * * 1"
workflow_dispatch:
inputs:
ref:
description: >-
Commit SHA, tag or branch to build. Pin a release candidate so
every job in the run tests the same tree.
required: false
default: ""
permissions:
contents: read
# A newer push supersedes an in-flight run for the same ref: the older
# one can no longer gate anything. Scheduled and dispatched runs keep
# their own group so a release-candidate soak is never cancelled by
# ordinary branch traffic.
concurrency:
group: build-linux-${{ github.event_name }}-${{ github.ref }}-${{ inputs.ref || 'auto' }}
cancel-in-progress: ${{ github.event_name == 'pull_request' || github.event_name == 'push' }}
jobs:
preflight:
name: Preflight and sandbox tier (no GTK app)
timeout-minutes: 30
runs-on: ubuntu-24.04
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y --no-install-recommends \
build-essential \
pkg-config \
libssl-dev \
libsecret-1-dev \
libkrb5-dev \
clang
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
components: rustfmt, clippy
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-preflight
- name: Preflight
run: ./scripts/preflight.sh
fast:
name: Fast checks (GTK)
timeout-minutes: 30
runs-on: ubuntu-24.04
needs: preflight
# ubuntu-24.04 ships glib 2.80, but libadwaita 1.6 (workspace pin)
# transitively requires gio-2.0 >= 2.82. Building inside ubuntu:25.10
# gives us glib 2.84, which satisfies the system-deps check. The
# integration job stays on the host runner — driver crates depend
# only on tablepro-core, so they don't pull in libadwaita.
container:
image: ubuntu:25.10
env:
DEBIAN_FRONTEND: noninteractive
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
apt-get update
apt-get install -y --no-install-recommends \
build-essential \
ca-certificates \
curl \
git \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
libgtksourceview-5-dev \
libssl-dev \
libsecret-1-dev \
libkrb5-dev \
clang \
dbus-daemon \
xvfb \
xauth \
at-spi2-core \
python3-pyatspi
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
components: rustfmt, clippy
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-fast-gtk
- name: Format check
run: cargo fmt --all -- --check
- name: Clippy
# DuckDB is an optional heavy crate; keep it out of the default GTK gate.
run: cargo clippy --workspace --exclude tablepro-driver-duckdb --all-targets -- -D warnings
- name: Unit tests (build via test)
run: cargo test --workspace --exclude tablepro-driver-duckdb --lib --bins
- name: Install cargo-deny and cargo-audit
run: |
cargo install cargo-deny --locked
cargo install cargo-audit --locked
- name: cargo-deny
run: cargo deny check
- name: cargo-audit
run: cargo audit
gtk-safety:
name: Installed GTK safety smoke
timeout-minutes: 45
runs-on: ubuntu-24.04
needs: fast
container:
image: ubuntu:25.10
env:
DEBIAN_FRONTEND: noninteractive
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install GTK test dependencies
run: |
apt-get update
apt-get install -y --no-install-recommends \
build-essential ca-certificates curl git pkg-config \
libgtk-4-dev libadwaita-1-dev libgtksourceview-5-dev \
libssl-dev libsecret-1-dev libsecret-tools libkrb5-dev clang \
dbus-daemon gnome-keyring libglib2.0-bin xvfb xauth at-spi2-core python3-pyatspi scrot
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-gtk-safety
- name: Secret Service round-trip
run: ./scripts/test-secret-service.sh
- name: GTK installed-flow smoke
env:
TABLEPRO_GTK_ARTIFACT_DIR: ${{ github.workspace }}/gtk-artifacts/smoke
run: ./scripts/test-gtk-safety.sh
- name: Upload GTK diagnostics
if: always()
uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f
with:
name: gtk-safety-${{ github.run_id }}-${{ github.run_attempt }}
path: gtk-artifacts
if-no-files-found: ignore
current-stable-clippy:
name: Current stable Clippy (scheduled)
timeout-minutes: 30
if: github.event_name == 'schedule' || github.event_name == 'workflow_dispatch'
runs-on: ubuntu-24.04
needs: preflight
container:
image: ubuntu:25.10
env:
DEBIAN_FRONTEND: noninteractive
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
apt-get update
apt-get install -y --no-install-recommends \
build-essential \
ca-certificates \
curl \
git \
pkg-config \
libgtk-4-dev \
libadwaita-1-dev \
libgtksourceview-5-dev \
libssl-dev \
libsecret-1-dev \
libkrb5-dev \
clang
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: stable
components: clippy
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-current-stable-clippy
- name: Clippy on current stable
# The repository override selects 1.93, so +stable is required here.
run: cargo +stable clippy --workspace --exclude tablepro-driver-duckdb --all-targets -- -D warnings
integration:
name: Driver integration tests (docker)
timeout-minutes: 45
runs-on: ubuntu-24.04
needs: preflight
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
build-essential \
pkg-config \
libssl-dev \
libkrb5-dev \
clang
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-integration
- name: Verify docker is available
run: docker version
- name: Postgres integration tests
run: cargo test --test integration -p tablepro-driver-postgres -- --include-ignored --test-threads=1
- name: PostgreSQL Unix-socket integration
run: ./scripts/test-postgres-socket.sh
- name: MySQL integration tests
run: cargo test --test integration -p tablepro-driver-mysql -- --include-ignored --test-threads=1
- name: MSSQL integration tests
run: cargo test --test integration -p tablepro-driver-mssql -- --include-ignored --test-threads=1
- name: ClickHouse integration tests
run: cargo test --test integration -p tablepro-driver-clickhouse -- --include-ignored --test-threads=1
driver-tls:
name: Driver TLS fixture (docker)
timeout-minutes: 30
runs-on: ubuntu-24.04
needs: preflight
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
build-essential \
pkg-config \
libssl-dev \
libkrb5-dev \
clang
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-driver-tls
- name: Verify docker is available
run: docker compose version
- name: Driver TLS fixture
run: ./scripts/test-driver-tls.sh
postgres-release:
name: PostgreSQL release fixture (docker)
timeout-minutes: 30
runs-on: ubuntu-24.04
needs: preflight
defaults:
run:
working-directory: linux
steps:
- uses: actions/checkout@fbc6f3992d24b796d5a048ff273f7fcc4a7b6c09
with:
ref: ${{ inputs.ref || (github.event_name == 'schedule' && 'linux') || github.ref }}
- name: Record the commit under test
run: |
echo "tree under test: $(git rev-parse HEAD)"
- name: Install system dependencies
run: |
sudo apt-get update
sudo apt-get install -y \
build-essential \
pkg-config \
libssl-dev \
libkrb5-dev \
clang \
openssh-client
- uses: dtolnay/rust-toolchain@6c977a6ca4077a0ceb28ffbe03f59d46e9ac8772
with:
toolchain: 1.93
- uses: Swatinem/rust-cache@6323deb102c322ba6fcbdcafc7e3dddab59af2b6
with:
workspaces: linux
prefix-key: linux-postgres-release
- name: Verify docker is available
run: docker compose version
- name: PostgreSQL TLS, SSH, lock, and reconnect fixture
run: ./scripts/test-postgres-release.sh