Skip to content

GitLab

    • GitLab: the DevOps platform
    • Explore GitLab
    • Install GitLab
    • How GitLab compares
    • Get started
    • GitLab docs
    • GitLab Learn
  • Pricing
  • Talk to an expert
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
    • Switch to GitLab Next
    • Menu
    Projects Groups Snippets
  • Sign up now
  • Login
  • Sign in / Register
  • Bitcoin Cash Node Bitcoin Cash Node
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 163
    • Issues 163
    • List
    • Boards
    • Service Desk
    • Milestones
    • Iterations
    • Requirements
  • Merge requests 65
    • Merge requests 65
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
    • Test Cases
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages & Registries
    • Packages & Registries
    • Package Registry
    • Container Registry
    • Infrastructure Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Code review
    • Insights
    • Issue
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Bitcoin Cash Node
  • Bitcoin Cash NodeBitcoin Cash Node
  • Merge requests
  • !1115

Tachyon: Allow multiple OP_RETURN outputs in a transaction

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged BigBlockIfTrue requested to merge BigBlockIfTrue/bitcoin-cash-node:v23/multi-op-return into master Mar 14, 2021
  • Overview 5
  • Commits 1
  • Pipelines 3
  • Changes 8

After the Tachyon upgrade, a standard transaction can now use any number of data carrier outputs, as long as the total script size of these outputs does not exceed the pre-existing limit of 223 bytes. The number 223 remains user-configurable (-datacarriersize=<n>).

Cumulative size of OP_RETURN outputs is counted in a CScript::size_type (currently uint32_t) and checked only once at the end (for optimal performance for standard transactions). Because of the consensus and standardness transaction size limits, there is no risk of overflow. The new per-transaction size check makes the old per-output size check redundant, also before the upgrade, and hence the latter has been removed.

Specification effort: https://bitcoincashresearch.org/t/multiple-op-returns-this-time-for-real/315

Includes tests:

  • Unit test for both pre-upgrade and post-upgrade standardness logic.
  • Functional test for activation, based on the OP_RETURN limit increase in the Monolith (May 2018) upgrade (removed in commit 9e563fa4).

After the upgrade activates, the pre-upgrade logic and the functional test can be removed.

Test plan: ninja check check-functional

Assignee
Assign to
Reviewer
Request review from
Time tracking
Source branch: v23/multi-op-return