digidem / digidem/comapeo-core-react-native
CI: fast package-lint job (publint + attw + tarball-contents assertion)
Nobody has claimed this yet.
- Dominant language
- Kotlin
- Stars
- 1
- Forks
- 0
- Avg merge
- 8h 24m
- Merged PRs (30d)
- 9
Description
Problem
The example app consumes the module via a Metro alias to the repo root (apps/example/metro.config.js → @comapeo/core-react-native: '../..'), and all existing CI consumes the workspace source, never the packed tarball. Nothing today catches a missing files entry, an unbuilt native artifact, or a broken exports map — the classic "works locally, broken on npm" failure.
This module is especially exposed because most of what ships is generated and gitignored: android/src/main/jniLibs/**/*.so, android/src/main/assets/nodejs-project/, ios/Frameworks/**.xcframework, ios/nodejs-project/, android/libnode/, and build/. A regression in the files array or a platform-gated build step (e.g. publishing from Linux → empty ios/Frameworks/) would pass all current tests and produce a runtime-broken package.
Proposed: fast PR-level package-lint job
Cheap checks that run on every PR (seconds, reuse existing download:nodejs-mobile + backend:build steps on a macOS runner):
-
publint— validatesexports/main/typesresolution. -
@arethetypeswrong/cli— catches ESM/CJS + types mismatches across the.and./sentryexport conditions. - Tarball-contents assertion —
npm pack --json, then assert the tarball contains at least oneandroid/src/main/jniLibs/**/*.so, oneios/Frameworks/**.xcframework, the Android + iOSnodejs-projectbundles,android/libnode/bin/**/libnode.so, andbuild/index.js. This is the highest value-per-second check and would have caught a Linux-published (iOS-less) tarball.
Context
Spun off from the release workflow PR (.github/workflows/release.yml). See the build pipeline in scripts/build-backend.ts and the files array in package.json.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with .github/workflows/release.yml, scripts/build-backend.ts, and the files array in package.json; inspect how the existing download:nodejs-mobile and backend:build steps run on macOS. Add a fast PR-level package-lint job using the proposed package checks and tarball assertions, and verify it catches missing Android, iOS, nodejs-project, libnode, or build artifacts.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- github-actions, typescript
- Domain
- build-system, ci-cd, release
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 68/100