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

refactor(minor-rewards): msg and state separation #761

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

fish-sammy
Copy link
Collaborator

Description

Todos

  • Unit tests
  • Manual tests
  • Documentation
  • Connect epics/issues

Convention Checklist

  • Each contract should have a client mod for others to interact with it.
  • Derive macros
  • The state mod and msg mod should use separate data structures so that internal state changes do not break the contract interface. Check out the interchain-token-service for reference.
    • msg.rs should never use any type from the state.rs
    • Shared types must be defined in a separate exported mod. If those types have already been defined somewhere else, then they should get re-exported in the exported mod

Steps to Test

Expected Behaviour

Notes

@fish-sammy fish-sammy requested a review from a team as a code owner February 12, 2025 18:08
Copy link

codecov bot commented Feb 12, 2025

Codecov Report

Attention: Patch coverage is 89.02439% with 9 lines in your changes missing coverage. Please review.

Project coverage is 93.47%. Comparing base (fed53af) to head (5681ca2).

Files with missing lines Patch % Lines
contracts/rewards/src/contract.rs 75.67% 9 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #761      +/-   ##
==========================================
- Coverage   93.50%   93.47%   -0.03%     
==========================================
  Files         233      233              
  Lines       38893    38948      +55     
==========================================
+ Hits        36366    36407      +41     
- Misses       2527     2541      +14     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@@ -160,11 +160,11 @@ pub fn create_pool(

pub fn update_pool_params(
storage: &mut dyn Storage,
pool_id: &PoolId,
pool_id: PoolId,
Copy link
Contributor

Choose a reason for hiding this comment

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

I don't understand this change. Why own the PoolId if you only need it for references?

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