Releases: software-mansion/scarb
v2.8.5
Welcome to the release notes for Scarb v2.8.5
!
The primary aim of this release is to bring Cairo compiler fix release.
New developments included
- Support packaging cairo-plugins - Scarb can now be called with
scarb package
andscarb publish
on a package, that implements procedural macros. - Support enabling features when compiling integration tests - This release fixes a bug, because of which selected features have not been enabled on main package of integration tests.
Cairo Version
This version of Scarb comes with Cairo v2.8.5
.
What's Changed
- Support packaging cairo-plugins by @DelevoXDG in #1605
- Enable features for main package during integration tests compilation by @DelevoXDG in #1646
- Fix packaging plugins when --no-verify is passed by @DelevoXDG in #1643
- Doc fix - procedural macros by @wawel37 in #1651
- Doc typo fix - Publishing to registry by @DelevoXDG in #1654
- Stop using process:exit for error code handling by @maciektr in #1652
- Add CI to publish builtin plugins by @DelevoXDG in #1648
- Return ExitCode instead of process:exit() in extensions by @maciektr in #1667
- Update mermaid dependency by @maciektr in #1671
Full Changelog: v2.8.4...v2.8.5
v2.8.4
Welcome to the release notes for Scarb v2.8.4
!
The primary aim of this release is to bring Cairo compiler fix release.
New developments included
scarb fmt
for formatting path - Scarb formatter can now accept paths to format. This can be useful when integrating with external tooling.#[doc(hidden)]
support in Scarb Doc - Since this release, you can hide docs for some parts of your codebase with#[doc(hidden)]
attributes.
Cairo Version
This version of Scarb comes with Cairo v2.8.4
.
What's Changed
- Ignore items with #[doc(hidden)] by @wawel37 in #1597
- Update snforge init test for foundry 0.31.0 by @maciektr in #1618
- Bump the non-critical group with 4 updates by @dependabot in #1621
- Fix documentation typo by @wawel37 in #1624
- feat: scarb fmt a subdirectory by @enitrat in #1626
- Update scarb docs by @maciektr in #1630
- Bump deno_task_shell from 0.18.0 to 0.18.1 by @dependabot in #1633
- Bump once_cell from 1.20.0 to 1.20.2 in the non-critical group by @dependabot in #1632
New Contributors
Full Changelog: v2.8.3...v2.8.4
v2.8.3
Welcome to the release notes for Scarb v2.8.3
!
The primary aim of this release is to bring changes that will make test targets compilation faster.
This release also includes several interface changes and developments.
Contracts from dependencies no longer compiled by default with cairo-test
Warning
If your cairo-test
tests use contracts defined in dependencies, an action is required!
Until this Scarb release, cairo-test
has been implicitly building all contracts from all dependencies of the tested package.
This strategy has been seen as convenient for it's users (as no action has been required from them to use those contracts in their tests). However, as Cairo codebases grew, it became unsustainably suboptimal. Since this release, only contracts defined in build-external-contracts
property on [[target.starknet-contract]]
section are built when compiling tests. See Scarb documentation for more details. This is the same strategy, that has been already used by Starknet Foundry Forge, as described in docs.
Print profile names in finished build message
From this release, the message printed on finished build now includes the name of the profile used.
For example:
Finished `dev` profile target(s) in 4 seconds
Support Trait and Impl inner functions in Scarb procedural macro attributes
It is now possible, to use attribute procedural macros on functions defined in traits or impls.
For instance, following syntax is now supported to expand some_attribute
attribute.
#[abi(embed_v0)]
impl SomeImpl of ISomeInterface<ContractState> {
fn get(self: @ContractState) -> u128 {
self.counter.read()
}
#[some_attribute]
fn increase(ref self: ContractState) {
self.counter.write( self.counter.read() + 1 );
}
}
Features validation in a workspace bug fix
Due to a bug in features validation logic, it has been observed that features defined in a single package of a workspace failed to resolved if not defined in other workspace packages. This logic has been fixed now.
Minor interface changes
- Target kinds filter in
scarb build
- This version introduces new optional argument--target-kinds
which accepts a coma separated list of target kind names. If present, only specified target kinds will be built. - Cairo run arguments file - This version introduces new optional argument
--arguments-file
, which can be used to provide program arguments through file on host os.
Cairo Version
This version of Scarb comes with Cairo v2.8.2
.
What's Changed
- Bump the non-critical group with 6 updates by @dependabot in #1583
- Update Cairo by @maciektr in #1584
- Update CODEOWNERS by @maciektr in #1588
- Print profile name in finished targets message by @maciektr in #1587
- Add target-kinds filter argument to build by @maciektr in #1589
- Feat: cairo-run extension: support --arguments-file optional parameter by @m-kus in #1591
- Bump the non-critical group with 3 updates by @dependabot in #1594
- Bump dompurify from 3.0.5 to 3.1.6 in /website by @dependabot in #1595
- Make paths displed on left nav bar if duplicated by @wawel37 in #1592
- Fix single package features in a workspace by @maciektr in #1593
- Bump vite from 5.2.12 to 5.4.6 in /website by @dependabot in #1602
- Support more ModuleItems in proc macro attribute expansion by @maciektr in #1556
- Adjust tests to new trait types and consts signatures by @wawel37 in #1600
- Remove redundant call to DiagnosticsReporter::ensure by @maciektr in #1604
- Compile contract artifacts in test targets by @maciektr in #1585
- Bump thiserror from 1.0.63 to 1.0.64 in the non-critical group by @dependabot in #1607
- Update docs by @maciektr in #1606
- Only search build-external-contracts for contracts in test target compilation by @maciektr in #1612
- Bump starknet-types-core from 0.1.5 to 0.1.6 by @dependabot in #1608
- Bump rollup from 4.21.3 to 4.22.4 in /website by @dependabot in #1614
New Contributors
Full Changelog: v2.8.2...v2.8.3
v2.8.2
Welcome to the release notes for Scarb v2.8.2
!
This release includes several bug fixes and new developments.
- Scarb publish support - Scarb now supports publishing packages to the registry! To upload a package to the official scarbs.xyz registry, you can now simply do
scarb publish
. The authentication token for the registry interactions can be obtained through the registry and provided by environmental variable. Please see the "Publishing" page in our documentation for more information. - Hidden line support in doc snippets - documentation generated with
scarb doc
now supports hidding code lines in Cairo code snippets. Thehighlight.js
highlighter modified for use withscarb doc
generated docs supports highligthing snippets with hidden lines. - Unnecessary registry downloads fix - Due to a bug in registry client implementation, some packages would end up being unnecessarly downloaded multiple times. Since this release, this should not happen no more.
Cairo Version
This version of Scarb comes with Cairo v2.8.2
.
What's Changed
- Update README.md by @mkaput in #1558
- Update cairo by @maciektr in #1559
- Bump slackapi/slack-github-action from 1.26.0 to 1.27.0 by @dependabot in #1567
- Bump deno_task_shell from 0.17.0 to 0.18.0 by @dependabot in #1569
- Bump the non-critical group with 4 updates by @dependabot in #1568
- Fix unnecessary downloads of cached registry packages by @DelevoXDG in #1571
- Update highlight.js / hidden line rust. by @wawel37 in #1566
- Rename
open_rw
->create_rw
by @DelevoXDG in #1573 - Update CODEOWNERS by @maciektr in #1575
- Add
cargo xtask set-cairo-version --path
by @mkaput in #1578 - Remove allow(dead_code) from scarb-doc by @maciektr in #1574
- Add package publish by @THenry14 in #1570
Full Changelog: v2.8.1...v2.8.2
v2.8.1
Welcome to the release notes for Scarb v2.8.1
!
This is a quick fix release which does not include any new features - only bug fixes.
- The assert_macros package version change - the
assert_macros
package that contains macros likeassert_eq!
is now versioned with the same version as Cairo compiler used by Scarb.
Cairo Version
This version of Scarb comes with Cairo v2.8.0
.
What's Changed
- Fix proc macro diagnostics stable pointer by @maciektr in #1555
- Fix assert macros by @maciektr in #1563
Full Changelog: v2.8.0...v2.8.1
v2.8.0
Welcome to the release notes for Scarb v2.8.0
!
This release includes several bug fixes and new developments.
- Scarb features support in scarb-doc - you can now control conditional compilation while generating docs!
- Document only public items - the documentation is now only generated for public items by
scarb-doc
(unless used with--document-private-items
flag). - Cairo coverage support - Scarb now includes an
unstable-add-statements-code-locations-debug-info
Cairo config key that enables generating mappings used by cairo-coverage. - Dev dependencies propagation fix - due to an error in Scarb dependency resolver, in some cases dev-deps from other workspace members would end up being used during compilation.
- Diagnostics fix - in some cases, diagnostics from package dependencies could be missing, resulting in a panic during package build.
The assert_macros package version change - the(fixed inassert_macros
package that contains macros likeassert_eq!
is now versioned with the same version as Scarb.2.8.1
)
Cairo Version
This version of Scarb comes with Cairo v2.8.0
.
What's Changed
- Add cairo highlight documentation by @wawel37 in #1521
- Update Cairo by @maciektr in #1522
- Document registries and packaging process by @szymmis in #962
- Bump the non-critical group with 6 updates by @dependabot in #1526
- Fix test runner flag in docs by @maciektr in #1529
- Doc/features support by @wawel37 in #1511
- Update Cairo, move scarb-doc to rust-analyzer-salsa by @maciektr in #1531
- Document Scarb.toml
publish
field by @DelevoXDG in #1533 - Update Cairo by @maciektr in #1539
- starknet_multiple_contracts example refurbishment by @stranger80 in #1543
- Fix dev-deps propagation for ws members by @maciektr in #1542
- Revert "Fix diagnostics reporter main crates setup (#1514)" by @maciektr in #1540
- Pin assert_macros version to Scarb version by @maciektr in #1537
- Doc / Add
--document-private-items
flag by @wawel37 in #1528 - Do not show warnings from dependencies by @maciektr in #1547
- Add
unstable-add-statements-code-locations-debug-info
flag by @maciektr in #1538 - Bump the non-critical group with 7 updates by @dependabot in #1545
- Update gix to 0.66 by @maciektr in #1549
- Stack size troubleshooting by @maciektr in #1548
- Fix dev deps propagation by @maciektr in #1552
- Prepare release
2.8.0
by @maciektr in #1551
New Contributors
- @stranger80 made their first contribution in #1543
Full Changelog: v2.7.1...v2.8.0
v2.7.1
Welcome to the release notes for Scarb v2.7.1
!
This release is primarily a Cairo update.
It also introduces an mdBook
compatible Cairo code highlighter, that can be useful for docs generated with scarb-doc
.
Cairo Version
This version of Scarb comes with Cairo v2.7.1
.
What's Changed
- Create highlight.js file for mdBook cairo support by @wawel37 in #1499
- Update cairo, fix nightlies by @THenry14 in #1505
- Bump the non-critical group with 5 updates by @dependabot in #1504
- Update cairo, fix nightlies by @THenry14 in #1510
- Fix diagnostics reporter main crates setup by @maciektr in #1514
- Added Nit about doc markdown being mdBook compatiable. by @wawel37 in #1513
- Bump the non-critical group with 7 updates by @dependabot in #1515
- Add basic scarb doc documentation by @wawel37 in #1518
- Prepare release
2.7.1
by @maciektr in #1520
New Contributors
Full Changelog: v2.7.0...v2.7.1
v2.7.0
Welcome to the release notes for Scarb v2.7.0
!
This release comes with several new developments.
Procedural macros
Since this release, we now officially support code generation! You can write your own macros in Rust, that modify the Cairo code of your project during compilation.
Learn more by reading our docs.
Generating documentation with scarb-doc
With this release, it is now possible to automatically generate documentation for your project by running scarb doc
command. This documentation will include all doc comments you add to your code with ///
prefix. The collected documentation is output to the target/doc/<package-name>
directory, in either custom JSON
, or mdBook
compatible markdown format.
Learn more by reading our docs.
Cairo Version
This version of Scarb comes with Cairo v2.7.0
.
What's Changed
- Update Cairo by @maciektr in #1469
- Bump the non-critical group with 6 updates by @dependabot in #1470
- Foldable sidebar by @piotmag769 in #1468
- Bump openssl from 0.10.64 to 0.10.66 by @dependabot in #1471
- Fix clippy warnings after rust update by @maciektr in #1476
- Allow executing scripts in workspace root by @maciektr in #1473
- Bump gix-attributes from 0.22.2 to 0.22.3 by @dependabot in #1475
- Replace stabilized once_cell api by @maciektr in #1477
- Make scarb new and init command interactive by @ksew1 in #1472
- Fix inlining strategy flag - pass during db construction by @maciektr in #1478
- Bump gix from 0.63.0 to 0.64.0 by @dependabot in #1481
- Bump the non-critical group with 6 updates by @dependabot in #1480
- Update CODEOWNERS by @maciektr in #1482
- Prepare scarb-stable-hash for publishing by @maciektr in #1490
- Prepare cairo-lang-macro-stable for publishing by @maciektr in #1491
- Add procedural macros page to docs by @maciektr in #1492
- Fix verify archive smoke test by @maciektr in #1498
- Drop rlib from build_cairo_plugin tests by @maciektr in #1493
- Prepare cairo-lang-macro-attributes for publishing by @maciektr in #1494
- Prepare cairo-lang-macro for publishing by @maciektr in #1495
- Add link to docs.rs for cairo-lang-macro by @maciektr in #1496
- Prepare release 2.7.0 by @THenry14 in #1500
New Contributors
Full Changelog: v2.7.0-rc.4...v2.7.0
v2.7.0-rc.4
Welcome to the release notes for Scarb v2.7.0-rc.4
!
Warning
This version is not supported on Starknet! If you want to develop contracts deployable to the current Starknet, please stick with Scarb v2.6.5
This quick release changes the default registry url used by Scarb.
Cairo Version
This version of Scarb comes with Cairo v2.7.0-rc.3
.
What's Changed
- Update Cairo by @maciektr in #1451
- Extract package metadata info + refactor by @piotmag769 in #1460
- Add book.toml generation by @piotmag769 in #1461
- Add traits for generating markdown docs by @piotmag769 in #1462
- Bump gix-path from 0.10.8 to 0.10.9 by @dependabot in #1466
- Markdown generation by @piotmag769 in #1463
- Tests for md generation by @piotmag769 in #1464
- Enable registry usage by default by @THenry14 in #1465
- Prepare release
2.7.0-rc.4
by @maciektr in #1467
New Contributors
Full Changelog: v2.7.0-rc.3...v2.7.0-rc.4
v2.7.0-rc.3
Welcome to the release notes for Scarb v2.7.0-rc.3
!
Warning
This version is not supported on Starknet! If you want to develop contracts deployable to the current Starknet, please stick with Scarb v2.6.5
This quick release is primarily a Cairo upgrade.
Cairo Version
This version of Scarb comes with Cairo v2.7.0-rc.3
.
What's Changed
- Fix ignored test case by @maciektr in #1443
- Update Cairo by @maciektr in #1446
- Update README.md by @mkaput in #1448
- Allow packaging with publish=false by @maciektr in #1447
- Bump the non-critical group with 6 updates by @dependabot in #1449
- Prepare release
2.7.0-rc.3
by @maciektr in #1450
Full Changelog: v2.7.0-rc.2...v2.7.0-rc.3