Skip to content

Commit

Permalink
ci: deduplicate both ci environment variables and odbc setup
Browse files Browse the repository at this point in the history
  • Loading branch information
cpcloud committed Dec 23, 2023
1 parent 33e9f26 commit 51601cc
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 28 deletions.
29 changes: 2 additions & 27 deletions .github/workflows/ibis-backends.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,13 @@ concurrency:

env:
FORCE_COLOR: "1"
ODBCSYSINI: "${{ github.workspace }}/ci/odbc"
SQLALCHEMY_WARN_20: "1"

jobs:
test_backends:
name: ${{ matrix.backend.title }} ${{ matrix.os }} python-${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
env:
SQLALCHEMY_WARN_20: "1"
ODBCSYSINI: "${{ github.workspace }}/.odbc"
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -312,16 +311,6 @@ jobs:
- name: checkout
uses: actions/checkout@v4

- name: setup odbc for mssql
if: ${{ matrix.backend.name == 'mssql' }}
run: |
mkdir -p "$ODBCSYSINI"
{
echo '[FreeTDS]'
echo "Driver = libtdsodbc.so"
} > "$ODBCSYSINI/odbcinst.ini"
- uses: extractions/setup-just@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down Expand Up @@ -411,8 +400,6 @@ jobs:
test_backends_min_version:
name: ${{ matrix.backend.title }} Min Version ${{ matrix.os }} python-${{ matrix.python-version }}
runs-on: ${{ matrix.os }}
env:
SQLALCHEMY_WARN_20: "1"
strategy:
fail-fast: false
matrix:
Expand Down Expand Up @@ -706,8 +693,6 @@ jobs:
- oracle
services:
- oracle
env:
ODBCSYSINI: "${{ github.workspace }}/.odbc"
steps:
- name: checkout
uses: actions/checkout@v4
Expand All @@ -720,16 +705,6 @@ jobs:
sudo apt-get update -qq -y
sudo apt-get install -qq -y build-essential ${{ join(matrix.backend.sys-deps, ' ') }}
- name: setup odbc for mssql
if: ${{ matrix.backend.name == 'mssql' }}
run: |
mkdir -p "$ODBCSYSINI"
{
echo '[FreeTDS]'
echo "Driver = libtdsodbc.so"
} > "$ODBCSYSINI/odbcinst.ini"
- uses: extractions/setup-just@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
Expand Down
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -131,4 +131,6 @@ ibis/examples/descriptions

# chat
*zuliprc*
.odbc

# automatically generated odbc file for ci
ci/odbc/odbc.ini
2 changes: 2 additions & 0 deletions ci/odbc/odbcinst.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
[FreeTDS]
Driver = libtdsodbc.so

0 comments on commit 51601cc

Please sign in to comment.