Skip to content

Commit 5bf9488

Browse files
committed
ci: Add ORA_TZFILE workaround to ruby_head workflow
The scheduled ruby_head workflow has been failing since 2026-05-09 with `OCIError: ORA-01805: possible error in date/time operation` raised from `ocidatetime.c:119` for every DATE/TIMESTAMP fetch: https://github.com/rsim/ruby-plsql/actions/runs/25586756343 Cause: `gvenzl/oracle-free:latest` ships Oracle Free 23ai with a newer timezone-data version than the `instantclient-basic-linuxx64.zip` "latest" download embeds, and ruby-oci8 raises ORA-01805 whenever the client tries to materialize a date/time fetched from a session opened against the newer server. Copy the server's `timezlrg_*.dat` onto the Instant Client and point ORA_TZFILE at it, immediately after the `Create database user` step. The lookup is dynamic so a future bump of the gvenzl image (which ships whatever timezone version is current) continues to work without further edits. Mirrors rsim/oracle-enhanced#2764.
1 parent 959e88b commit 5bf9488

1 file changed

Lines changed: 11 additions & 0 deletions

File tree

.github/workflows/ruby_head.yml

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,17 @@ jobs:
6262
- name: Create database user
6363
run: |
6464
./ci/setup_accounts.sh
65+
- name: Force client TZ data to match server (ORA_TZFILE workaround)
66+
run: |
67+
ORACLE_CONTAINER=$(docker ps --filter "ancestor=gvenzl/oracle-free" -q)
68+
SRC=$(docker exec "$ORACLE_CONTAINER" bash -c 'ls $ORACLE_HOME/oracore/zoneinfo/timezlrg_*.dat 2>/dev/null | head -1')
69+
echo "Server TZ file: $SRC"
70+
DST_DIR="$ORACLE_HOME/oracore/zoneinfo"
71+
sudo mkdir -p "$DST_DIR"
72+
docker cp "$ORACLE_CONTAINER":"$SRC" /tmp/_server_tzfile.dat
73+
sudo mv /tmp/_server_tzfile.dat "$DST_DIR/$(basename "$SRC")"
74+
ls -l "$DST_DIR"
75+
echo "ORA_TZFILE=$DST_DIR/$(basename "$SRC")" >> $GITHUB_ENV
6576
- name: Bundle install
6677
run: |
6778
bundle install --jobs 4 --retry 3

0 commit comments

Comments
 (0)