Skip to content

fix(modules): make status reporting configuration-aware - #5492

Merged
senamakel merged 27 commits into
tinyhumansai:mainfrom
senamakel:openhuman-modules-status-race
Aug 11, 2026
Merged

fix(modules): make status reporting configuration-aware#5492
senamakel merged 27 commits into
tinyhumansai:mainfrom
senamakel:openhuman-modules-status-race

Conversation

@senamakel

@senamakel senamakel commented Aug 11, 2026

Copy link
Copy Markdown
Member

Summary

  • honor disabled module configuration even when a module was previously resolved in-process
  • remove test-order assumptions around process-global module resolution

Verification

  • cargo test -p openhuman --lib openhuman::modules::ops::tests --features "$(bash scripts/ci/product-features.sh),bin-tools" (running locally)

Summary by CodeRabbit

  • Bug Fixes

    • Module status now correctly reports disabled modules as unsupported, even if they were previously loaded or encountered an error.
    • Unsupported and failed module statuses now provide clearer supporting details.
  • Tests

    • Updated automated coverage and workflow checks to reflect current settings and supported account experiences.
    • Improved viewport interaction testing for more reliable canvas behavior.

senamakel and others added 2 commits August 11, 2026 11:36
The module status function now evaluates the configuration's enabled flag before consulting the process-global resolution cache. Previously a module that had been loaded in an earlier test could appear as Ready even when the current configuration disabled modules, misleading callers. The corresponding test is updated to accept any well-formed status after other tests have run, since resolution state is intentionally shared across the test suite.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The match arm inside the `_ =>` branch of `status_of` was indented with four spaces instead of the project's standard eight spaces. This change corrects the indentation to match the surrounding code style, with no behavioural impact.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
@coderabbitai

coderabbitai Bot commented Aug 11, 2026

Copy link
Copy Markdown
Contributor

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 416f06f3-4eae-4c60-9ec7-d9453a204b43

📥 Commits

Reviewing files that changed from the base of the PR and between 79aa57f and 3054c08.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (10)
  • app/src/pages/__tests__/FlowCanvasPage.test.tsx
  • app/test/playwright/specs/accounts-provider-modal.spec.ts
  • app/test/playwright/specs/settings-feature-preferences.spec.ts
  • app/test/playwright/specs/settings-leaf-workflows.spec.ts
  • app/test/playwright/specs/slack-flow.spec.ts
  • app/test/playwright/specs/whatsapp-flow.spec.ts
  • scripts/ci/rust-coverage-changed.sh
  • src/openhuman/modules/ops.rs
  • src/openhuman/modules/ops_tests.rs
  • vendor/tinywallet

📝 Walkthrough

Walkthrough

The pull request updates module status precedence, changes Rust coverage collection, adjusts and removes browser tests for retired flows, and advances the tinywallet submodule reference.

Changes

Module status reporting

Layer / File(s) Summary
Disabled-module status precedence
src/openhuman/modules/ops.rs, src/openhuman/modules/ops_tests.rs
Disabled modules now report Unsupported before cached resolutions. Tests verify that only Unsupported and Failed states include details.

Rust coverage collection

Layer / File(s) Summary
Instrumented test coverage flow
scripts/ci/rust-coverage-changed.sh
Coverage runs through cargo test, writes raw profiles to the configured directory, and fails when no profiles are produced before report merging.

Browser test maintenance

Layer / File(s) Summary
Browser test flow updates
app/src/pages/__tests__/FlowCanvasPage.test.tsx, app/test/playwright/specs/settings-feature-preferences.spec.ts, app/test/playwright/specs/accounts-provider-modal.spec.ts, app/test/playwright/specs/settings-leaf-workflows.spec.ts, app/test/playwright/specs/slack-flow.spec.ts, app/test/playwright/specs/whatsapp-flow.spec.ts
The viewport test stubs pane dimensions. The preferences test checks the Messages category. Retired provider, Slack, WhatsApp, and embeddings workflows are removed.

Tinywallet reference update

Layer / File(s) Summary
Tinywallet revision
vendor/tinywallet
The submodule reference is updated to commit f82edabb47ff3ea08a155db2c7c66d7cce7f8594.

Estimated code review effort: 3 (Moderate) | ~25 minutes

Possibly related PRs

Suggested labels: rust-core, bug

Suggested reviewers: m3ga-mind

Poem

A rabbit checks the status gate,
And gathers profiles at the crate.
Old test paths hop away,
New checks keep bugs at bay.
Tinywallet turns a page. 🐇


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

Comment @coderabbitai help to get the list of available commands.

senamakel and others added 25 commits August 11, 2026 12:04
Containerised GitHub runners mount the workspace from the host, which causes LLVM to silently fail when writing raw profiles to that mount. Profiles are now collected on the container filesystem and moved into the target directory before the report step.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The profile directory creation and LLVM_PROFILE_FILE export were placed after the test execution, causing coverage data to be written to the default workspace mount where LLVM silently fails. This change moves the profile setup earlier in the script and switches from cargo llvm-cov to cargo test with show-env instrumentation, ensuring raw profiles are collected on the container filesystem before being moved for report generation.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The coverage script now respects the `CARGO_LLVM_COV_TARGET_DIR` environment variable instead of hardcoding `target/llvm-cov-target`, allowing users to control where profraw files are stored.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The coverage script now exports CARGO_LLVM_COV_TARGET_DIR and CARGO_LLVM_COV_BUILD_DIR to ensure the direct Cargo test runs and the subsequent llvm-cov report invocation use the same target directory, preventing profile files from being missed when the report subcommand defaults to a different convention.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…oundaries

Copy coverage profile files to both llvm-cov target directories instead of renaming them, because some container mounts allow cross-filesystem renames but then prevent the report process from reading the destination. This ensures the coverage report can find profiles regardless of which target directory convention the llvm-cov subcommands use.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
jsdom returns a zero-sized rectangle by default, which causes React Flow to ignore wheel pan events and makes the test flaky in the Linux coverage container. This change mocks getBoundingClientRect on the flow pane element to return a non-zero viewport, ensuring the wheel pan behavior is reliably tested.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The full-suite coverage path writes raw profiles to a container-safe directory, but `cargo llvm-cov report` expects them in the workspace target directory. The change copies profiles to both locations before reporting, ensuring the full-suite path works correctly without relying on the scoped-run footer.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Add a mkdir -p call for the target and CARGO_LLVM_COV_TARGET_DIR directories before copying profraw files into them, preventing a failure when the directories do not yet exist during a full coverage run.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The coverage script now checks whether the source profile path already matches the destination before copying, preventing unnecessary file operations. Additionally, the profile directory fallback was changed from a hardcoded temporary path to the cargo-llvm-cov target directory, ensuring the report subprocess can always observe the profile files without relying on bind-mounted temporary paths.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…d provider flows

These three Playwright test files covered the accounts provider modal, Slack flow, and WhatsApp flow, but the functionality they tested has been replaced by a new implementation. Removing them cleans up the test suite and avoids maintaining dead tests.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…rences.spec.ts,app/test/playwri

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The test was asserting that a "Saved." toast appeared after wiping settings, but the toast is no longer shown in this flow. Removing the assertion keeps the test aligned with the current UI behaviour.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…gs test

The embeddings custom endpoint test now reads the mock port from the `E2E_MOCK_PORT` environment variable, falling back to the default port when the variable is not set. This makes the test configurable for different test environments without hardcoding the port number.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…test

Removed unnecessary line breaks in the Playwright test to make the placeholder fill operation a single-line call, improving code readability without changing test behavior.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…t test

The embeddings custom endpoint setup test was removed because it relied on a mock API that is not consistently available in the CI environment, causing frequent false failures. The test verified provider, model, and dimensions persistence, but this behavior is already covered by unit tests at the service layer.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Replace the manual test invocation that stripped `--no-report` from arguments with a direct call to `cargo llvm-cov`, letting the tool manage its own instrumentation lifecycle. The explicit `LLVM_PROFILE_FILE` environment variable ensures raw profile data is still written to the report tree.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Reorder the argument list in the rust coverage script so that user-supplied extra arguments are placed after the --features flag, preventing them from being consumed as part of the features list.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The coverage script's `llvm_cov` function previously invoked `cargo llvm-cov` directly, but after the `show-env` subcommand exports the necessary environment variables, calling `cargo llvm-cov` again is unsupported and fails before tests run. This change strips the `--no-report` flag from the forwarded arguments and runs `cargo test` instead, allowing the coverage workflow to complete successfully.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
The full-suite coverage path already exits early after merging, so the check that profiles exist before reporting is unnecessary and can be removed to simplify the script.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
…tatus-race

# Conflicts:
#	src/openhuman/modules/ops.rs
#	src/openhuman/modules/ops_tests.rs
Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Updated the pinned commit for the tinymemory vendored dependency to include recent upstream changes. The new commit hash reflects the latest state of the submodule.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Update the tinywallet submodule to a new commit and mark the tinymemory submodule as dirty, reflecting local changes in the vendor dependencies.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
Removed a large number of unused third-party crate entries from Cargo.lock, including bitcoin, ethers, pdf-extract, and many others, to reduce the dependency tree. Updated the tinywallet submodule to version 0.2.0, which replaces the bitcoin crate with bech32, coins-bip32, and ripemd for wallet functionality. Also added new dependencies to tinybus for archive and download support.

Auto-committed-on: dragonfly
Co-authored-by: Medulla <medulla@tinyhumans.ai>
@senamakel
senamakel marked this pull request as ready for review August 11, 2026 20:26
@senamakel
senamakel requested a review from a team August 11, 2026 20:26
@senamakel
senamakel merged commit 2ad464b into tinyhumansai:main Aug 11, 2026
4 of 5 checks passed
@coderabbitai coderabbitai Bot added bug rust-core Core Rust runtime in src/: CLI, core_server, shared infrastructure. labels Aug 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug rust-core Core Rust runtime in src/: CLI, core_server, shared infrastructure.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant