Skip to content

Commit 792639c

Browse files
bitzoicSwayStar123IGI-111sdankelK1-R1
authored
Release v0.6.1 (#150)
* Hotfix: Update Cargo.toml to v0.5.1 (#115) * Hotfix: Update Cargo.toml to v0.5.1 * Udpate CHANGELOG * fix vault reads * add changelog * move changelog to new empty changelog * add "unreleased" to changelog heads * remove date * add v0.5.1 * SRC-6 example contract does not update managed assets (#122) * Update SRC-6 example with decrementation of managed assets * Update CHANGELOG * Fix link on CHANGELOG.md * Update CHANGELOG to resolve markdown error with duplicate headers * Write to storage * Use new namespace syntax for storage (#120) * chore: fix compiler warnings * remove for examples * Update changelog * Prepare master for v0.5.2 release (#126) * Prepare for v0.5.2 release * Update CHANGELOG * Update CHANGELOG formatting * Make the `SubId` an `Option` in SRC-3's `mint()` function (#131) * Update specifications to change SRC-3 mint sub_id to an Option * Update SRC-3 standard for option in mint * Update examples * Udpate CHANGELOG * Run formatter * Fix spelling * Add event logging to SRC-20 and SRC-7 standards (#130) * Add event logging to SRC-20 and SRC-7 specification * Add event logging structs to SRC-20 and SRC-7 * Update CHANGELOG * Add inline docs to SRC-20 events * Fix CI * Require that logs of metadata are emitted even with contants * Update standards with additional log and ordering * Update examples to follow new specs * Add custom word to spell checker * Run formatter * Fix markdown formatting * Resolve warnings in examples * Build CI with release * Store srv7 metadata to storage * Remove cancel in progress from CI * Update name for TotalSupplyEvent * Split examples into seperate workspace projects * Prepare for v0.6.0 release * Update CHANGELOG * Resolve warnings in examples (#137) * Resolve warnings * Update CHANGELOG * Run formatter * Remove cancel in progress from CI * Revert remove cancel in progress from CI * fix max_depositable and max_withdrawable examples --------- Co-authored-by: SwayStar123 <[email protected]> * chore: update to forc 0.63.3 (#135) * chore: update to forc 0.63.1 * chore: updated changelog * Update to forc v0.63.3 --------- Co-authored-by: bitzoic <[email protected]> * docs: update src14 storage recommendation and general typos (#136) * chore: update to forc 0.63.1 * chore: updated changelog * docs: update src14 and general typos * Apply PR review comments * Fix markdown * Update CHANGELOG * Improve CHANGELOG comment --------- Co-authored-by: bitzoic <[email protected]> * Add helper functions to SRC7 standard's `Metadata` (#144) * Add helper functions to SRC7 standard * Update CHANGELOG * Remove metadata functions (#148) * Fix Sway Standards inline docs (#142) * Update sway standards inline docs * Update CHANGELOG * Fix typo * Prepare for Sway-Standards `v0.6.1` release (#147) * Prepare for Sway-Standards v0.6.1 release * Update CHANGELOG * Add helper functions to struct types and `Eq` implementations for all types (#149) * Add helper functions to struct types and Eq implementations * Add checks to enum types * Update CHANGELOG --------- Co-authored-by: SwayStar123 <[email protected]> Co-authored-by: SwayStar123 <[email protected]> Co-authored-by: IGI-111 <[email protected]> Co-authored-by: Sophie <[email protected]> Co-authored-by: K1-R1 <[email protected]>
1 parent 65e09f9 commit 792639c

File tree

36 files changed

+2825
-386
lines changed

36 files changed

+2825
-386
lines changed

.github/workflows/ci.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,9 @@ concurrency:
1515
env:
1616
CARGO_TERM_COLOR: always
1717
REGISTRY: ghcr.io
18-
RUST_VERSION: 1.77.0
19-
FORC_VERSION: 0.61.0
20-
CORE_VERSION: 0.26.0
18+
RUST_VERSION: 1.80.1
19+
FORC_VERSION: 0.63.3
20+
CORE_VERSION: 0.34.0
2121
PATH_TO_SCRIPTS: .github/scripts
2222

2323
jobs:

CHANGELOG.md

Lines changed: 26 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,26 +9,48 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
99

1010
Description of the upcoming release here.
1111

12-
### Added Unreleased
12+
### Added
1313

1414
- Something new here 1
1515
- Something new here 2
1616

17-
### Changed Unreleased
17+
### Changed
1818

1919
- Something changed here 1
2020
- Something changed here 2
2121

22-
### Fixed Unreleased
22+
### Fixed
2323

2424
- Some fix here 1
2525
- Some fix here 2
2626

27-
#### Breaking Unreleased
27+
#### Breaking
2828

2929
- Some breaking change here 1
3030
- Some breaking change here 2
3131

32+
## [Version 0.6.1]
33+
34+
Description of the upcoming release here.
35+
36+
### Added v0.6.1
37+
38+
- [#149](https://github.com/FuelLabs/sway-standards/pull/149) Adds struct field getters, `new()`, and `Eq` implementations to SRC-10's `DepositMessage` and `MetadataMessage` types and SRC-11's `SecurityInformation` type.
39+
- [#149](https://github.com/FuelLabs/sway-standards/pull/149) Adds `Eq` implementation to SRC-5's `AccessError` error.
40+
- [#149](https://github.com/FuelLabs/sway-standards/pull/149) Adds check functions and `Eq` implementation to SRC-5's `State` type and SRC-10's `DepositType` type.
41+
- [#149](https://github.com/FuelLabs/sway-standards/pull/149) Adds struct field getters, `new()`, `log()`, and `Eq` implementations to SRC-6's `Deposit`, and `Withdraw` types, SRC-20's `SetNameEvent`, `SetSymbolEvent`, `SetDecimalsEvent`, and `TotalSupplyEvent` events, and SRC-7's `SetMetadataEvent` event.
42+
43+
### Changed v0.6.1
44+
45+
- [#135](https://github.com/FuelLabs/sway-standards/pull/135) Updates standards, examples and CI to latest forc 0.63.3.
46+
- [#147](https://github.com/FuelLabs/sway-standards/pull/147) Prepares for the v0.6.1 release.
47+
48+
### Fixed v0.6.1
49+
50+
- [#137](https://github.com/FuelLabs/sway-standards/pull/137) Resolves warnings for SRC-6, SRC-14, and SRC-5 standard examples.
51+
- [#136](https://github.com/FuelLabs/sway-standards/pull/136) Fixes SRC14 to recommend namespacing all non-standardized storage variables under the SRC14 namespace, fixes typos, and improves markdown in docs and inline documentation.
52+
- [#142](https://github.com/FuelLabs/sway-standards/pull/142) Fixes errors in inline documentation for SRC-10, SRC-12, SRC-14, SRC-20, SRC-3, SRC-5, SRC-7 standards.
53+
3254
## [Version 0.6.0]
3355

3456
### Added v0.6.0

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[package]
22
name = "sway-standards"
3-
version = "0.6.0"
3+
version = "0.6.1"
44
edition = "2021"

README.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -9,8 +9,8 @@
99
<a href="https://github.com/FuelLabs/sway-standards/actions/workflows/ci.yml" alt="CI">
1010
<img src="https://github.com/FuelLabs/sway-standards/actions/workflows/ci.yml/badge.svg" />
1111
</a>
12-
<a href="https://crates.io/crates/forc/0.61.0" alt="forc">
13-
<img src="https://img.shields.io/badge/forc-v0.61.0-orange" />
12+
<a href="https://crates.io/crates/forc/0.63.3" alt="forc">
13+
<img src="https://img.shields.io/badge/forc-v0.63.3-orange" />
1414
</a>
1515
<a href="./LICENSE" alt="forc">
1616
<img src="https://img.shields.io/github/license/FuelLabs/sway-standards" />
@@ -65,7 +65,7 @@ If you don't find what you're looking for, feel free to create an issue and prop
6565
To import a standard the following should be added to the project's `Forc.toml` file under `[dependencies]` with the most recent release:
6666

6767
```toml
68-
standards = { git = "https://github.com/FuelLabs/sway-standards", tag = "v0.6.0" }
68+
standards = { git = "https://github.com/FuelLabs/sway-standards", tag = "v0.6.1" }
6969
```
7070

7171
> **NOTE:**
@@ -109,7 +109,7 @@ Example of the SRC-3 implementation where a contract mints multiple assets with
109109

110110
#### SRC-5; Ownership Examples
111111

112-
##### - [Uninitalized](./examples/src5-ownership/uninitialized_example/src/uninitialized_example.sw)
112+
##### - [Uninitialized](./examples/src5-ownership/uninitialized_example/src/uninitialized_example.sw)
113113

114114
Example of the SRC-5 implementation where a contract does not have an owner set at compile time with the intent to set it during runtime.
115115

@@ -162,12 +162,12 @@ Example of a minimal SRC-14 implementation with no access control.
162162
Example of a SRC-14 implementation that also implements [SRC-5](https://docs.fuel.network/docs/sway-standards/src-5-ownership/).
163163

164164
> **Note**
165-
> All standards currently use `forc v0.61.0`.
165+
> All standards currently use `forc v0.63.3`.
166166
167167
<!-- TODO:
168168
## Contributing
169169
170-
Check out the [book](https://fuellabs.github.io/sway-libs/book/index.html) for more info!
170+
Check out the [book](https://fuellabs.github.io/sway-libs/book/index.html) for more info!
171171
-->
172172

173173
> **Note**

docs/spell-check-custom-words.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -259,10 +259,10 @@ WAV
259259
OGA
260260
glTF
261261
GLB
262-
Uninitalized
262+
Uninitialized
263263
upgradeability
264264
SetMetadataEvent
265265
SetNameEvent
266266
SetSymbolEvent
267267
SetDecimalsEvent
268-
UpdateTotalSupplyEvent
268+
UpdateTotalSupplyEvent

docs/src/index.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,14 +7,14 @@ Standards in this repository may be in various stages of development. Use of dra
77
If you don't find what you're looking for, feel free to create an issue and propose a new standard!
88

99
> **Note**
10-
> All standards currently use `forc v0.61.0`.
10+
> All standards currently use `forc v0.63.3`.
1111
1212
## Using a standard
1313

1414
To import a standard the following should be added to the project's `Forc.toml` file under `[dependencies]` with the most recent release:
1515

1616
```toml
17-
standards = { git = "https://github.com/FuelLabs/sway-standards", tag = "v0.6.0" }
17+
standards = { git = "https://github.com/FuelLabs/sway-standards", tag = "v0.6.1" }
1818
```
1919

2020
> **NOTE:**

docs/src/src-12-contract-factory.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ There are no other standards that the SRC-12 requires compatibility.
6262

6363
## Security Considerations
6464

65-
This standard takes into consideration child contracts that are deployed with differentiating configurable values, however individual contract behaviors may be dependent on storage variables. As storage variables may change after the contract has been registered with the SRC-12 compliant contract, the standard suggests to check these values upon registration however it is not enforced.
65+
This standard takes into consideration child contracts that are deployed with differentiating configurable values, however individual contract behaviours may be dependent on storage variables. As storage variables may change after the contract has been registered with the SRC-12 compliant contract, the standard suggests to check these values upon registration however it is not enforced.
6666

6767
## Example ABI
6868

docs/src/src-13-soulbound-address.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,15 @@ We must also ensure every `Address` on Fuel has its own Predicate. This can be g
2525
### Definitions
2626

2727
- **Soulbound Address Predicate** - The resulting predicate which owns assets on behalf of an `Address`.
28-
- **Soulbound Address** - The computed `Address` of the *Soulbound Asset Predicate*.
29-
- **Soulbound Asset** - Any [Native Asset](https://docs.fuel.network/docs/sway/blockchain-development/native_assets) sent to the *Soulbound Address*.
28+
- **Soulbound Address** - The computed `Address` of the _Soulbound Asset Predicate_.
29+
- **Soulbound Asset** - Any [Native Asset](https://docs.fuel.network/docs/sway/blockchain-development/native_assets) sent to the _Soulbound Address_.
3030

3131
### Soulbound Address Predicate Specification
3232

33-
- The *Soulbound Address Predicate* SHALL never spend the assets sent to its computed predicate `Address` or *Soulbound Address*.
34-
- The *Soulbound Address Predicate* SHALL encode an `Address` of which it represents the soulbound address.
33+
- The _Soulbound Address Predicate_ SHALL never spend the assets sent to its computed predicate `Address` or _Soulbound Address_.
34+
- The _Soulbound Address Predicate_ SHALL encode an `Address` of which it represents the soulbound address.
3535

36-
Below we define the *Soulbound Address Predicate* where `ADDRESS` MUST be replaced with the `Address` of which the *Soulbound Address Predicate* represents.
36+
Below we define the _Soulbound Address Predicate_ where `ADDRESS` MUST be replaced with the `Address` of which the _Soulbound Address Predicate_ represents.
3737

3838
```sway
3939
predicate;
@@ -50,9 +50,9 @@ fn main() -> bool {
5050

5151
### Soulbound Address
5252

53-
The *Soulbound Address* is the *Soulbound Address Predicate*'s predicate address. A predicate's address(the bytecode root) is defined [here](https://github.com/FuelLabs/fuel-specs/blob/master/src/identifiers/predicate-id.md).
53+
The _Soulbound Address_ is the _Soulbound Address Predicate_'s predicate address. A predicate's address(the bytecode root) is defined [here](https://github.com/FuelLabs/fuel-specs/blob/master/src/identifiers/predicate-id.md).
5454

55-
The *Soulbound Address* may be computed from the *Soulbound Address Predicate*'s bytecode both on-chain or off-chain. For off-chain computation, please refer to the fuels-rs [predicate docs](https://docs.fuel.network/docs/fuels-rs/predicates/). For on-chain computation, please refer to Sway-Lib's [Bytecode Library](https://docs.fuel.network/docs/sway-libs/bytecode/).
55+
The _Soulbound Address_ may be computed from the _Soulbound Address Predicate_'s bytecode both on-chain or off-chain. For off-chain computation, please refer to the fuels-rs [predicate docs](https://docs.fuel.network/docs/fuels-rs/predicates/). For on-chain computation, please refer to Sway-Lib's [Bytecode Library](https://docs.fuel.network/docs/sway-libs/bytecode/).
5656

5757
## Rationale
5858

@@ -66,13 +66,13 @@ This standard is compatible with Fuel's [Native Assets](https://docs.fuel.networ
6666

6767
This standard does not introduce any security concerns, as it does not call external contracts, nor does it define any mutations of the contract state.
6868

69-
It should however be noted that any Native Asset on the Fuel Network is not a Soulbound Asset until it is sent to a *Soulbound Address*.
69+
It should however be noted that any Native Asset on the Fuel Network is not a Soulbound Asset until it is sent to a _Soulbound Address_.
7070

7171
## Example
7272

73-
The following example shows the *Soulbound Address Predicate* for the `0xe033369a522e3cd2fc19a5a705a7f119938027e8e287c0ec35b784e68dab2be6` `Address`.
73+
The following example shows the _Soulbound Address Predicate_ for the `0xe033369a522e3cd2fc19a5a705a7f119938027e8e287c0ec35b784e68dab2be6` `Address`.
7474

75-
The resulting *Soulbound Address* is `0x7f28a538d06788a3d98bb72f4b41012d86abc4b0369ee5dedf56cfbaf245d609`. Any Native Assets sent to this address will become Soulbound Assets.
75+
The resulting _Soulbound Address_ is `0x7f28a538d06788a3d98bb72f4b41012d86abc4b0369ee5dedf56cfbaf245d609`. Any Native Assets sent to this address will become Soulbound Assets.
7676

7777
```sway
7878
predicate;

docs/src/src-14-simple-upgradeable-proxies.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ The FuelVM provides an `LDC` instruction that is used by Sway's `std::execution:
2525
### Required Behavior
2626

2727
The proxy contract MUST maintain the address of its target in its storage at slot `0x7bb458adc1d118713319a5baa00a2d049dd64d2916477d2688d76970c898cd55` (equivalent to `sha256("storage_SRC14_0")`).
28-
It SHOULD base other proxy specific storage fields at `sha256("storage_SRC14")` to avoid collisions with target storage.
28+
It SHOULD base other proxy specific storage fields in the `SRC14` namespace to avoid collisions with target storage.
2929
It MAY have its storage definition overlap with that of its target if necessary.
3030

3131
The proxy contract MUST delegate any method call not part of its interface to the target contract.

docs/src/src-2-inline-documentation.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -325,7 +325,7 @@ This standard will improve security by providing developers with relevant inform
325325
/// use ownable::Ownership;
326326
///
327327
/// storage {
328-
/// owner: Ownership = Ownership::initalized(Identity::Address(Address::zero())),
328+
/// owner: Ownership = Ownership::initialized(Identity::Address(Address::zero())),
329329
/// }
330330
///
331331
/// fn foo() {

0 commit comments

Comments
 (0)