Skip to content

ci(governance): allow Java in android/**/src/**/*.java (platform-required JVM shims)#340

Merged
hyperpolymath merged 1 commit into
mainfrom
chore/android-java-shim-exemption
Jun 2, 2026
Merged

ci(governance): allow Java in android/**/src/**/*.java (platform-required JVM shims)#340
hyperpolymath merged 1 commit into
mainfrom
chore/android-java-shim-exemption

Conversation

@hyperpolymath
Copy link
Copy Markdown
Owner

Branch with 1 commit ahead of main; no PR previously opened. Filed during 2026-06-02 estate orphan-branch sweep.

…ired JVM shims)

Android instantiates Service / BroadcastReceiver / AppWidgetProvider /
Activity subclasses by class name at platform boundaries. The JVM
classloader demands bytecode implementing those superclasses — Rust /
Zig cannot satisfy this contract directly. Consumers writing mobile
apps via Gossamer (or any webview shell) need a minimal Java shim
surface that delegates immediately to native (JNI / Zig-FFI) code.

This carve-out exempts EXACTLY `android/**/src/**/*.java` paths
(anchored: `(^|/)android/.*/src/.*\.java$`). Properties:

* `.kt` / `.kts` remain fully banned (no Kotlin carve-out).
* Random `Foo.java` at repo root still fails.
* `not-android/.../src/.../Foo.java` still fails.
* Matches the established Android source-tree shape used by Gossamer
  upstream (`gossamer/android/src/main/java/io/gossamer/...`) and by
  consumers like neurophone (`android/app/src/main/java/ai/neurophone/...`).

Triggered by the neurophone Kotlin → Gossamer migration RFC
(hyperpolymath/neurophone#97). Without this carve-out the migration
cannot land cleanly because the four JVM-class-name boundaries above
are unavoidable.

Each Java shim added under this carve-out must be a minimal delegating
wrapper (typically <10 LoC) that JNIs into Rust/Zig immediately. The
shim contains no business logic.

No SHA bump required for the 6 consumers pinning `@main` (incl.
neurophone). 228 consumers pinning SHA `861b5e911d9e5dcfb3c0ab3dd2a9a3c8fd0a1613`
will need a SHA-bump fan-out post-merge — coordinate via the established
R5b campaign script.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@hyperpolymath hyperpolymath merged commit 7814dc6 into main Jun 2, 2026
18 checks passed
@hyperpolymath hyperpolymath deleted the chore/android-java-shim-exemption branch June 2, 2026 11:11
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 2, 2026

🔍 Hypatia Security Scan

Findings: 201 issues detected

Severity Count
🔴 Critical 64
🟠 High 43
🟡 Medium 94

⚠️ Action Required: Critical security issues found!

View findings
[
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Action for the check script)\n        uses: actions/checkout@de0f needs attention",
    "type": "unpinned_action",
    "file": "governance-reusable.yml",
    "action": "pin_sha",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in affinescript-verify.yml",
    "type": "missing_timeout_minutes",
    "file": "affinescript-verify.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in boj-build.yml",
    "type": "missing_timeout_minutes",
    "file": "boj-build.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in casket-pages.yml",
    "type": "missing_timeout_minutes",
    "file": "casket-pages.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in casket-pages.yml",
    "type": "missing_timeout_minutes",
    "file": "casket-pages.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in changelog-reusable.yml",
    "type": "missing_timeout_minutes",
    "file": "changelog-reusable.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in codeql-reusable.yml",
    "type": "missing_timeout_minutes",
    "file": "codeql-reusable.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in codeql.yml",
    "type": "missing_timeout_minutes",
    "file": "codeql.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  },
  {
    "reason": "Issue in deno-ci-reusable.yml",
    "type": "missing_timeout_minutes",
    "file": "deno-ci-reusable.yml",
    "action": "flag",
    "rule_module": "workflow_audit",
    "severity": "medium"
  }
]

Powered by Hypatia Neurosymbolic CI/CD Intelligence

@hyperpolymath hyperpolymath restored the chore/android-java-shim-exemption branch June 2, 2026 11:13
@hyperpolymath hyperpolymath deleted the chore/android-java-shim-exemption branch June 2, 2026 15:55
hyperpolymath added a commit that referenced this pull request Jun 2, 2026
Adds [session-history-2026-06-02] section capturing:

- 3 PRs merged today: #338 zotpress carve-out, #339 License Policy
  Manual-Only section, #340 Java/android exemption
- 4 standing/in-flight campaigns: #288/#323/#324 (CodeQL cron) +
  #331 (boj-build sweep)
- The 3-layer license auto-PR hardening (hypatia#414/#415 +
  gitbot-fleet#247 + standards#339) triggered by neurophone#99
- The auto-remediation companion: hypatia#422 (WF024/WF025/BH008
  detectors) + gitbot-fleet#251 (5 fix scripts)

last-updated bumped from 2026-04-04 → 2026-06-02. NO licence
or SPDX-header edits — the existing PMPL header is owner-managed
drift pending the manual sweep (see [[standards-agpl-intentional]]).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant