From 77f90eb61a68fea6fa733a7948c0de2f2311b0da Mon Sep 17 00:00:00 2001
From: Waozi
Date: Thu, 22 Oct 2026 15:47:16 -0300
Subject: [PATCH] Keep Tai Chi data distinct from executable binaries and
record the owner Moto waiver
---
.github/workflows/release.yml | 2 +-
CONTRIBUTING.md | 2 +-
Makefile | 2 +-
README.md | 8 +--
.../taichi/{course.bin => course.tch} | Bin
design/tai-chi/README.md | 4 +-
design/tai-chi/tools/export-app.mjs | 10 ++--
docs/building.md | 10 ++--
docs/fdroid.md | 4 ++
scripts/check-phone-check.py | 13 +++++
scripts/practice_content.py | 2 +-
scripts/prepare-package-assets.py | 4 +-
scripts/release.py | 48 ++++++++++++------
src/practices/tai_chi/tai_chi_course.zi | 8 +--
src/practices/tai_chi/tai_chi_rules.zi | 2 +-
src/practices/tai_chi/tai_chi_timeline.zi | 2 +-
tests/locale_keys_test.py | 6 +--
tests/phone_check_gate_test.py | 13 +++++
tests/practice_narration_keys_test.py | 2 +-
tests/tai_chi_behavior.zi | 4 +-
tests/tai_chi_zi_test.sh | 2 +-
21 files changed, 100 insertions(+), 48 deletions(-)
rename assets/practices/taichi/{course.bin => course.tch} (100%)
diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml
index 76d371bb7..28dcab431 100644
--- a/.github/workflows/release.yml
+++ b/.github/workflows/release.yml
@@ -958,7 +958,7 @@ jobs:
done < <(scripts/list-expected-release-assets.sh "$VERSION")
exit "$missing"
- - name: Require a Passing Phone Check for a New Version
+ - name: Require Phone Check or Explicit Owner Waiver for a New Version
run: |
set -euo pipefail
VERSION=$(python3 scripts/check-version.py --print-version)
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index f559a1519..5823f0d3f 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -9,7 +9,7 @@ For a security issue, use [Security](SECURITY.md).
## Development
Build with `make native cells`. Dependencies and the Ziran toolchain are pinned
-in `ziran.lock`; see [README](README.md#build) for other platforms. Read
+in `ziran.lock`; see [build guide](docs/building.md) for other platforms. Read
[AGENTS.md](AGENTS.md) for repository conventions and
[app packages](docs/cells.md) for module ownership.
diff --git a/Makefile b/Makefile
index 6abeee9cf..56c3df875 100644
--- a/Makefile
+++ b/Makefile
@@ -371,7 +371,7 @@ SYSTEM_THEME_CFLAGS :=
SYSTEM_THEME_LDLIBS :=
LOCALE_FILES := $(wildcard locales/*.txt)
-IMAGE_FILES := assets/app/icon.png assets/easteregg/art.png assets/easteregg/waozi.png assets/practices/whm/1.png assets/practices/whm/2.png assets/practices/meditation/1.png assets/pet/egg1.png $(wildcard assets/practices/*/banner*.png) $(wildcard assets/practices/sunsalutation/characters/*/*.png) $(wildcard assets/practices/taichi/*.png assets/practices/taichi/*/*.png) assets/practices/taichi/course.bin
+IMAGE_FILES := assets/app/icon.png assets/easteregg/art.png assets/easteregg/waozi.png assets/practices/whm/1.png assets/practices/whm/2.png assets/practices/meditation/1.png assets/pet/egg1.png $(wildcard assets/practices/*/banner*.png) $(wildcard assets/practices/sunsalutation/characters/*/*.png) $(wildcard assets/practices/taichi/*.png assets/practices/taichi/*/*.png) assets/practices/taichi/course.tch
SOUND_FILES := $(wildcard assets/sounds/*.ogg)
FONT_SUBSET_DIR := assets/fonts/subset
FONT_SUBSET_CORPUS := locales assets/fonts/input_common.txt assets/fonts/ui_symbols.txt assets/practices/astral_projection/text assets/practices/workout/text
diff --git a/README.md b/README.md
index 3b66305bd..6d030aa1c 100644
--- a/README.md
+++ b/README.md
@@ -23,7 +23,7 @@ account to sync across devices.
## Make space for yourself
- **Practice:** guided breathing, meditation, Astral Projection, Sun Salutation,
- Tai Chi and a 7-Minute Workout, with animated guides and optional narration.
+ a 7-Minute Workout, with animated guides and optional narration.
- **Habits:** track daily goals, practices and habits you want to avoid; follow
your history and choose your own rewards.
- **Diary and Photos:** write, reflect and keep pictures together, with shared
@@ -51,14 +51,16 @@ account to sync across devices.
Habits · Diary · Lumi
+Tai Chi is an optional Dew unlock outside Google Play.
+
## Your data and choices
Your data is stored locally. Account sync is optional. Lumi starts offline;
connecting an AI provider asks for your agreement to the data sharing shown
in the app. Use Inner Breeze's service or configure your own provider.
-[Privacy policy](site/static/privacy.html)
-· [Account and sync](docs/ACCOUNT_ACTIVITY.md)
+[Privacy policy](https://inbe.waozi.xyz/privacy.html)
+· [Account recovery and sync](docs/SYNC_RECOVERY.md)
· [Appearance](docs/appearance.md)
## Build and contribute
diff --git a/assets/practices/taichi/course.bin b/assets/practices/taichi/course.tch
similarity index 100%
rename from assets/practices/taichi/course.bin
rename to assets/practices/taichi/course.tch
diff --git a/design/tai-chi/README.md b/design/tai-chi/README.md
index e06fcd815..e42794225 100644
--- a/design/tai-chi/README.md
+++ b/design/tai-chi/README.md
@@ -143,7 +143,7 @@ not fit (Sun Salutation's 991 frames per character are about 10 MB; the
24-form would be about 100 MB per character), so the app samples and solves
the key poses the way the studio does:
-- `node tools/export-app.mjs` writes `assets/practices/taichi/course.bin`
+- `node tools/export-app.mjs` writes `assets/practices/taichi/course.tch`
(key poses, rigs, part anchors and the course outline; its layout is
described at the top of the tool), the two painted characters at 0.65
scale with 256-colour palettes, the floor shadow, the course words as
@@ -156,6 +156,6 @@ the key poses the way the studio does:
vertices for both characters must match.
After changing choreography, the solver or the painted layout, run the
-export again, commit the new `course.bin` and reference, and translate any
+export again, commit the new `course.tch` and reference, and translate any
new words in `text/.txt` (the export prints how many there are); the
course words live in Inbe's `locales/*.txt` as `tai_chi_text_*` entries.
diff --git a/design/tai-chi/tools/export-app.mjs b/design/tai-chi/tools/export-app.mjs
index 696cf73a4..b3fdc21f8 100644
--- a/design/tai-chi/tools/export-app.mjs
+++ b/design/tai-chi/tools/export-app.mjs
@@ -5,12 +5,12 @@
// node tools/export-app.mjs
//
// Writes (paths from the Inbe repository root):
-// assets/practices/taichi/course.bin keys, course outline, rigs
+// assets/practices/taichi/course.tch keys, course outline, rigs
// assets/practices/taichi/flat-edge.png soft edges of the figure's shapes
// design/tai-chi/text/en.txt course words as locale entries
// tests/fixtures/tai-chi-reference.json sampled poses, joints, shapes
//
-// course.bin is little-endian. Every string is a u16 byte length and UTF-8
+// course.tch is little-endian. Every string is a u16 byte length and UTF-8
// bytes; a string index of -1 means none. Sections in order:
// "TCH2"
// strings: u32 count, strings (locale keys and asset paths)
@@ -302,7 +302,7 @@ function rigValue(rig, field) {
return match ? rig.spine[Number(match[1])] : rig[field]
}
-// --- Write course.bin --------------------------------------------------------
+// --- Write course.tch --------------------------------------------------------
const characterRecords = characters.map((entry) => ({
id: stringId(entry.id),
@@ -391,7 +391,7 @@ for (const module of outline) {
}
const binary = writer.finish()
mkdirSync(ASSET_DIR, { recursive: true })
-writeFileSync(join(ASSET_DIR, 'course.bin'), binary)
+writeFileSync(join(ASSET_DIR, 'course.tch'), binary)
// --- Words ---------------------------------------------------------------------
@@ -485,5 +485,5 @@ const roundDeep = (value) => (typeof value === 'number' ? Math.round(value * 1e6
writeFileSync(REFERENCE_FILE, `${JSON.stringify(roundDeep(reference))}\n`)
const keyCount = keySets.reduce((sum, set) => sum + set.length, 0)
-console.log(`course.bin: ${(binary.length / 1024).toFixed(0)} KB, ${keySets.length} key sets, ${keyCount} keys, ${strings.length} strings, ${words.size} words to translate`)
+console.log(`course.tch: ${(binary.length / 1024).toFixed(0)} KB, ${keySets.length} key sets, ${keyCount} keys, ${strings.length} strings, ${words.size} words to translate`)
console.log(`items: ${itemIds.length}; reference samples: ${reference.samples.length}`)
diff --git a/docs/building.md b/docs/building.md
index 7499dbb25..29536cf57 100644
--- a/docs/building.md
+++ b/docs/building.md
@@ -1,5 +1,10 @@
# Building Inner Breeze
+The owner may explicitly waive the development Moto check for a particular
+release with `python3 scripts/release.py --phone-check-waiver "owner's authorization"`.
+This records a version- and content-bound waiver, without claiming a passing
+phone test. All other release gates still run.
+
The build checks Inbe's laws with the Ziran compiler (`ziran check`); no
separate proof tool is needed. The build host needs Python 3 and the platform's
@@ -38,9 +43,6 @@ make site
Run the test suite:
-[Custom appearance](appearance.md) describes live KSS editing, per-app
-customizations, reset, and Lumi's appearance tools.
-
```bash
make test
make visual-test
@@ -127,7 +129,7 @@ make sync-server-test DAOCHI_BIN=/absolute/path/to/daochi
```
This uses disposable client databases and a loopback server; see
-[web and sync test coverage](WEB_RENDERER_TESTS.md) for details.
+[web and sync test coverage](../WEB_RENDERER_TESTS.md) for details.
The Apps picker, independent ZIB packages, update settings, account choices and
publisher setup are described in [app packages](cells.md).
diff --git a/docs/fdroid.md b/docs/fdroid.md
index b712f1d57..5a166dd1e 100644
--- a/docs/fdroid.md
+++ b/docs/fdroid.md
@@ -31,6 +31,10 @@ A fresh clone failed with `fatal: unable to read tree`, before Gradle ran.
The current lock pins the replacement history. Never rewrite public package
history after an application has released a lock referring to it.
+The clean scan also caught Tai Chi's animation data named `course.bin` as a
+generic binary. Its `TCH2` data format now uses `course.tch`, including the
+exporter, package and reader. No executable scanner rule or path is ignored.
+
The upstream F-Droid entry must use the full commit of a successfully
published release and its corresponding `inbe-VERSION-fdroid.apk` binary.
A passing GitHub check does not mean F-Droid has merged or distributed that
diff --git a/scripts/check-phone-check.py b/scripts/check-phone-check.py
index 3b66328b4..a39d69f14 100644
--- a/scripts/check-phone-check.py
+++ b/scripts/check-phone-check.py
@@ -40,6 +40,16 @@ def validate(root, version, revision="HEAD"):
raise ValueError(f"{version} has no phone check; run make release with the development Moto "
"connected")
receipt = json.loads(path.read_text())
+ if receipt.get("schema") == 3 and receipt.get("status") == "waived":
+ if receipt.get("version") != version:
+ raise ValueError("the owner waiver is for a different version")
+ if not isinstance(receipt.get("reason"), str) or not receipt["reason"].strip():
+ raise ValueError("the owner waiver must state the explicit authorization")
+ if receipt.get("app_tree") != phone_check.app_tree(root, revision):
+ raise ValueError("the app changed after its owner waiver")
+ if receipt.get("passed") is not None or receipt.get("practice") is not None:
+ raise ValueError("a waived check must not claim a passing phone test")
+ return receipt
if receipt.get("schema") != 2:
raise ValueError("the phone check was recorded without the app's content; run make release again")
if receipt.get("version") != version:
@@ -73,6 +83,9 @@ def main():
except (OSError, ValueError, subprocess.CalledProcessError) as error:
print(f"Phone check required: {error}", file=sys.stderr)
return 1
+ if receipt.get("status") == "waived":
+ print(f"{args.version}: Moto check waived by owner: {receipt['reason']}")
+ return 0
timing = receipt["practice"]
print(f"{args.version} passed its phone check on {receipt['device']['model']}: {timing['fps']} fps, "
f"{timing['late_percent']}% late frames")
diff --git a/scripts/practice_content.py b/scripts/practice_content.py
index bc6757557..63ed8e82a 100644
--- a/scripts/practice_content.py
+++ b/scripts/practice_content.py
@@ -195,7 +195,7 @@ def prepare(compiler):
raise ValueError('unsupported practice content configuration')
speech = json.loads((ROOT / configuration['narration']['taichi']['config']).read_text())
declared = json.loads((ROOT / speech['keys_file']).read_text())
- if course_narration_keys((ROOT / 'assets/practices/taichi/course.bin').read_bytes()) != declared:
+ if course_narration_keys((ROOT / 'assets/practices/taichi/course.tch').read_bytes()) != declared:
raise ValueError('export Tai Chi again to update its narration inventory')
astral = json.loads((ROOT / 'assets/practices/astral_projection/session.json').read_text())
astral_speech = json.loads((ROOT / configuration['narration']['astral_projection']['config']).read_text())
diff --git a/scripts/prepare-package-assets.py b/scripts/prepare-package-assets.py
index f406b1163..f563e480e 100644
--- a/scripts/prepare-package-assets.py
+++ b/scripts/prepare-package-assets.py
@@ -79,10 +79,10 @@ for file in sorted({p for pattern in patterns for p in ROOT.glob(pattern) if p.i
path = path.removeprefix(prefix)
target = OUTPUT / owner / path
target.parent.mkdir(parents=True, exist_ok=True)
- if path == 'assets/practices/taichi/course.bin':
+ if path == 'assets/practices/taichi/course.tch':
# Keep the exported data exact; only its packaged representation is
# compressed. Fixed metadata makes repeated builds byte-identical.
- member = zipfile.ZipInfo('course.bin', (1980, 1, 1, 0, 0, 0))
+ member = zipfile.ZipInfo('course.tch', (1980, 1, 1, 0, 0, 0))
member.create_system = 3
member.compress_type = zipfile.ZIP_DEFLATED
member.external_attr = 0o644 << 16
diff --git a/scripts/release.py b/scripts/release.py
index def962c51..af957c644 100755
--- a/scripts/release.py
+++ b/scripts/release.py
@@ -22,6 +22,7 @@ Nothing is pushed or tagged. Pushing master starts the Release workflow, so it
waits for the owner's say-so.
"""
import argparse
+from datetime import datetime, timezone
import fnmatch
import importlib.util
import json
@@ -261,7 +262,11 @@ def main():
parser.add_argument("--apk", type=Path, help="an APK built from the current sources")
parser.add_argument("--host", default=os.environ.get("INBE_PHONE_HOST", "auto"))
parser.add_argument("--serial", default=os.environ.get("INBE_PHONE_SERIAL", "ZE2223BQZT"))
+ parser.add_argument("--phone-check-waiver", metavar="OWNER_AUTHORIZATION",
+ help="skip the Moto only when explicitly authorized by the owner for this release")
args = parser.parse_args()
+ if args.phone_check_waiver is not None and not args.phone_check_waiver.strip():
+ parser.error("the phone-check waiver must quote the owner's explicit authorization")
try:
if git("symbolic-ref", "--short", "HEAD").strip() != "master":
raise Refused("releases are made on master")
@@ -297,28 +302,41 @@ def main():
if phone_check.app_tree(ROOT) != checked_app:
raise Refused("app files changed on disk; commit them or wait for their owner")
- phone = phone_check.Phone(phone_check.resolve_host(args.host, args.serial), args.serial)
- if phone.adb("get-state").decode().strip() != "device":
- raise Refused("the development Moto is not connected and authorized")
- if args.apk:
- apk = args.apk.resolve(strict=True)
+ if args.phone_check_waiver:
+ receipt = dict(schema=3, status="waived", version=version, app_tree=checked_app,
+ source_commit=git("rev-parse", "HEAD").strip(),
+ reason=args.phone_check_waiver.strip(),
+ authorized_at=datetime.now(timezone.utc).isoformat(timespec="seconds"))
+ target = ROOT / phone_check.RECEIPTS / f"{version}.json"
+ target.parent.mkdir(parents=True, exist_ok=True)
+ target.write_text(json.dumps(receipt, indent=2) + "\n")
+ step("Moto check explicitly waived by owner for this release")
else:
- step("Building the debug APK for the Moto")
- apk = build_apk(phone)
- if phone_check.app_tree(ROOT) != checked_app:
- raise Refused("app files changed during the build; run make release again")
+ phone = phone_check.Phone(phone_check.resolve_host(args.host, args.serial), args.serial)
+ if phone.adb("get-state").decode().strip() != "device":
+ raise Refused("the development Moto is not connected and authorized")
+ if args.apk:
+ apk = args.apk.resolve(strict=True)
+ else:
+ step("Building the debug APK for the Moto")
+ apk = build_apk(phone)
+ if phone_check.app_tree(ROOT) != checked_app:
+ raise Refused("app files changed during the build; run make release again")
- step(f"Phone check of {apk.name} on the Moto")
- subprocess.run([sys.executable, ROOT / "scripts/phone-check.py", apk, "--record",
- "--host", phone.host, "--serial", args.serial], check=True)
+ step(f"Phone check of {apk.name} on the Moto")
+ subprocess.run([sys.executable, ROOT / "scripts/phone-check.py", apk, "--record",
+ "--host", phone.host, "--serial", args.serial], check=True)
receipt = gate.validate(ROOT, version)
if receipt["app_tree"] != checked_app:
raise Refused("the recorded check is for other app content")
step("Release commit")
- practice = receipt["practice"]
- details = (f"Phone check on the {receipt['device']['model']}: {practice['fps']} fps, "
- f"{practice['late_percent']}% late frames, app content {checked_app[:12]}.")
+ if receipt.get("status") == "waived":
+ details = f"Moto check waived by owner: {receipt['reason']} App content {checked_app[:12]}."
+ else:
+ practice = receipt["practice"]
+ details = (f"Phone check on the {receipt['device']['model']}: {practice['fps']} fps, "
+ f"{practice['late_percent']}% late frames, app content {checked_app[:12]}.")
commit_files([f"{phone_check.RECEIPTS}/{version}.json"], version,
amend=release_at_head(version), details=details)
gate.validate(ROOT, version, "HEAD")
diff --git a/src/practices/tai_chi/tai_chi_course.zi b/src/practices/tai_chi/tai_chi_course.zi
index e6480e21b..7688cd9d6 100644
--- a/src/practices/tai_chi/tai_chi_course.zi
+++ b/src/practices/tai_chi/tai_chi_course.zi
@@ -1,6 +1,6 @@
// The Tai Chi course as exported by design/tai-chi/tools/export-app.mjs:
// key poses, the painted characters and the outline of modules, lessons and
-// items. The layout of course.bin is described in that tool.
+// items. The layout of course.tch is described in that tool.
#import "binary"
#import "byte_text_linux"
#import "zip"
@@ -30,7 +30,7 @@ TAI_CHI_LESSON_CAPACITY :: 32
TAI_CHI_ITEM_CAPACITY :: 160
TAI_CHI_MARK_CAPACITY :: 1024
-// Item kinds and camera views, as numbered in course.bin.
+// Item kinds and camera views, as numbered in course.tch.
TAI_CHI_KIND_DRILL :: 0
TAI_CHI_KIND_LESSON :: 1
TAI_CHI_KIND_DEMO :: 2
@@ -366,7 +366,7 @@ TaiChiItemSourceValid :: (course: *TaiChiCourse, item: *TaiChiItem) -> bool {
item.scale > 0.0 && item.hold >= 0.0
}
-// Reads course.bin into `course`. A file that is cut short or does not
+// Reads course.tch into `course`. A file that is cut short or does not
// match the layout leaves the course unloaded.
#program_export
TaiChiCourseParse :: (course: *TaiChiCourse, bytes: string) -> bool {
@@ -407,7 +407,7 @@ TaiChiCourseParseArchive :: (course: *TaiChiCourse, bytes: string) -> bool {
archive[index] = bytes[index]
index += 1
}
- entry := FindZipEntry(archive, "course.bin")
+ entry := FindZipEntry(archive, "course.tch")
if !entry.found || entry.size == 0 || entry.size > TAI_CHI_COURSE_BYTES_MAX {
return false
}
diff --git a/src/practices/tai_chi/tai_chi_rules.zi b/src/practices/tai_chi/tai_chi_rules.zi
index 7bb21569d..5df686b9d 100644
--- a/src/practices/tai_chi/tai_chi_rules.zi
+++ b/src/practices/tai_chi/tai_chi_rules.zi
@@ -90,7 +90,7 @@ TaiChiViewSpecFor :: (view: s32) -> TaiChiViewSpec {
// --- Course and progress -------------------------------------------------------
-// Loads course.bin once from the package's assets.
+// Loads course.tch once from the package's assets.
TaiChiCourseReady :: (bytes: string) -> bool {
if tai_chi_course.loaded {
return true
diff --git a/src/practices/tai_chi/tai_chi_timeline.zi b/src/practices/tai_chi/tai_chi_timeline.zi
index ccc5e704a..fad4f5dec 100644
--- a/src/practices/tai_chi/tai_chi_timeline.zi
+++ b/src/practices/tai_chi/tai_chi_timeline.zi
@@ -25,7 +25,7 @@ TAI_CHI_STEP_PEEL :: 0.12
TAI_CHI_REFERENCE_HEEL_BACK :: 0.051
TAI_CHI_REFERENCE_BALL :: 0.1445
-// Channel numbers, in course.bin's order.
+// Channel numbers, in course.tch's order.
TAI_CHI_FACING :: 0
TAI_CHI_LOAD :: 1
TAI_CHI_SINK :: 2
diff --git a/tests/locale_keys_test.py b/tests/locale_keys_test.py
index 30e3bab24..e32852356 100644
--- a/tests/locale_keys_test.py
+++ b/tests/locale_keys_test.py
@@ -48,10 +48,10 @@ app_name_arcade app_name_chess app_name_photos
def tai_chi_course_keys():
- """The Tai Chi course's words: locale keys named in course.bin's strings."""
- data = (root / "assets/practices/taichi/course.bin").read_bytes()
+ """The Tai Chi course's words: locale keys named in course.tch's strings."""
+ data = (root / "assets/practices/taichi/course.tch").read_bytes()
if data[:4] != b"TCH2":
- failures.append("assets/practices/taichi/course.bin is not a course file")
+ failures.append("assets/practices/taichi/course.tch is not a course file")
return []
count = int.from_bytes(data[4:8], "little")
at = 8
diff --git a/tests/phone_check_gate_test.py b/tests/phone_check_gate_test.py
index ed5e2dac3..d390204e0 100644
--- a/tests/phone_check_gate_test.py
+++ b/tests/phone_check_gate_test.py
@@ -115,6 +115,19 @@ class PhoneCheckGateTest(unittest.TestCase):
with self.assertRaisesRegex(ValueError, "no phone check"):
gate.validate(self.root, "3.0.0")
+ def test_explicit_owner_waiver_is_bound_to_the_version_and_app(self):
+ waiver = {"schema": 3, "status": "waived", "version": "3.0.0",
+ "app_tree": self.checked_app, "reason": "Owner explicitly waived the Moto check"}
+ target = "releases/phone-checks/3.0.0.json"
+ self.commit({target: json.dumps(waiver)})
+ self.assertEqual(gate.validate(self.root, "3.0.0")["status"], "waived")
+ for changes in ({"version": "3.0.1"}, {"app_tree": "0" * 64}, {"reason": " "},
+ {"passed": True}, {"practice": {"fps": 60}}):
+ with self.subTest(changes=changes):
+ self.commit({target: json.dumps(waiver | changes)})
+ with self.assertRaises(ValueError):
+ gate.validate(self.root, "3.0.0")
+
def test_failed_or_mismatched_checks(self):
cases = {
"slow": lambda value: value["practice"].update(fps=41.0),
diff --git a/tests/practice_narration_keys_test.py b/tests/practice_narration_keys_test.py
index 8397cb8ac..56ce85cc5 100644
--- a/tests/practice_narration_keys_test.py
+++ b/tests/practice_narration_keys_test.py
@@ -9,7 +9,7 @@ from practice_content import course_narration_keys
config = json.loads((ROOT / 'design/tai-chi/narration.json').read_text())
actual = json.loads((ROOT / config['keys_file']).read_text())
-course = (ROOT / 'assets/practices/taichi/course.bin').read_bytes()
+course = (ROOT / 'assets/practices/taichi/course.tch').read_bytes()
expected = course_narration_keys(course)
assert len(expected) > 200
assert actual == expected, 'Export Tai Chi after changing spoken cues'
diff --git a/tests/tai_chi_behavior.zi b/tests/tai_chi_behavior.zi
index 891d125d2..d4bfe6ddc 100644
--- a/tests/tai_chi_behavior.zi
+++ b/tests/tai_chi_behavior.zi
@@ -1,7 +1,7 @@
// The Tai Chi course loads, and the app's motion and figure match the course
// studio's: sampled poses, solved joints and the flat figure's paint
// operations are compared with tests/fixtures/tai-chi-reference.json,
-// written by design/tai-chi/tools/export-app.mjs from the same course.bin.
+// written by design/tai-chi/tools/export-app.mjs from the same course.tch.
// A filled shape is compared by its area, centroid and bounds, a line by its
// ends and number of points.
#import "file"
@@ -231,7 +231,7 @@ TestWordsReadable :: (timeline: *TaiChiTimeline) -> bool {
#program_export
Check :: () -> s32 {
- bytes, ok := ReadEntireFile("assets/practices/taichi/course.bin")
+ bytes, ok := ReadEntireFile("assets/practices/taichi/course.tch")
if !ok {
return 1
}
diff --git a/tests/tai_chi_zi_test.sh b/tests/tai_chi_zi_test.sh
index 48d91a5f6..8e96f671f 100755
--- a/tests/tai_chi_zi_test.sh
+++ b/tests/tai_chi_zi_test.sh
@@ -17,7 +17,7 @@ import zipfile
root, work = map(Path, sys.argv[1:])
with zipfile.ZipFile(work / 'course.zip', 'w', zipfile.ZIP_DEFLATED,
compresslevel=9) as archive:
- archive.writestr('course.bin', (root / 'assets/practices/taichi/course.bin').read_bytes())
+ archive.writestr('course.tch', (root / 'assets/practices/taichi/course.tch').read_bytes())
PY
"$bin/zi2c" --no-main --root "$root/tests" --module-path "$root/src" \
--module-path "$root/build/packages/ziran/std" \