Skip to content

Conversation

@L3pereira
Copy link
Contributor

@L3pereira L3pereira commented Jun 2, 2022

Merge after #3821

When creating a video, the sender gets slashed video state bloat bond
When deleting a channel sender gets paid the video state bloat bond amount
Uses the funds_needed_for_upload implemented here #3693 to verify the funds needed before charging the video state bloat bond

┆Issue is synchronized with this Asana task by Unito

@vercel
Copy link

vercel bot commented Jun 2, 2022

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Updated
pioneer-testnet ⬜️ Ignored (Inspect) Jul 1, 2022 at 11:16AM (UTC)

@L3pereira L3pereira changed the title Introduce video state bloat bond #3394 Introduce video state bloat bond Jun 2, 2022
@L3pereira L3pereira self-assigned this Jun 2, 2022
@L3pereira L3pereira requested a review from dobertRowneySr June 2, 2022 17:43
// == MUTATION SAFE ==
//

let _ = Balances::<T>::slash(&sender, video_state_bloat_bond);
Copy link
Member

Choose a reason for hiding this comment

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

Do we not put the bloat bond in some treasury account or something? What did we do for bounty pallet bloat bonds, or for storage?

Copy link
Collaborator

@dobertRowneySr dobertRowneySr left a comment

Choose a reason for hiding this comment

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

Same cosmetics as the channel bloat bond PR, otherwise LGTM

increase_account_balance_helper(DEFAULT_MEMBER_ACCOUNT_ID, 11);
create_default_member_owned_channel();

let video_state_bloat_bond = 1;
Copy link
Collaborator

Choose a reason for hiding this comment

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

why not use their DEFAULT-* counterparts?

@L3pereira L3pereira requested a review from dobertRowneySr June 17, 2022 12:14
Copy link
Collaborator

@dobertRowneySr dobertRowneySr left a comment

Choose a reason for hiding this comment

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

LGTM

@bedeho bedeho requested a review from Lezek123 June 20, 2022 08:47
@bedeho bedeho added carthage and removed audit-3 labels Jun 20, 2022
@bedeho bedeho changed the base branch from audit3 to carthage June 22, 2022 09:55
@L3pereira L3pereira requested a review from bedeho June 24, 2022 15:01
@bedeho bedeho removed their request for review June 25, 2022 07:48
@L3pereira L3pereira force-pushed the introduce_video_state_bloat_bond_#3394 branch from 054225d to 0e07683 Compare June 30, 2022 08:00
@L3pereira L3pereira requested a review from dobertRowneySr June 30, 2022 08:16
Copy link
Collaborator

@dobertRowneySr dobertRowneySr left a comment

Choose a reason for hiding this comment

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

  • build node & runtime ✔️
  • types and metadata ✔️
  • cargo test ✔️
  • there are some problem with benchmarks:
---- tests::council_discard_remaining_rewards_on_depose stdout ----
thread 'tests::council_discard_remaining_rewards_on_depose' panicked at 'attempt to subtract with overflow', runtime-modules/council/src/mock.rs:1496:17
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

---- tests::council_many_cycle_rewards stdout ----
thread 'tests::council_many_cycle_rewards' panicked at 'attempt to subtract with overflow', runtime-modules/council/src/mock.rs:1496:17

---- tests::council_rewards_are_paid stdout ----
thread 'tests::council_rewards_are_paid' panicked at 'attempt to subtract with overflow', runtime-modules/council/src/mock.rs:1496:17

---- tests::vote_stake_locks_after_new_election_starts stdout ----
thread 'tests::vote_stake_locks_after_new_election_starts' panicked at 'attempt to subtract with overflow', runtime-modules/council/src/mock.rs:1496:17

These should be fixed see mnaamani#13

@L3pereira L3pereira force-pushed the introduce_video_state_bloat_bond_#3394 branch from 0e07683 to 7e8982d Compare July 1, 2022 09:20
types generation

types generation and channel duplication fix
@L3pereira L3pereira force-pushed the introduce_video_state_bloat_bond_#3394 branch from 7e8982d to 375f94f Compare July 1, 2022 11:16
@dobertRowneySr dobertRowneySr merged commit cf18a6c into Joystream:carthage Jul 1, 2022
@L3pereira L3pereira deleted the introduce_video_state_bloat_bond_#3394 branch July 29, 2022 13:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants