Skip to content

fix(bindgen): fix ts bytearray type mapping - #3247

Merged
glihm merged 1 commit into
dojoengine:mainfrom
MartianGreed:fix/ts-bindgen-byte-array
Jun 20, 2025
Merged

fix(bindgen): fix ts bytearray type mapping#3247
glihm merged 1 commit into
dojoengine:mainfrom
MartianGreed:fix/ts-bindgen-byte-array

Conversation

@MartianGreed

@MartianGreed MartianGreed commented Jun 17, 2025

Copy link
Copy Markdown
Contributor

Description

Related issue

#3216

Summary by CodeRabbit

  • Bug Fixes
    • Improved handling of byte array types in TypeScript code generation, ensuring correct input type mapping.
  • Tests
    • Added tests to verify accurate mapping of byte array types to string inputs.
  • Style
    • Removed unnecessary trailing whitespace in documentation comments.

@coderabbitai

coderabbitai Bot commented Jun 17, 2025

Copy link
Copy Markdown
Contributor

Walkthrough

Ohayo sensei! This update adjusts TypeScript code generation for Cairo byte arrays. It removes the unnecessary ByteArray import from starknet and ensures that Cairo's ByteArray type is consistently mapped to JavaScript strings. Additional tests and a trait implementation for comparing type mappings are introduced. No logic or macro behavior is otherwise changed.

Changes

File(s) Summary
crates/dojo/bindgen/src/plugins/typescript/generator/function.rs Removed ByteArray from the starknet import list in check_imports.
crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs Mapped CAIRO_BYTE_ARRAY to JS_STRING for input types; added test for this mapping; added PartialEq impl for tests.
crates/macros/merge-options/src/lib.rs Removed trailing whitespace in a doc comment example.

Sequence Diagram(s)

sequenceDiagram
    participant CairoType
    participant JsTypeMapping
    participant TypeScriptGenerator

    CairoType->>JsTypeMapping: Request mapping for ByteArray
    JsTypeMapping-->>TypeScriptGenerator: Returns JS_STRING
    TypeScriptGenerator->>TypeScriptGenerator: Omits ByteArray from starknet imports
Loading

Possibly related PRs

Suggested reviewers

  • glihm

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f9ba1a9 and ae83f42.

📒 Files selected for processing (3)
  • crates/dojo/bindgen/src/plugins/typescript/generator/function.rs (1 hunks)
  • crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (4 hunks)
  • crates/macros/merge-options/src/lib.rs (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • crates/macros/merge-options/src/lib.rs
🚧 Files skipped from review as they are similar to previous changes (2)
  • crates/dojo/bindgen/src/plugins/typescript/generator/function.rs
  • crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: fmt
✨ Finishing Touches
  • 📝 Generate Docstrings
🧪 Generate Unit Tests
  • Create PR with Unit Tests
  • Post Copyable Unit Tests in Comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai auto-generate unit tests to generate unit tests for this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🔭 Outside diff range comments (1)
crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (1)

160-167: Ohayo sensei – ByteArray short-form is still unmapped

The new match arm correctly maps the full path (CAIRO_BYTE_ARRAY) to JS_STRING, but the test you add below expects the short literal "ByteArray" to resolve the same way.
Currently "ByteArray" falls through to the default branch and will remain "ByteArray", making the test (and generated TS) fail.

A minimal fix is to add an explicit arm (or a suffix check) for the short form in both JsPrimitiveInputType and JsPrimitiveType:

             CAIRO_CONTRACT_ADDRESS => JsPrimitiveInputType(JS_STRING.to_owned()),
             CAIRO_BYTE_ARRAY => JsPrimitiveInputType(JS_STRING.to_owned()),
+            // Allow using the short type without the full module path
+            "ByteArray" => JsPrimitiveInputType(JS_STRING.to_owned()),

Without this, cargo test will fail on test_byte_array_input_type.

🧹 Nitpick comments (1)
crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (1)

378-395: Imported constants look good – minor style nit

Nice addition of JS_STRING to the test imports and the PartialEq shim for JsPrimitiveInputType.
You can simplify the comparison closure slightly:

-        fn eq(&self, other: &JsPrimitiveInputType) -> bool {
-            self == &other.0.as_str()
+        fn eq(&self, other: &JsPrimitiveInputType) -> bool {
+            *self == other.0
         }

No functional gain, just removes an extra reference & call.

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 4c0f09a and 2cfe3d2.

📒 Files selected for processing (2)
  • crates/dojo/bindgen/src/plugins/typescript/generator/function.rs (1 hunks)
  • crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (4 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: fmt
🔇 Additional comments (3)
crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (1)

876-889: Test will fail until short-form mapping is added

As noted above, the second assert_eq! relies on "ByteArray" mapping to JS_STRING, which is not implemented yet. Merge will break CI unless the mapping arm is added.
After adding the extra match arm, this test will pass.

crates/dojo/bindgen/src/plugins/typescript/generator/function.rs (2)

22-25: Removal of ByteArray import LGTM

With ByteArray now mapped to plain string in generated TS, dropping it from the Starknet import keeps the bundle clean and avoids unused-import warnings.
No further action needed.


13-28: Quick sanity-check: detect residual ByteArray references

Just to be safe, run a quick grep to ensure no stale ByteArray symbols remain in the generator after this change:

#!/bin/bash
rg -n "ByteArray" crates/dojo/bindgen/src/plugins/typescript | head

Expect: only occurrences in tests or constant definitions, none inside production generator code.

@MartianGreed
MartianGreed force-pushed the fix/ts-bindgen-byte-array branch 2 times, most recently from 0a554ca to 10d2dbe Compare June 18, 2025 08:14

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
crates/dojo/bindgen/src/lib.rs (1)

267-267: Ohayo sensei! Replace magic number with self-documenting expectation

Bumping the expected model count from 89 works today but is brittle: any future model addition/removal will break the test again. Prefer deriving the expectation from the data you already have, or enumerating the expected tags and asserting on that list’s length—this keeps intent obvious and failures more informative.

-        assert_eq!(data.models.len(), 9);
+        // Expected models we explicitly care about; update list, not magic number.
+        let expected = ["ns-Position", "ns-Moves", "ns-Message", "ns-PlayerConfig", /* … */];
+        assert_eq!(data.models.len(), expected.len());
+        for tag in expected {
+            assert!(data.models.contains_key(tag), "{tag} missing");
+        }
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0a554ca and 10d2dbe.

📒 Files selected for processing (3)
  • crates/dojo/bindgen/src/lib.rs (2 hunks)
  • crates/dojo/bindgen/src/plugins/typescript/generator/function.rs (1 hunks)
  • crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs (4 hunks)
✅ Files skipped from review due to trivial changes (1)
  • crates/dojo/bindgen/src/plugins/typescript/generator/function.rs
🚧 Files skipped from review as they are similar to previous changes (1)
  • crates/dojo/bindgen/src/plugins/typescript/generator/mod.rs
⏰ Context from checks skipped due to timeout of 90000ms (1)
  • GitHub Check: fmt
🔇 Additional comments (1)
crates/dojo/bindgen/src/lib.rs (1)

15-17: Ohayo sensei! Import re-order looks fine

Pure re-ordering; no semantic changes, compilation unaffected.

@MartianGreed
MartianGreed force-pushed the fix/ts-bindgen-byte-array branch 3 times, most recently from f9ba1a9 to ad4a2b8 Compare June 18, 2025 08:28
@MartianGreed
MartianGreed force-pushed the fix/ts-bindgen-byte-array branch from ad4a2b8 to ae83f42 Compare June 18, 2025 08:51
@glihm
glihm merged commit 79963e2 into dojoengine:main Jun 20, 2025
glihm added a commit that referenced this pull request Jul 3, 2025
* Fix broken getting started link in README (#3235)

* chore(versions): add torii 1.5.6

* Update DEVELOPMENT.md (#3236)

* Update DEVELOPMENT.md with new instructions

* Update scripts/rebuild_test_artifacts.sh with Rabbit suggestion

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Respond to review comments

* Respond to review comments II

* Respond to review comments III

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* feat: update rpc spec to 0.8 (#3179)

* release(prepare): v1.6.0-alpha.0 (#3241)

Prepare release: v1.6.0-alpha.0

Co-authored-by: glihm <glihm@users.noreply.github.com>

* chore(versions): bump katana to 1.6.0-alpha.0

* fix(dojoup): remove new line in the source cmd (#3244)

fix: fixed new line in the source cmd

* chore: edited the build badge and its link (#3221)

Co-authored-by: Ammar Arif <evergreenkary@gmail.com>

* chore(devcontainer): update image: v1.6.0-alpha.0 (#3242)

Update devcontainer image: v1.6.0-alpha.0

Co-authored-by: glihm <glihm@users.noreply.github.com>

* chore: add katana 1.5.4 (#3245)

* chore: add the missing backticks in the comments (#3243)

Signed-off-by: one230six <723682061@qq.com>

* fix(bindgen): use world namespace for imported models in TypeScript S… (#3249)

* fix(bindgen): filter out Value models (#3248)

* fix(bindgen): fix ts bytearray type mapping (#3247)

* chore: update katana versions (#3253)

add katana versions

* sozo(unrealengine): handle UE5.6 and Dojo 1.5 (#3252)

* fix(sozo): assert caller permission with match (#3254)

* handle call_contract_syscall() result for better panic trace

* avoid using 0 as caller address

* remove temporarly the RPC version check.

Currently, Katana uses the new RPC types, without
bumping the spec version. To ensure we can still use
sozo with sepolia/mainnet and Katana, Sozo will not check
the RPC version for now

* update test dbs

---------

Co-authored-by: glihm <dev@glihm.net>

* feat(sozo): create standalone bindgen command (#3246)

* feat: create standalone bindgen command

* cleanup unused inputs

* remove dbg

* add meaningful error if project is not built

---------

Co-authored-by: glihm <dev@glihm.net>

* feat(sozo): add MCP sever (#3256)

* feat(sozo): add mvp for mcp server

* refacto: restructure MCP server

* evaluate changes using official rust sdk

* feat(mcp): add stdio support

* refacto with rmcp crate

* wip

* bump rmcp

* add testing support

* wip

* refacto

* cleanup

* add instructions

* add instructions

* wip test

* refacto tests

* add debugging

* ignore test with katana at the moment

* fix typos and sozo path

* refacto uri parsing

* remove dbg

* disable test that should be run with katana

* fix test, windows fails because of new reqwest version

* refactor(types): schema json sql value (#3257)

* refactor(types): schema json sql value

* remove excess comma

* fix clippy

---------

Co-authored-by: glihm <dev@glihm.net>

* chore: bump cairo packages to 1.6.0-alpha.0

* fix(mcp): ensure test is using latest version

* split scarb metadata ext in a different crate for dependencies

* wip: controller issue

* wip

* wip: resolve conflicts and update deps

* cleanup

* lint

* wip

* wip tests

* fix all tests

* rebuild test db

* fix: run linter

* fix slot dep with github commit

* fix clippy

* fix inspect by adding missing json format

* fix mcp formatting

* fix stdio_test

* use sozo from path

---------

Signed-off-by: one230six <723682061@qq.com>
Co-authored-by: Ritik <ritikverma0050@gmail.com>
Co-authored-by: Daniel Kronovet <kronovet@gmail.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Ammar Arif <evergreenkary@gmail.com>
Co-authored-by: Tarrence van As <tarrencev@users.noreply.github.com>
Co-authored-by: glihm <glihm@users.noreply.github.com>
Co-authored-by: Benjamin <158306087+bengineer42@users.noreply.github.com>
Co-authored-by: braveocheretovych <braveocheretovych@gmail.com>
Co-authored-by: one230six <163239332+one230six@users.noreply.github.com>
Co-authored-by: Brother MartianGreed <valentin@pupucecorp.com>
Co-authored-by: Corentin Cailleaud <corentin.cailleaud@caillef.com>
Co-authored-by: Rémy Baranx <remy.baranx@gmail.com>
Co-authored-by: Larko <59736843+Larkooo@users.noreply.github.com>
glihm added a commit that referenced this pull request Jul 14, 2025
…3266)

* feat: add external contract registering in the world (#3195)

* Use the world as external contract reference and manage upgrades with sozo

* update spawn-and-move with new external contract features

* update test artifacts + world_address in dojo_dev.toml

* export entrypoints + fix tests + remove TODO RBA

* restore test_metadata_updated_event test

* fix tests

* rabbit improvements

* fix test

* feat: add proc macros (#3212)

* WIP

* add macros + core-tests crates + update them from 1.6.0

* update scripts/cairo_fmt.sh + fix fmt

* update CI + Scarb.toml files

* fix fmt

* change from 2.11.2 to 2.11.4

* fix scarb issue + fmt

* one testing library for each test runner (cairo, snfoundry) + update examples

* fix fmt

* update comment

* chore: apply patches to sync exact same commits than scarb

* fix(ci): update rust-toolchain version

* fix(ci): bump clippy to use nightly compatible with 1.86

* fix: clippy and fmt

* update spawn-and-move to use dojo-snf-test

* update world address

---------

Co-authored-by: glihm <dev@glihm.net>

* Scarb crate removing (#3223)

* introduce scarb_interop crate

* handle missing scarb

* introduce metadata instead of workspace to manage dojo related paths and config

* add stats back and ensure profile is propagated until build not only metadata

* cleanup and add error message if SCARB is not set correctly

* add features + packages to build command

* update scarb build/test command

* refactor packages/features

* fix utils.rs + enable auth command

* fix rust fmt

* re-enable sozo commands

* re-enable the last sozo commands + new version command

* fix issue with conflicts_with_all

* check if manifest_path does not exist

* set run() functions as async instead of using tokio

* update init command management

* refactor metadata loading + dead code cleaning

* add build_simple_dev() function to be used to easily build spawn-and-move for tests/benches

* update tests + fmt + clippy

* remove dojo/lang

* remove useless sozo files

* tiny change

* fix CI

* use scarb nightly in CI

* fix manifest_path/manifest_dir issue

* fix fmt

* update snfoundry version + update tests accordingly + add cairo-profiler to .tool-versions

---------

Co-authored-by: glihm <dev@glihm.net>

* feat: add DojoStore trait to handle storage serialization (#3219)

* add DojoStore management

* fix rust fmt after abigen

* fix ModelReader

* fix fmt

* set DojoStore functions as inline(always)

* update test artifacts

* fix fmt

* remove dojo-core test from CI as all tests are now in core-tests

* feat: add block number for external contract events (#3224)

* add block_number to ExternalContractRegistered/ExternalContractUpgraded events

* remove useless println

* restore external_contracts tests + update with block_number

* update test artifacts

* fix clippy

* rework: handle block_number

* fix world.dns for external contract + update tests

* update sozo events with missing events

* add a self-managed external contract called from spawn-and-move

* update manifest_dev.json

* use dns_address

* fix fmt + abigen

* update test artifacts

* fix fmt

* update starkli path

* update policies

* rebuild test db

* fix: restore resource order to avoid storage conflict (#3238)

* Resource enum variant order should not change as it is used in the world storage

* fix fmt

* fix world address and test db

* fix fmt

---------

Co-authored-by: glihm <dev@glihm.net>

* fix(lang): remove warning with unit type (#3255)

fix warning with unit type for enumerations serialization generated code.

* dev: merge main in dev 1.6.0 (#3263)

* Fix broken getting started link in README (#3235)

* chore(versions): add torii 1.5.6

* Update DEVELOPMENT.md (#3236)

* Update DEVELOPMENT.md with new instructions

* Update scripts/rebuild_test_artifacts.sh with Rabbit suggestion

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* Respond to review comments

* Respond to review comments II

* Respond to review comments III

---------

Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>

* feat: update rpc spec to 0.8 (#3179)

* release(prepare): v1.6.0-alpha.0 (#3241)

Prepare release: v1.6.0-alpha.0

Co-authored-by: glihm <glihm@users.noreply.github.com>

* chore(versions): bump katana to 1.6.0-alpha.0

* fix(dojoup): remove new line in the source cmd (#3244)

fix: fixed new line in the source cmd

* chore: edited the build badge and its link (#3221)

Co-authored-by: Ammar Arif <evergreenkary@gmail.com>

* chore(devcontainer): update image: v1.6.0-alpha.0 (#3242)

Update devcontainer image: v1.6.0-alpha.0

Co-authored-by: glihm <glihm@users.noreply.github.com>

* chore: add katana 1.5.4 (#3245)

* chore: add the missing backticks in the comments (#3243)

Signed-off-by: one230six <723682061@qq.com>

* fix(bindgen): use world namespace for imported models in TypeScript S… (#3249)

* fix(bindgen): filter out Value models (#3248)

* fix(bindgen): fix ts bytearray type mapping (#3247)

* chore: update katana versions (#3253)

add katana versions

* sozo(unrealengine): handle UE5.6 and Dojo 1.5 (#3252)

* fix(sozo): assert caller permission with match (#3254)

* handle call_contract_syscall() result for better panic trace

* avoid using 0 as caller address

* remove temporarly the RPC version check.

Currently, Katana uses the new RPC types, without
bumping the spec version. To ensure we can still use
sozo with sepolia/mainnet and Katana, Sozo will not check
the RPC version for now

* update test dbs

---------

Co-authored-by: glihm <dev@glihm.net>

* feat(sozo): create standalone bindgen command (#3246)

* feat: create standalone bindgen command

* cleanup unused inputs

* remove dbg

* add meaningful error if project is not built

---------

Co-authored-by: glihm <dev@glihm.net>

* feat(sozo): add MCP sever (#3256)

* feat(sozo): add mvp for mcp server

* refacto: restructure MCP server

* evaluate changes using official rust sdk

* feat(mcp): add stdio support

* refacto with rmcp crate

* wip

* bump rmcp

* add testing support

* wip

* refacto

* cleanup

* add instructions

* add instructions

* wip test

* refacto tests

* add debugging

* ignore test with katana at the moment

* fix typos and sozo path

* refacto uri parsing

* remove dbg

* disable test that should be run with katana

* fix test, windows fails because of new reqwest version

* refactor(types): schema json sql value (#3257)

* refactor(types): schema json sql value

* remove excess comma

* fix clippy

---------

Co-authored-by: glihm <dev@glihm.net>

* chore: bump cairo packages to 1.6.0-alpha.0

* fix(mcp): ensure test is using latest version

* split scarb metadata ext in a different crate for dependencies

* wip: controller issue

* wip

* wip: resolve conflicts and update deps

* cleanup

* lint

* wip

* wip tests

* fix all tests

* rebuild test db

* fix: run linter

* fix slot dep with github commit

* fix clippy

* fix inspect by adding missing json format

* fix mcp formatting

* fix stdio_test

* use sozo from path

---------

Signed-off-by: one230six <723682061@qq.com>
Co-authored-by: Ritik <ritikverma0050@gmail.com>
Co-authored-by: Daniel Kronovet <kronovet@gmail.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Ammar Arif <evergreenkary@gmail.com>
Co-authored-by: Tarrence van As <tarrencev@users.noreply.github.com>
Co-authored-by: glihm <glihm@users.noreply.github.com>
Co-authored-by: Benjamin <158306087+bengineer42@users.noreply.github.com>
Co-authored-by: braveocheretovych <braveocheretovych@gmail.com>
Co-authored-by: one230six <163239332+one230six@users.noreply.github.com>
Co-authored-by: Brother MartianGreed <valentin@pupucecorp.com>
Co-authored-by: Corentin Cailleaud <corentin.cailleaud@caillef.com>
Co-authored-by: Rémy Baranx <remy.baranx@gmail.com>
Co-authored-by: Larko <59736843+Larkooo@users.noreply.github.com>

* feat(core): use metaprogramming for tuple and fixed size array Introspect and DojoStore (#3260)

* reuse Starkware metaprogramming stuff to manage tuples

* fix fmt + clippy + artifacts

* use metaprogramming to handle tuple introspect

* fix fmt + clippy + artifacts

* add fixed size array support

* update dojo-world

* update abigen + artifacts after rebase

* add a sum_sizes function

* update artifacts

* tooling: add cairo-bench tool + bench tests (#3240)

* add cairo-bench tool

* add bench tests

* first optimisation batch

* fix fmt

* add license info

* update artifacts after rebase

* fix cairo-bench tests

* update artifacts

* update artifacts

* update scarb lock

---------

Co-authored-by: glihm <dev@glihm.net>

* fix(cairo-bench): use write and threshold + refactor fixed size array (#3267)

* remove update-ref-test-list argument

* add threshold parameter to cairo-bench (set to 3% by default)

* max_fee_raw and fee_estimate_multiplier don't exist anymore

* update sozo model commands for fixed size arrays

* fix fmt + clippy

* rename --update-ref to --write

* fix some tests

* fix fmt

* fix(ci): update katana to 1.6.2 for compatible db

---------

Signed-off-by: one230six <723682061@qq.com>
Co-authored-by: Rémy Baranx <remy.baranx@gmail.com>
Co-authored-by: Ritik <ritikverma0050@gmail.com>
Co-authored-by: Daniel Kronovet <kronovet@gmail.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: Ammar Arif <evergreenkary@gmail.com>
Co-authored-by: Tarrence van As <tarrencev@users.noreply.github.com>
Co-authored-by: glihm <glihm@users.noreply.github.com>
Co-authored-by: Benjamin <158306087+bengineer42@users.noreply.github.com>
Co-authored-by: braveocheretovych <braveocheretovych@gmail.com>
Co-authored-by: one230six <163239332+one230six@users.noreply.github.com>
Co-authored-by: Brother MartianGreed <valentin@pupucecorp.com>
Co-authored-by: Corentin Cailleaud <corentin.cailleaud@caillef.com>
Co-authored-by: Larko <59736843+Larkooo@users.noreply.github.com>
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