Conversation
|
Do not merge please. I will add some tests |
|
Tests added. (hope you are OK with that fact that I add |
|
|
Likely, some version / rules updates. |
|
@maurolacy there is no way to log in in circle without providing Still no changes from |
Don't worry, we'll fix it later. |
You can always try and reproduce the CI setup / tests locally. Take a look a the cicleci config file for reference. |
|
|
webmaster128
left a comment
There was a problem hiding this comment.
Just some code style remarks. Mauro and Ethan know the logic better than I do.
packages/cw0/Cargo.toml
Outdated
| thiserror = { version = "1.0.21" } | ||
|
|
||
| [dev-dependencies] | ||
| cw-storage-plus = { version = "0.6.1", features = ["iterator"] } |
There was a problem hiding this comment.
Can you use a local dependency, e.g.
| cw-storage-plus = { version = "0.6.1", features = ["iterator"] } | |
| cw-storage-plus = { path = "../../packages/storage-plus", version = "0.6.2", features = ["iterator"] } |
packages/cw0/src/pagination.rs
Outdated
| } | ||
| pub fn calc_range_start(start_after: Option<Addr>) -> Option<Vec<u8>> { | ||
| start_after.map(|addr| { | ||
| let mut v: Vec<u8> = addr.as_ref().into(); |
There was a problem hiding this comment.
There is now .as_bytes() which is a bit more explicit and does the same
| let mut v: Vec<u8> = addr.as_ref().into(); | |
| let mut v: Vec<u8> = addr.as_bytes().into(); |
packages/cw0/src/pagination.rs
Outdated
| None => Ok(None), | ||
| } | ||
| pub fn calc_range_end(end_before: Option<Addr>) -> Option<Vec<u8>> { | ||
| end_before.map(|addr| addr.as_ref().into()) |
There was a problem hiding this comment.
| end_before.map(|addr| addr.as_ref().into()) | |
| end_before.map(|addr| addr.as_bytes().into()) |
| } | ||
| None => Ok(None), | ||
| } | ||
| pub fn calc_range_start(start_after: Option<Addr>) -> Option<Vec<u8>> { |
There was a problem hiding this comment.
Can only do proper / full reviews beginning next week.
Perhaps the original functions must be kept, as they can be useful for old-style ranges / storage. These new ones can also be suffixed by _addr for clarity, but given that this is the new standard, I don't think that's really necessary.
There was a problem hiding this comment.
I see now that the original argument is Addr already so, it's OK to remove / rename these functions.
Fix dependency section. |
The version of cosmwasm-std is not up to date anymore. Your branch has 0.14. Could you update this PR to the latest main state? |
Signed-off-by: Stanislav Pirx <stanislav.pirx@gmail.com>
Signed-off-by: Stanislav Pirx <stanislav.pirx@gmail.com>
Signed-off-by: Stanislav Pirx <stanislav.pirx@gmail.com>
Signed-off-by: Stanislav Pirx <stanislav.pirx@gmail.com>
Signed-off-by: Stanislav Pirx <stanislav.pirx@gmail.com>
b833b61 to
0509cc7
Compare
Done, rebase it to |
|
Merging |
No description provided.