Skip to content

fix: remove entity type overlaps causing causality region conflicts#164

Merged
hudsonhrh merged 1 commit intomainfrom
hudsonhrh/washington-v5
Apr 16, 2026
Merged

fix: remove entity type overlaps causing causality region conflicts#164
hudsonhrh merged 1 commit intomainfrom
hudsonhrh/washington-v5

Conversation

@hudsonhrh
Copy link
Copy Markdown
Member

Summary

  • Four file/ipfs data source templates declared entity types (Task, Project, Proposal, DDVProposal, EducationModule) they never write to — but that ARE written by onchain ethereum event handlers in the same block
  • In specVersion 1.2.0, file data sources run in a separate offchain causality region. When their entities list overlaps with onchain handler entity types, the store detects causality region conflicts during block transaction commit
  • This caused non-deterministic "WASM runtime thread terminated" / "Failed to transact block operations" crashes — the failure point shifted each retry because IPFS fetch order varies
  • Fix: restrict each file data source's entities list to only the metadata entity type the handler actually writes to

Why previous fixes didn't work

Test plan

  • npm run codegen passes
  • npm run build passes
  • All 241 tests pass
  • subgraph-lint passes (0 errors)
  • Redeploy and verify indexing past the previously failing block

🤖 Generated with Claude Code

File data source templates (ProposalMetadata, TaskMetadata, ProjectMetadata,
EducationModuleMetadata) declared entity types they never write to (Proposal,
DDVProposal, Task, Project, EducationModule). These same entity types ARE
written by ethereum event handlers in the same block.

In specVersion 1.2.0, file data sources run in an offchain causality region.
When their entities list overlaps with onchain handler entity types, the store
detects causality region conflicts during block transaction commit — causing
non-deterministic "WASM runtime thread terminated" crashes that shift based
on IPFS fetch order.

Fix: restrict each file data source's entities list to only the metadata
entity type the handler actually writes to.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@hudsonhrh hudsonhrh merged commit f69d144 into main Apr 16, 2026
6 checks passed
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