Skip to content

Bulk market scripts call create-market with a missing category argument #60

@Mosas2000

Description

@Mosas2000

Several mainnet utility scripts still call market-core.create-market with only three arguments, but the contract now requires question, end-date, resolution-date, and category.

Affected scripts:

  • scripts/bulk-create-markets.ts
  • scripts/market-lifecycle.ts
  • scripts/stress-test.ts
  • scripts/interact-contract.ts

Evidence:

  • contracts/market-core.clar defines create-market as (question, end-date, resolution-date, category).
  • Each of the scripts above still passes only three arguments.

Impact:

  • The transaction call will fail at broadcast time or contract execution time.
  • Bulk market creation and lifecycle/stress scripts cannot create markets successfully against the current contract ABI.

Reproduction:

  1. Run one of the scripts that creates a market, e.g. npm run bulk-markets or npm run interact.
  2. Inspect the constructed contract call.
  3. The call omits the required category Clarity argument.

Priority: High

Suggested scope:
Update every create-market caller to include the category value expected by the contract, and add coverage so this does not regress.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions