Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
01376c0
WIP: conversion layer, reflection binder, Stats
tannevaled Oct 17, 2026
4ffdbd4
WIP: Special, Optimize, Integrate; generator also lists the special f…
tannevaled Oct 17, 2026
1419f6c
Tests: every Stats, Special, Optimize and Integrate binding compared …
tannevaled Oct 17, 2026
e807935
Callbacks abort the Go algorithm on a Ruby error; error, edge and obj…
tannevaled Oct 17, 2026
dc3c666
internal/gen: tests, the generated files checked current
tannevaled Oct 17, 2026
b8038d8
Plot: bind go-plot figures, axes and options
tannevaled Oct 17, 2026
7504a1b
DataFrame: bind go-dataframe frames, series, group-bys and indexes
tannevaled Oct 17, 2026
81e17df
DataFrame: DatetimeFields keeps the default inspect
tannevaled Oct 17, 2026
990e08e
Plot: every binding compared with the Go call, SVG byte for byte
tannevaled Oct 17, 2026
fe5087f
DataFrame: construction and frame methods compared with the Go calls
tannevaled Oct 17, 2026
e6b2968
DataFrame: series, group-bys, indexes and every error branch tested a…
tannevaled Oct 17, 2026
3db9f6a
Examples of DataFrame and Plot, run by a test
tannevaled Oct 17, 2026
a899494
Examples per module, README listing every binding (checked by a test)…
tannevaled Oct 17, 2026
7ec66fa
cells: run a notebook's Ruby cells, and exchange variables with its G…
tannevaled Oct 17, 2026
75495ad
cells: NewWriting, for a host that captures output itself
tannevaled Oct 18, 2026
d4ec4fc
Test a result's to_h and a nil slice field
tannevaled Oct 18, 2026
85379b5
Special: call one- and two-real ufuncs directly, not through reflect …
tannevaled Oct 18, 2026
a881de2
cells: a runaway recursion's error shows twelve frames, not thousands
tannevaled Oct 18, 2026
2956206
go-embedded-ruby/ruby v0.8.0, the released embedding API, instead of …
tannevaled Oct 18, 2026
f63439f
Tests on Windows: CRLF checkouts, and the system's own words for a mi…
tannevaled Oct 18, 2026
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
122 changes: 122 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,122 @@
name: ci

on:
push:
branches: [main]
pull_request:
branches: [main]

permissions:
contents: read

# Copied from go-notebook/notebook's ci.yml and adapted in two ways:
#
# - every lane runs twice where it matters, on rbgo's default build and on
# its rbgo_core build (-tags rbgo_core: the language and the numeric stack,
# no gem), which is what a notebook worker and a browser page link;
# - the cross-compile lane covers the targets rbgo itself builds for (its
# release matrix plus js/wasm), not every GOOS/GOARCH: rbgo's internal/vm
# does not compile for plan9, aix, solaris, illumos, the BSDs or 32-bit
# targets, so neither can anything that embeds it.
jobs:
test:
name: test (${{ matrix.os }}, ${{ matrix.tags || 'default' }})
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
tags: ['', rbgo_core]
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version: '1.27.2'
- run: go version
# Not on Windows: its checkout converts line endings to CRLF.
- name: gofmt
if: runner.os != 'Windows'
shell: bash
run: |
unformatted=$(gofmt -l .)
[ -z "$unformatted" ] || { echo "::error::not gofmt-formatted:"; echo "$unformatted"; exit 1; }
- run: go vet -tags "${{ matrix.tags }}" ./...
- run: go build -tags "${{ matrix.tags }}" ./...
- name: Test + 100% coverage gate
shell: bash
run: |
COVERPKG=$(go list ./... | paste -sd, -)
go test -tags "${{ matrix.tags }}" -race -coverpkg="$COVERPKG" -coverprofile=cover.out ./...
go tool cover -func=cover.out | tail -n 25
cov=$(go tool cover -func=cover.out | tail -1 | awk '{print $3}' | tr -d '%')
echo "coverage: ${cov}%"
awk -v t="$cov" 'BEGIN { exit !(t+0 >= 100.0) }' || {
echo "::error::coverage ${cov}% < 100%"; exit 1; }

security:
name: govulncheck + fuzz
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version: '1.27.2'
- name: govulncheck
run: go run golang.org/x/vuln/cmd/govulncheck@v1.8.0 ./...
- name: Fuzz the binding arguments for 60 s
run: go test -tags rbgo_core -run '^$' -fuzz FuzzBindingArguments -fuzztime 60s .

arch-native:
name: arch arm64
runs-on: ubuntu-26.04-arm
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version: '1.27.2'
- run: go vet ./... && go test ./... && go test -tags rbgo_core ./...

arch-qemu:
name: arch ${{ matrix.goarch }} (qemu)
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
include:
- { goarch: riscv64, qemu: qemu-riscv64-static }
- { goarch: loong64, qemu: qemu-loongarch64-static }
- { goarch: ppc64le, qemu: qemu-ppc64le-static }
- { goarch: s390x, qemu: qemu-s390x-static }
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version: '1.27.2'
- run: sudo apt-get update && sudo apt-get install -y qemu-user-static
- name: Vet + test under qemu (${{ matrix.goarch }})
run: |
GOOS=linux GOARCH=${{ matrix.goarch }} go vet -tags rbgo_core ./...
GOARCH=${{ matrix.goarch }} go test -tags rbgo_core -short -exec=${{ matrix.qemu }} ./...

cross:
name: compile on every target rbgo builds for
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
- uses: actions/setup-go@v7
with:
go-version: '1.27.2'
- name: go test -c for each target, both builds
shell: bash
run: |
fail=0
for t in linux/amd64 linux/arm64 linux/riscv64 linux/loong64 linux/ppc64le linux/s390x \
darwin/amd64 darwin/arm64 windows/amd64 windows/arm64 wasip1/wasm js/wasm; do
os=${t%/*}; arch=${t#*/}
for tags in "" rbgo_core; do
for p in $(go list ./...); do
GOOS=$os GOARCH=$arch go test -tags "$tags" -c -o /dev/null "$p" >/dev/null 2>err.txt || { echo "::error::$t [$tags] $p"; cat err.txt; fail=1; }
done
done
done
exit $fail
Loading
Loading