Skip to content

moving_price in DynamicInfo returns incorrect values (wrong fractional bits) #3009

@mcjkula

Description

@mcjkula

Describe the bug

The moving_price field in DynamicInfo returns values that are smaller than the actual on-chain values. This is caused by using incorrect fractional bits parameter during I96F32 fixed-point decoding.

To Reproduce

import bittensor as bt

subtensor = bt.Subtensor()
subnet_info = subtensor.subnet(netuid=56)
print(subnet_info.moving_price)

Expected behavior

Expected: ~0.05, Actual: ~0.00000000001

Screenshots

No response

Environment

MacOS 15.0, bittensor==9.8.3

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions