Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

On Simnet, in at-block, burn-block-height returns the highest latest value, not the value on that block #1615

Open
0xc22b opened this issue Nov 25, 2024 · 0 comments
Assignees

Comments

@0xc22b
Copy link

0xc22b commented Nov 25, 2024

Describe the bug
On Simnet, in at-block, burn-block-height returns the highest latest value, not the value on that block

To Reproduce
Steps to reproduce the behavior:

  1. Run clarinet console with a smart contract below.
(define-read-only (get-burn (height uint))
    (let
        (
            (id (unwrap! (get-stacks-block-info? id-header-hash height) err-invalid-args))
        )
        (at-block id
            (ok { burn-block-height: burn-block-height, stacks-block-height: stacks-block-height })
        )
    )
)
  1. Run ::advance_burn_chain_tip 1 repeatedly
  2. Call the smart contract with different heights
(contract-call? .contract get-burn u3)

Expected behavior
burn-block-height should return the height for that at-block

Screenshots
Image

Environment (please complete the following information):

  • OS (version): macOS (14.7)
  • Clarinet version 2.11.2
@github-project-automation github-project-automation bot moved this to 🆕 New in DevTools Nov 25, 2024
@hugocaillard hugocaillard self-assigned this Nov 25, 2024
@hugocaillard hugocaillard moved this from 🆕 New to 🏗 In Progress in DevTools Nov 25, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 🏗 In Progress
Development

No branches or pull requests

2 participants