Skip to content

fix(gitsync): the image's own module copy is judged against an import's requires (Plugins#2715) - #6190

Merged
rbuergi merged 1 commit into
mainfrom
fix/image-copy-judged-against-requires
Oct 6, 2026
Merged

rbuergi merged 1 commit into
mainfrom
fix/image-copy-judged-against-requires

Conversation

@rbuergi

@rbuergi rbuergi commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Refs Systemorph/MeshWeaver.Plugins#2715. That issue is sev:H, so it closes after verification on a rolled instance, not when this merges.

Root cause

src/MeshWeaver.PluginCatalog/LoadedPackageModuleReader.cs (Resolve) is the reading that rule 1b (ModuleSyncDecision.DeclineUnmetRequirements, #6110) judges an import's requires against. It only stated a module that loaded from a landed generation. A module that loaded from the image's own copy was left out, and the comment called that "not judged". So rule 1b could never hold an import against the image copy, which is the most common copy there is.

It is live now on the control instance (memex.systemorph.com, image d205295 = 3.0.0-ci.9984, Plugins 29bfaefb). Read-only readings from 2026-10-06 ~06:45Z:

  • search nodeType:NodeType content.compilationStatus:Error partitions:all returns 21 types over 123 readable partitions. 20 of them are in Hosting, including Hosting/InstanceAction, Deployment, InstanceRequest, FleetConsole and TriageItem. All were compiled at 2026-10-05 23:25–23:26Z.
  • The compilationError on TriageItem and on an InstanceAction instance is CS0246/CS0103 LanePolicy, LaneScheduler, Lanes, and CS1061 ThreadDispatchPool.Allowance. Those are AI members from Plugins 4c5aa6437.
  • Plugins/Hosting was installed at 23:27:04Z. Its Hosting/index.json hash 52bb6e92… is Plugins 26aaaf092, which declares AI@^1.22.0.
  • The image's AI is stamped 1.21.1 (AI/manifest.lock at 29bfaefb), and 29bfaefb does not contain 4c5aa6437.
  • /health nodetype_bake lists all 20 Hosting types as failed. The InstanceAction NodeType is in Error, so instance actions on the control instance cannot run.

Fix

Tests

LoadedPackageModuleReaderTest, run locally: 10 of 10 pass.

  • The incident through the real decision. Hosting declares AI@^1.22.0 and the image AI is stamped 1.21.1, so the import is Declined and the reason names 1.21.1.
    • In-test negative control: the old reading (Resolve) lets the same tree go Synced, which is what happened on the control instance.
  • Negative control (run): with the image pass disabled, 2 of 10 go red: the incident test and TheImageCopyLoaded_ReadsTheSeedsVersion.
  • A landed generation that loaded wins. No stamp, no package and a foreign leaf all stay unjudged.
  • ImageCopiesOf reads a real stamp from disk.

What this does NOT do / not established

  • It does not fix the control instance as it stands. Hosting's sources are already written. Its 20 types recover when AI ≥ 1.22 is loaded there: either a roll to an image ≥ 3.0.0-ci.9995 (which ships AI 1.22.x), or the landed store AI 1.22.0 loading. After that, recycle Hosting/Deployment (the type cascades).
  • Not established: why the landed store AI 1.22.0 (Plugins/AI installed 2026-10-05 21:40Z, which carries LanePolicy) did not load at the 22:54Z boot, even though 1.22.0 > 1.21.1. The compile errors show that the loaded AI lacks LanePolicy. I did not read the pod's [ModuleLoad] lines: that is break-glass, and the governed Logs action needs Hosting/InstanceAction, which is down. So "the image copy loaded" is an inference from the compile errors, not a log reading.
  • A package that starts using a newer module without raising its requires is still not caught here. Plugins now stamps floors (mesh-floors.py).

Pairs-with: none — adds a public method and a public record; nothing is removed or re-signed.

🤖 Generated with Claude Code

…'s requires (Plugins#2715)

LoadedPackageModuleReader left a module that loaded from the IMAGE's copy out of the
reading ("absent means not judged"), so rule 1b (DeclineUnmetRequirements) could never
hold an import against the commonest copy there is. Measured on the control instance
2026-10-05: image Plugins 29bfaefb ships AI stamped 1.21.1; Hosting's tree declared
AI@^1.22.0 and called LanePolicy (AI 1.22 only); the import wrote Hosting's sources
and twenty Hosting NodeTypes, InstanceAction among them, parked at CS0246 LanePolicy.

- ResolveWithImageCopies: an image-copy load is read at the version its module.seed.json
  stamp states (ImageModuleSeed, #6044), keyed by the stamp's package; a landed generation
  that loaded wins. A seed can only understate the image's bytes, so this can over-hold,
  never admit. No stamp / substituted / ambiguous loads stay unjudged.
- ImageCopiesOf: the production reader of those stamps.
- Resolve keeps its shape and forwards (distinct name, no CS0419 for dependents).
- Doc: ModuleSyncPerManifestHash rule 1b.

Tests: LoadedPackageModuleReaderTest — the incident through the real decision, with the
old reading as the in-test negative control (Synced); disabling the image pass reds 2 of 10.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@meshweaver-cloud
meshweaver-cloud Bot enabled auto-merge October 6, 2026 06:58
@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results

   11 files   -    11     11 suites   - 11   27m 59s ⏱️ - 15m 36s
6 842 tests  - 3 936  6 842 ✅  - 3 743  0 💤  - 193  0 ❌ ±0 
6 854 runs   - 3 937  6 854 ✅  - 3 744  0 💤  - 193  0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

This pull request removes 4011 and adds 57 tests. Note that renamed tests count towards both.

   --- End of inner exception stack trace ---
   --- End of inner exception stack trace ---, expected: True)
   --- End of inner exception stack trace ---, isDenial: True)
 ---> (Inner Exception #1) MeshWeaver.Messaging.Hub.Test.InfrastructureFaultTest+ProviderException (0x80004005): Failed to connect to 10.42.18.4:5432<---
 ---> (Inner Exception #1) System.InvalidOperationException: boom<---
 ---> (Inner Exception #1) System.InvalidOperationException: source B is misconfigured<---
 ---> (Inner Exception #1) System.Net.Sockets.SocketException (0xFFFDFFFF): Name or service not known<---
 ---> MeshWeaver.Messaging.Hub.Test.InfrastructureFaultTest+ProviderException (0x80004005): Failed to connect to 10.42.18.4:5432
 ---> System.AggregateException: One or more errors occurred. (Failed to connect to 10.42.18.4:5432)
…
Memex.Portal.Shared.Test.InstanceIdRulesMatchTheRegistryTest ‑ TheSetupHostAgreesWithTheRegistry(candidate: "083ef8dd-90ea-46cc-a532-1b55807296d6")
Memex.Portal.Shared.Test.InstanceRebootFaultedRestartTest ‑ ARestartThatCrashed_IsFaulted_RetriedByThePass_AndCompletesOnTheNextAttempt
Memex.Portal.Shared.Test.LoadedPackageModuleReaderTest ‑ ALandedGenerationThatLoaded_WinsOverTheImageReading
Memex.Portal.Shared.Test.LoadedPackageModuleReaderTest ‑ ARequirementTheImagesCopyDoesNotMeet_DeclinesTheImport
Memex.Portal.Shared.Test.LoadedPackageModuleReaderTest ‑ AnImageCopyWithoutAStampOrAnotherLeaf_IsNotJudged
Memex.Portal.Shared.Test.LoadedPackageModuleReaderTest ‑ ImageCopiesOf_ReadsTheStampBesideTheImagesCopy
Memex.Portal.Shared.Test.LoadedPackageModuleReaderTest ‑ TheImageCopyLoaded_ReadsTheSeedsVersion
Memex.Portal.Shared.Test.ModuleReloadFaultedBesideActivationTest ‑ OneModulesCrashedAdopt_BesideAnotherModulesLiveActivation_IsFaulted
Memex.Portal.Shared.Test.ModuleReloadFaultedTest ‑ ADecidedFailure_IsFailed_AndIsNeverRetried
Memex.Portal.Shared.Test.ModuleReloadFaultedTest ‑ ATransientFault_IsFaulted_TheNextPassRetriesIt_AndItSucceeds
…

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 0)

  3 files  ±0    3 suites  ±0   3m 34s ⏱️ +9s
566 tests ±0  375 ✅ ±0  191 💤 ±0  0 ❌ ±0 
570 runs  ±0  379 ✅ ±0  191 💤 ±0  0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 3)

2 481 tests  +5   2 481 ✅ +5   7m 35s ⏱️ +8s
    4 suites ±0       0 💤 ±0 
    4 files   ±0       0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 1)

1 753 tests  ±0   1 751 ✅ ±0   5m 32s ⏱️ -4s
    4 suites ±0       2 💤 ±0 
    4 files   ±0       0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 2)

    5 files  ±0      5 suites  ±0   4m 0s ⏱️ +7s
1 279 tests ±0  1 279 ✅ ±0  0 💤 ±0  0 ❌ ±0 
1 280 runs  ±0  1 280 ✅ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026 •

Copy link
Copy Markdown
Contributor

Test Results (shard 5)

    2 files  ±0      2 suites  ±0   8m 42s ⏱️ +22s
1 108 tests ±0  1 108 ✅ ±0  0 💤 ±0  0 ❌ ±0 
1 109 runs  ±0  1 109 ✅ ±0  0 💤 ±0  0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

♻️ This comment has been updated with latest results.

@github-actions

github-actions Bot commented Oct 6, 2026

Copy link
Copy Markdown
Contributor

Test Results (shard 4)

  1 files   -     3    1 suites   - 3   6m 19s ⏱️ - 8m 33s
510 tests  - 3 086  510 ✅  - 3 086  0 💤 ±0  0 ❌ ±0 
510 runs   - 3 093  510 ✅  - 3 093  0 💤 ±0  0 ❌ ±0 

Results for commit 7249e74. ± Comparison against base commit 8c08fa4.

This pull request removes 3614 and adds 510 tests. Note that renamed tests count towards both.

   --- End of inner exception stack trace ---
   --- End of inner exception stack trace ---, expected: True)
   --- End of inner exception stack trace ---, isDenial: True)
 ---> (Inner Exception #1) MeshWeaver.Messaging.Hub.Test.InfrastructureFaultTest+ProviderException (0x80004005): Failed to connect to 10.42.18.4:5432<---
 ---> (Inner Exception #1) System.InvalidOperationException: boom<---
 ---> (Inner Exception #1) System.InvalidOperationException: source B is misconfigured<---
 ---> (Inner Exception #1) System.Net.Sockets.SocketException (0xFFFDFFFF): Name or service not known<---
 ---> MeshWeaver.Messaging.Hub.Test.InfrastructureFaultTest+ProviderException (0x80004005): Failed to connect to 10.42.18.4:5432
 ---> System.AggregateException: One or more errors occurred. (Failed to connect to 10.42.18.4:5432)
…
MeshWeaver.Hosting.Test.ABakedTypeRegistersWithoutAnInstanceTest ‑ ABakedTypeNobodyActivated_IsRegisteredByThePass_WithoutARecompile
MeshWeaver.Hosting.Test.ABakedTypeRegistersWithoutAnInstanceTest ‑ ATypeWithNoBuild_IsSkipped_NotCompiled
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ AConfirmedAbsentPartition_SkipsTheTypeAndNamesThePartition
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ APartitionNobodyDenied_IsWarmedAsBefore(typePath: "Admin/User", because: "a live partition is warmed")
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ APartitionNobodyDenied_IsWarmedAsBefore(typePath: "Markdown", because: "a type with no partition segment at all is warmed")
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ APartitionNobodyDenied_IsWarmedAsBefore(typePath: "UWDeepfieldExtra/Thing", because: "a partition whose NAME merely starts the same is w"···)
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ AProviderThatKnowsItsStore_ConfirmsAbsence
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ AProviderThatThrowsSynchronously_IsIndeterminate_NotAnEscapingException
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ ASkippedType_DoesNotHoldReadiness
MeshWeaver.Hosting.Test.ADeletedPartitionIsNotPumpedTest ‑ ASkippedType_IsCountedAsContentBroken_NotAsAFault
…

@systemorph-com
systemorph-com Bot enabled auto-merge October 6, 2026 09:29
@rbuergi
rbuergi disabled auto-merge October 6, 2026 12:14
@rbuergi
rbuergi enabled auto-merge October 6, 2026 12:14
@rbuergi
rbuergi merged commit 57842df into main Oct 6, 2026
rbuergi added a commit that referenced this pull request Oct 6, 2026
…t-requires

fix(gitsync): the image's own module copy is judged against an import's requires (Plugins#2715)
@rbuergi
rbuergi deleted the fix/image-copy-judged-against-requires branch October 10, 2026 13:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

thread:pr-systemorph-meshweaver-6190-fbeb35 https://memex.systemorph.com/Hosting/Triage/_Thread/pr-systemorph-meshweaver-6190

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant