Skip to content

Remove ambiguous 'environment' metadata attribute#143

Merged
Unisay merged 1 commit intomainfrom
yura/issue-142-remove-environment-metadata
Nov 7, 2025
Merged

Remove ambiguous 'environment' metadata attribute#143
Unisay merged 1 commit intomainfrom
yura/issue-142-remove-environment-metadata

Conversation

@Unisay
Copy link
Collaborator

@Unisay Unisay commented Nov 7, 2025

Summary

Removes the environment field from submission metadata as it has proven to be ambiguous and not useful to authors.

Problem

The environment metadata attribute suffered from several issues:

  • Low adoption: Only 28.6% of submissions used it (6 of 21)
  • Inconsistent semantics: Different compilers interpreted it differently:
    • Plinth: Documented compiler toolchain dependencies (plutus-tx, plutus-core, plutus-ledger-api)
    • OpShin: Documented runtime dependency (uplc library)
    • Aiken: Present but empty ("dependencies": {})
    • Plutarch/Scalus: Field entirely omitted
  • Not used by tooling: No Haskell code or bash scripts read or process this field - validation was purely schema-based
  • Ambiguous purpose: Unclear whether it should track compiler dependencies, runtime dependencies, or package lockfile versions

Changes

Schema Changes (2 files)

  • submissions/TEMPLATE/metadata.schema.json - Removed environment property definition
  • submissions/TEMPLATE/schemas-README.md - Removed environment documentation

Submission Data (9 files)

Removed environment object from:

  • 4 Plinth submissions (fibonacci_naive_recursion, factorial_naive_recursion, ecd, two_party_escrow)
  • 2 OpShin submissions (factorial_naive_recursion, fibonacci)
  • 3 Aiken submissions (fibonacci_naive_recursion, fibonacci tailrec/prepacked)

Documentation (3 files)

  • README.md - Removed environment from metadata example and reproducibility notes
  • doc/submission-guide.md - Removed environment from metadata example
  • doc/domain-model.md - Removed environment references from domain model

Impact

  • Zero breaking changes: Field was optional and not processed by any code
  • Simpler schema: Reduces confusion for submission authors
  • Can be re-introduced later: If a clear use case emerges with proper semantics

Validation

  • ✅ All 9 modified submissions verified with cape submission verify
  • ✅ All 222 tests passing with cabal test
  • ✅ All files formatted with treefmt

Fixes #142

Removed the 'environment' field from submission metadata due to:
- Low adoption (28.6% of submissions)
- Inconsistent semantics across compilers
- Not used by any tooling or validation logic
- Ambiguous purpose (compiler deps vs runtime deps)

Changes:
- Schema: Removed environment property from metadata.schema.json
- Documentation: Updated README, submission-guide, domain-model
- Submissions: Removed environment from 9 existing submissions
  - 4 Plinth submissions (plutus-tx/core/ledger-api dependencies)
  - 2 OpShin submissions (uplc library dependency)
  - 3 Aiken submissions (empty dependencies)
- All submissions verified and tests passing

The field was optional and can be re-introduced later if a clear
use case emerges with proper semantics.

Fixes #142
@github-actions
Copy link
Contributor

github-actions bot commented Nov 7, 2025

🚀 PR Preview Deployed

Preview URL: https://intersectmbo.github.io/UPLC-CAPE/pr-143/

The preview site is automatically updated on every push to this PR and will be removed when the PR is closed.

@Unisay Unisay self-assigned this Nov 7, 2025
@Unisay Unisay merged commit 23a45db into main Nov 7, 2025
3 checks passed
@Unisay Unisay deleted the yura/issue-142-remove-environment-metadata branch November 7, 2025 14:00
github-actions bot added a commit that referenced this pull request Nov 7, 2025
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.

Remove ambiguous 'environment' metadata attribute

1 participant