Skip to content

qbond update#914

Open
baoLuck wants to merge 2 commits into
qubic:developfrom
baoLuck:feature/2026-06-06-qbond-update
Open

qbond update#914
baoLuck wants to merge 2 commits into
qubic:developfrom
baoLuck:feature/2026-06-06-qbond-update

Conversation

@baoLuck

@baoLuck baoLuck commented Jun 8, 2026

Copy link
Copy Markdown
Contributor

Proposal

Contract file update instructions will be added 09.06.2026

Comment thread src/contracts/QBond.h
{
locals.tempOrder = state.get()._bidOrders.element(locals.elementIndex);
qpi.transfer(locals.tempOrder.owner, locals.tempOrder.numberOfMBonds * state.get()._bidOrders.priority(locals.elementIndex));
qpi.transfer(locals.tempOrder.owner, locals.tempOrder.numberOfMBonds * state.get()._bidOrders.priority(locals.elementIndex) - QBOND_PROCEDURE_FEE);

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you need to check >= QBOND_PROCEDURE_FEE like other places, otherwise negative value prevent the transfer and the burn still happen.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

conditions in AddBidOrder (L679-L680) and RemoveBidOrder (L881-L885) ensure that numberOfMbonds * mbondPrice is always greater than or equal to QBOND_PROCEDURE_FEE, so this check is unnecessary here

Comment thread src/contracts/QBond.h Outdated

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[non-blocking] Just double check, it is a little bit wierd to me, is it locals.tempMbondInfo.totalStaked + input.quMillions > QBOND_STAKE_LIMIT_PER_EPOCH ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, thanks

@cyber-pc cyber-pc left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, you need to update the migration tool.

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.

2 participants