BL-25: cache_model_0/abis/ task-contract artifacts are stale vs. foundry/src (missing 67/96 ABI entries)

Open
#246 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

@robertocarlous is already working on this.

Since Oct 16, 2026.

  • #261 by @robertocarlous — open

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
42/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python, solidity

Research direction

Read cache_model_0/manifest.json, foundry/foundry.toml, and dincli/cli/context.py to understand artifact metadata and CID resolution; then build the contracts with forge build in foundry. Regenerate the coordinator and auditor artifacts from foundry/out, update their manifest type and compilation details, and re-pin both files to IPFS with the resulting CIDs. Done when both ABIs contain the entries from foundry/src and the manifest resolves the regenerated artifacts.

Written by the indexing model from the issue text.

Description

Approved bug

Summary

cache_model_0/abis/DINTaskCoordinator.json and DINTaskAuditor.json are hardhat artifacts last regenerated 2026-06-09. They are missing 67 ABI entries for the coordinator (104 vs. 170 in foundry/src) and 96 entries for the auditor (68 vs. 158), and carry pre-foundry constructors.

PR #171 regenerated the six bundled dincli/abis/ files from foundry/out but explicitly left these alone because cache_model_0/manifest.json's task_contracts block:

  • pins each artifact to an IPFS CID
  • records "type": "hardhat-artifact" and a hardhat/cancun/optimizer-off compilation block
  • carries the currently deployed contract addresses

Regenerating the files locally without updating the manifest would leave the manifest describing artifacts it no longer points to and dincli's CID-based resolution would still fetch the old files from IPFS.

Impact

Any model owner or tool that follows cache_model_0 as a reference and resolves task-contract ABIs through the manifest will hit ABI encoding mismatches on the ~67 / ~96 entries added since the last hardhat regeneration — covering all reward settlement, commit-reveal, seed-lock, encrypted-test-data, and dispute-resolution surfaces added in P3.

Fix (one pass)

  1. Regenerate both ABI files from foundry/out with full bytecode:
    cd foundry && forge build
    # extract from foundry/out/DINTaskCoordinator.sol/DINTaskCoordinator.json
    # extract from foundry/out/DINTaskAuditor.sol/DINTaskAuditor.json
    
    or via a new dincli system dump-abi --bytecode --output cache_model_0/abis if that subcommand lands first.
  2. Update cache_model_0/manifest.json:
    • Change "type" from "hardhat-artifact" to "foundry-artifact".
    • Update the compilation block to reflect foundry / solc 0.8.28 / via-IR / optimizer-off (matching foundry/foundry.toml).
    • Re-pin both files to IPFS and update their CIDs.
  3. Addresses only change on a contract redeploy — no address update needed unless a redeploy happens concurrently.

References

  • Developer/BACK_LOG.md BL-25
  • PR #171 merge note — cache_model_0/abis/ explicitly left out of scope
  • cache_model_0/manifest.json task_contracts block
  • dincli/cli/context.py _resolve_task_artifacts — CID-based ABI resolution path
Dominant language
Python
Stars
4
Forks
7
Avg merge
3d 7h
Merged PRs (30d)
33

Getting set up

This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from InfiniteZeroFoundation/DevNet

All issues in InfiniteZeroFoundation/DevNet

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.