Skip to content

fix(differential): stop declaring the unregistered package so CI can instantiate - #314

Merged
hyperpolymath merged 3 commits into
validation/issue-23-native-dafrom
arena/a96f4abd-metamanifold-webui
Nov 8, 2026
Merged

hyperpolymath merged 3 commits into
validation/issue-23-native-dafrom
arena/a96f4abd-metamanifold-webui

Conversation

@hyperpolymath

Copy link
Copy Markdown
Owner

Change and reason

Julia tests was failing on #70 at Instantiate Julia project, so every step after it — RCall, the suite, coverage — was skipped. The cause is a single declaration:

Project.toml named CompositionalDA (bb1787b7-…) in [deps] and [compat], but the package is not in the General registry and there is no Manifest.toml entry to resolve it against. Pkg.instantiate() therefore cannot resolve the project and exits 1 on every checkout, CI included — before any test runs.

The module already imports the package opportunistically (_COMPOSITIONAL_DA_AVAILABLE), so the declaration is the only thing that has to go. This PR removes it and keeps the feature intact behind that guard:

  • Project.toml — the declaration is gone, replaced by a comment recording why it is absent and what must land together when it is registered (dependency + [compat] bound + regenerated Manifest.toml, in one change).
  • src/analysis/differential.jl — the refusal message no longer points at a Project.toml entry that no longer exists; compositional_da_available() is exported so callers (and tests) can ask the question the guard answers; the input checks (retained taxa, Int range) now run before the dependency probe, so a malformed matrix is refused for that reason whether or not the package is installed, on every machine.
  • tests — test_differential_native.jl began with import CompositionalDA, so the unit suite could not load at all without a package CI cannot install. Both native test files now branch on compositional_da_available(): the boundary fuzz, the oversize refusal and the constructor checks always run; without the package the refusal is what is asserted (both methods raise ArgumentError naming CompositionalDA, the route answers 400 invalid_input rather than a 500 or a table no model produced); with the package developed into the environment the adapter and ANCOM-BC comparisons run unchanged. Skips announce themselves with @info, like the existing R- and glmGamPoi-gated testsets.
  • docs/guide/web-interface.md — documents aldex2/ancombc, mc_samples/seed, and the package caveat the guide was missing.

No application logic changes: the estimators, their settings and their results are untouched.

Validation

The fork's action policy blocks julia-actions/* (verified: the dispatch fails with "…are not allowed in hyperpolymath/MetaManifold-WebUI because all actions must be from a repository owned by hyperpolymath, created by GitHub, verified in the GitHub Marketplace…"), so upstream's ci.yml cannot start here. The change was validated with a throwaway policy-compliant job on the same commit that reproduced the two steps that matter:

  • Pkg.instantiate() — success (this is the step that failed in Integration harness: profiles, merge hygiene, and granular re-anchor #70). Julia 1.12.5, R installed, RCall rebuilt against it.
  • julia --project=. test/runtests.jl test_differential test_differential_native — success: 1013 passed, 0 failed, 18 skipped (@test_skip).
    • Native configuration boundary fuzz — 790
    • Native input boundaries do not depend on the package — 5
    • Native methods refuse by name when the package is absent — 8
    • Route: native method override and input refusal — 16 (1 skipped: the adapter half)
    • Native compositional DA adapter, ANCOM-BC adapter… — skipped, package absent

The throwaway job did not restore renv, so glmGamPoi was absent; those five testsets fail by contract under CI=true when glmGamPoi is missing (issue #37), so the job ran with CI=false to have them skip loudly. In real CI they run — renv.lock installs glmGamPoi.

Frontend gates were run locally on this branch: bun install --frozen-lockfile, bun run build and bun test src (68 pass, 1 skip, 0 fail).

Not run here: the full CI job (DADA2/PR2/R suite, Agda, Codecov). Nothing in this diff touches them.

Scope

Follow-up, deliberately out of scope: activating the native methods for real. That needs either CompositionalDA registered in the General registry, or a [sources] git dependency — either way with the regenerated Manifest.toml in the same change. Until then aldex2/ancombc are wired, documented and refused by name.

Lockfiles: Manifest.toml and renv.lock are untouched; bun.lock is untouched.

Contribution checks

  • I followed CONTRIBUTING.md.
  • This branch starts at current upstream main and contains no merges from fork main.
  • Every commit is signed and shows as Verified.
  • CI has run and passes — it has not run yet: this branch is based on validation/issue-23-native-da, not main, so ci.yml's pull_request: branches: [main] does not trigger. Merging this into Integration harness: profiles, merge hygiene, and granular re-anchor #70's branch and re-running there is the intended path.
  • Existing licensing, citation and acknowledgement text is unchanged.

hyperpolymath and others added 3 commits November 8, 2026 01:34
`Pkg.instantiate()` failed in CI ("Julia tests": Instantiate Julia project),
so nothing downstream of it ran. `Project.toml` declared `CompositionalDA`,
which is not in the General registry and has no Manifest entry to resolve
against: the declaration alone is enough to make resolution fail for every
checkout, CI included.

The module already imports the package opportunistically, so the declaration is
what has to go. It is replaced by a note in `Project.toml` recording why it is
absent and what has to arrive with it (the dependency, its `[compat]` bound and
the regenerated `Manifest.toml`, in one change) once it is registered.

`compositional_da_available()` is exported so callers and tests can ask the
question the guard answers, and the refusal message now says where the package
comes from instead of pointing at a `Project.toml` entry that no longer exists.
The input checks (retained taxa, Int range) now run before the dependency
probe, so a malformed matrix is refused for that reason whether or not the
package is installed.

Co-authored-by: arena-agent <[email protected]>
`test_differential_native.jl` began with `import CompositionalDA`, so the unit
suite could not load at all without a package CI cannot install, and the route
test in `test_differential.jl` asserted a 200 from a method that could not run.

Both now branch on `compositional_da_available()`:

- The configuration boundary fuzz, the oversize-count refusal and the
  constructor errors run everywhere.
- Without the package, the refusal is what is tested: both native methods raise
  an `ArgumentError` naming `CompositionalDA` and pointing at `nb_glm`, and the
  route answers 400 `invalid_input` with that message rather than a 500 or a
  table of numbers no model produced.
- With the package developed into the environment, the adapter and ANCOM-BC
  comparisons run unchanged against it.

The skips announce themselves (`@info`) the way the R- and glmGamPoi-dependent
testsets in this file already do, so a silent gap is visible in the log.

Co-authored-by: arena-agent <[email protected]>
The web-interface guide listed only `nb_glm` and `clr_welch`, so `aldex2` and
`ancombc` were reachable through config and the UI without being described. It
now names both, says what they compute and which settings drive them
(`mc_samples`, `seed`), and states up front that they need `CompositionalDA`,
which is not installable yet, so the two methods refuse by name until it is
developed into the environment.

Co-authored-by: arena-agent <[email protected]>
@coderabbitai

coderabbitai Bot commented Nov 8, 2026

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on base/target branches other than the default branch.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

  • Source mode: Auto
  • Repository: Unavailable
  • Branch: Unavailable
  • File: No configuration file from this repository applied
  • Commit: Unavailable
  • Layers: Organization UI
  • Review profile: ASSERTIVE
  • Plan: Advanced
  • Run ID: becb195c-178e-4554-b0bb-52c50d2e7df3

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

@chatgpt-codex-connector

Copy link
Copy Markdown
Codex Review Summary: ❌ Failed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ❌ Failed 2026-11-08T01:52:43.725925Z
We couldn’t complete this review. Comment @codex review to try again.
d4b659f PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

Copy link
Copy Markdown
Owner Author

This is the analysis for upstream #70, posted here because the token used for this session has read-only access to JoshuaJewell/MetaManifold-WebUI (push: false) and cannot comment or edit there. The same text is saved as pr70-response.md in the session workspace for pasting upstream.

Two separate things are showing on #70. Neither is a finding against the code.

1. The Codex ❌ Failed badge is a quota message, not a failed review

chatgpt-codex-connector posted two comments, both of which are status/quota notices:

Codex Review Summary: ❌ Failed — We couldn't complete this review.
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.

So the review never ran: it hit the account's Codex review quota at 7888150. Nothing in this repository can change that — it resets on the plan's schedule, and @codex review re-triggers it (it would return the same message until then, which is why I have not spammed a retry).

For the record, there was nothing to resolve on the review side: this PR has 0 review threads and 0 inline review comments (reviewThreads.totalCount = 0). The two Codex comments are plain issue comments, which GitHub does not offer a "resolve" action for. There are also no CodeRabbit/Copilot/Qodo comments on this PR.

2. The real failing check: Julia tests dies at Instantiate Julia project

It fails in ~2 minutes at that step, so R setup, RCall, the suite and coverage never ran. Cause:

Project.toml declared CompositionalDA = "bb1787b7-…" in [deps] and [compat], but that package is not in the General registry (the registry has no C/CompositionalDA entry) and there is no Manifest.toml entry to resolve it against. Pkg.instantiate() therefore cannot resolve the project and exits 1 on every checkout — the declaration alone is enough, before a single test runs. The last commit on this branch already anticipated this ("the dependency and its resolved Manifest are the outstanding step for this PR"), but it is a hard blocker for CI rather than a follow-up.

Fix: this PR (#314) — fix(differential): stop declaring the unregistered package so CI can instantiate (3 commits, 5 files), based on validation/issue-23-native-da so it merges cleanly into it.

  • Removes the unresolvable [deps]/[compat] entries and records in Project.toml what has to land together when the package is registered: the dep, its [compat] bound and the regenerated Manifest.toml, in one change.
  • Keeps the feature exactly as designed behind the existing _COMPOSITIONAL_DA_AVAILABLE guard, adds an exported compositional_da_available(), and moves the input checks (retained taxa, Int range) ahead of the dependency probe so a malformed matrix is refused for that reason on every machine.
  • Makes the tests branch on availability instead of import CompositionalDA at the top of the file — which currently makes the whole unit suite unloadable wherever the package is absent. Without the package the refusal itself is asserted (both methods name CompositionalDA; the route returns 400 invalid_input, not a 500 and not a table no model produced).
  • Documents aldex2/ancombc, mc_samples and seed in docs/guide/web-interface.md, which this PR did not update.

Validation of #314 (throwaway job on the same tree; the fork's action policy blocks julia-actions/*, so ci.yml cannot start in the fork — that is also why this PR's ci.yml has never run inside the fork):

Step Result
Pkg.instantiate() ✅ passes (fails here as pushed)
julia --project=. test/runtests.jl test_differential test_differential_native ✅ 1013 passed, 0 failed, 18 skipped

Native configuration boundary fuzz 790 · Native input boundaries 5 · Native methods refuse by name 8 · Route: native method override and input refusal 16 · the two adapter testsets skip (they need the package). Frontend gates were run locally too: bun run build and bun test src → 68 pass, 1 skip, 0 fail.

Next step

  1. Merge fix(differential): stop declaring the unregistered package so CI can instantiate #314 into validation/issue-23-native-da.
  2. Re-run the CI workflow on this PR. The instantiate step should pass and the suite should go green; the native adapter parity tests stay skipped until CompositionalDA is registered (or added as a [sources] git dependency with its regenerated Manifest.toml) — that is the one piece of this PR that still cannot run in CI.

Merging this PR into validation/issue-23-native-da updates #70's head and re-triggers upstream CI, which is the only way to see the real job go green — the fork cannot run ci.yml at all (action policy).

@sonarqubecloud

sonarqubecloud Bot commented Nov 8, 2026

Copy link
Copy Markdown

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits. You can see your limits in the Codex usage dashboard.

@hyperpolymath
hyperpolymath merged commit be7792f into validation/issue-23-native-da Nov 8, 2026
3 checks passed
@hyperpolymath
hyperpolymath deleted the arena/a96f4abd-metamanifold-webui branch November 8, 2026 01:59
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.

2 participants