Skip to content

Commit 3182f67

Browse files
authored
Upgraded dependencies (#275)
2 parents f11f3e9 + 5210966 commit 3182f67

File tree

9 files changed

+524
-357
lines changed

9 files changed

+524
-357
lines changed

docs-test-gen/Cargo.lock

Lines changed: 501 additions & 308 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs-test-gen/Cargo.toml

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -12,21 +12,22 @@ phf = { version = "0.11.2", features = ["macros"] }
1212
strum = { version = "0.26.3", features = ["derive"] }
1313

1414
[dev-dependencies]
15-
sylvia = { version = "*", features = ["cosmwasm_2_0"] }
16-
cw2 = "*"
17-
cw-storage-plus = { version = "*", features = ["macro"] }
18-
cw-utils = "*"
19-
cosmwasm-schema = "*"
20-
cosmwasm-std = { version = "*", features = [
15+
sylvia = { version = "2.0.0-rc.1", features = ["cosmwasm_3_0"] }
16+
cw2 = "3.0.0-rc.0"
17+
cw-storage-plus = { version = "3.0.0-rc.2", features = ["macro"] }
18+
cw-utils = "3.0.0-rc.0"
19+
cosmwasm-schema = "3.0.0-rc.0"
20+
cosmwasm-std = { version = "3.0.0-rc.0", features = [
2121
"stargate",
2222
"staking",
23-
"cosmwasm_2_2",
23+
"cosmwasm_3_0",
24+
"ibc2"
2425
] }
2526
sha2 = "0.10.8"
2627
cosmos-sdk-proto = { version = "0.24.0", default-features = false } # Used in IBC code
2728
ibc = "0.54.0" # Used in IBC code
2829
serde = "*"
2930
schemars = "0.8.21" # Used in entrypoint example
3031
thiserror = "1.0.65"
31-
cw-storey = "*"
32-
storey = "*"
32+
cw-storey = "0.7.0-rc.0"
33+
storey = "0.5.0"

src/pages/sylvia/basics/interoperability.mdx

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,6 @@ pub struct ReplyContract;
8989

9090
#[entry_points]
9191
#[contract]
92-
#[sv::features(replies)]
9392
impl ReplyContract {
9493
pub fn new() -> Self {
9594
Self
@@ -141,7 +140,6 @@ pub struct ReplyContract {
141140

142141
#[entry_points]
143142
#[contract]
144-
#[sv::features(replies)]
145143
impl ReplyContract {
146144
pub fn new() -> Self {
147145
Self {

src/pages/sylvia/macros/attributes/data.mdx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,19 +2,12 @@
22
tags: ["sylvia", "attributes"]
33
---
44

5-
import { Callout } from "nextra/components";
6-
75
# sv::data attribute
86

97
Use `sv::data` to specify if the
108
[`SubMsgResponse::data`](https://docs.rs/cosmwasm-std/latest/cosmwasm_std/struct.SubMsgResponse.html)
119
field should be deserialized or not.
1210

13-
<Callout>
14-
To use `sv::data` attribute pre Sylvia `2.0.0`, you need to enable the `replies` feature using the
15-
[`sv::features`](features).
16-
</Callout>
17-
1811
## Macros
1912

2013
List of macros supporting the `sv::data` attribute:
@@ -29,7 +22,6 @@ pub struct Contract;
2922

3023
#[cfg_attr(feature = "library", sylvia::entry_points)]
3124
#[contract]
32-
#[sv::features(replies)]
3325
impl Contract {
3426
pub const fn new() -> Self {
3527
Self

src/pages/sylvia/macros/attributes/features.mdx

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ pub struct Contract;
2323

2424
#[cfg_attr(feature = "library", sylvia::entry_points)]
2525
#[contract]
26-
#[sv::features(replies)]
2726
impl Contract {
2827
pub const fn new() -> Self {
2928
Self
@@ -46,10 +45,7 @@ impl Contract {
4645
}
4746
```
4847

49-
Parameters supported by the `sv::features`:
50-
51-
- replies - enables better reply handling. This includes:
52-
- Auto dispatching of replies to the correct handler,
53-
- Deserialization of the `data` and `payload` fields,
54-
- Reply id generation.
55-
- [`SubMsg`](https://docs.rs/cosmwasm-std/latest/cosmwasm_std/struct.SubMsg.html) builder trait
48+
<Callout>
49+
As of **Sylvia 2.0.0**, all features are stabilized, and currently there are no supported
50+
`sv::features` parameters.
51+
</Callout>

src/pages/sylvia/macros/attributes/msg.mdx

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ impl CounterContract {
6262
}
6363

6464
#[sv::msg(reply)]
65-
fn some_reply(&self, ctx: ReplyCtx, reply: Reply) -> StdResult<Response> {
65+
fn some_reply(&self, ctx: ReplyCtx, result: SubMsgResult, #[sv::payload(raw)] payload: Binary) -> StdResult<Response> {
6666
Ok(Response::new())
6767
}
6868
}
@@ -92,11 +92,6 @@ fn some_query(&self, ctx: QueryCtx) -> SomeResult {
9292

9393
## Handling replies
9494

95-
<Callout>
96-
To use attributes present in this paragraph pre-Sylvia `2.0.0`, you need to enable the `replies`
97-
feature using the [`sv::features`](features) attribute.
98-
</Callout>
99-
10095
You can use additional parameters `handlers` and `reply_on` in the `#[sv::msg(reply)]` attribute.
10196

10297
```rust {1} template="sylvia-cw-storage-contract"

src/pages/sylvia/macros/attributes/payload.mdx

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22
tags: ["sylvia", "attributes"]
33
---
44

5-
import { Callout } from "nextra/components";
6-
75
# sv::payload attribute
86

97
Use `sv::payload` to specify if the
@@ -12,11 +10,6 @@ forwarded as `Binary`. Exactly _ONE_ reply method parameter can be marked with t
1210
attribute. If missing, Sylvia will deserialize the `payload` to types defined after the `sv::data`
1311
parameter.
1412

15-
<Callout>
16-
To use `sv::payload` attribute pre Sylvia `2.0.0`, you need to enable the `replies` feature using
17-
the [`sv::features`](features).
18-
</Callout>
19-
2013
## Macros
2114

2215
List of macros supporting the `sv::data` attribute:
@@ -37,7 +30,6 @@ pub struct Contract;
3730

3831
#[cfg_attr(feature = "library", sylvia::entry_points)]
3932
#[contract]
40-
#[sv::features(replies)]
4133
impl Contract {
4234
pub const fn new() -> Self {
4335
Self

src/pages/sylvia/macros/contract.mdx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ impl Contract {
7070
}
7171

7272
#[sv::msg(reply)]
73-
fn some_reply(&self, ctx: ReplyCtx, reply: Reply) -> StdResult<Response> {
73+
fn some_reply(&self, ctx: ReplyCtx, result: SubMsgResult, #[sv::payload(raw)] payload: Binary) -> StdResult<Response> {
7474
Ok(Response::new())
7575
}
7676
}

src/pages/sylvia/types/context.mdx

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,12 @@ types received in the contract entrypoints.
1212

1313
Those types are:
1414

15-
- [`InstantiateCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.InstantiateCtx.html)
16-
- [`ExecCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.ExecCtx.html)
17-
- [`QueryCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.QueryCtx.html)
18-
- [`MigrateCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.MigrateCtx.html)
19-
- [`ReplyCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.ReplyCtx.html)
20-
- [`SudoCtx`](https://docs.rs/sylvia/latest/sylvia/types/struct.SudoCtx.html)
15+
- [`InstantiateCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.InstantiateCtx.html)
16+
- [`ExecCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.ExecCtx.html)
17+
- [`QueryCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.QueryCtx.html)
18+
- [`MigrateCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.MigrateCtx.html)
19+
- [`ReplyCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.ReplyCtx.html)
20+
- [`SudoCtx`](https://docs.rs/sylvia/latest/sylvia/ctx/struct.SudoCtx.html)
2121

2222
<Callout>Use the above context types in contract message methods.</Callout>
2323

@@ -26,7 +26,7 @@ Those types are:
2626
Example instantiate method:
2727

2828
```rust
29-
use sylvia::types::InstantiateCtx;
29+
use sylvia::ctx::InstantiateCtx;
3030

3131
#[sv::msg(instantiate)]
3232
fn instantiate(&self, ctx: InstantiateCtx, mutable: bool) -> StdResult<Response> {

0 commit comments

Comments
 (0)