Skip to content

fix: wasm build issues #256

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 17, 2024
Merged

fix: wasm build issues #256

merged 2 commits into from
Aug 17, 2024

Conversation

ponderingdemocritus
Copy link
Contributor

@ponderingdemocritus ponderingdemocritus commented Aug 17, 2024

  • fixes wasm for web
  • bumps starter package
  • version bumps

Summary by CodeRabbit

  • New Features

    • Updated TypeScript dependency to version 5.5.4 across multiple packages, enhancing compatibility and functionality.
  • Bug Fixes

    • Removed unnecessary dependencies and adjusted paths for improved module resolution in the torii-wasm package.
  • Chores

    • Streamlined build output directory structure for the torii-wasm package, improving organization and clarity.
  • Documentation

    • Updated package configurations to enhance clarity on exported files and structure.

Copy link

coderabbitai bot commented Aug 17, 2024

Walkthrough

The recent updates across various projects focus on enhancing the TypeScript dependency, upgrading it from version ^5.0.3 to ^5.5.4, likely improving functionality and compatibility. The removal of the @dojoengine/torii-wasm dependency from a React app indicates a shift in project reliance. Additionally, adjustments to directory structures and import paths streamline the build processes and improve resource management clarity.

Changes

File(s) Change Summary
examples/react/react-app/package.json Removed @dojoengine/torii-wasm dependency; updated typescript from ^5.0.3 to ^5.5.4.
examples/react/react-pwa-app/package.json Updated typescript from ^5.0.3 to ^5.5.4.
examples/react/react-threejs/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/core/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/create-burner/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/create-dojo/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/react/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/state/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/torii-client/package.json Updated typescript from ^5.0.3 to ^5.5.4.
packages/torii-wasm/build.sh Adjusted output directory paths for WebAssembly builds, removing dist prefix.
packages/torii-wasm/package.json Modified paths to use relative addressing, updated typescript to ^5.5.4, downgraded wasm-pack.

Sequence Diagram(s)

%% No relevant sequence diagrams were generated due to the nature of the changes.
Loading

Poem

🐇 In a world of code, so bright and new,
A hop and a skip, we bid adieu.
TypeScript's upgrade, a leap in the air,
Smooth paths now lead us, with nary a care.
Dependencies shuffled, like leaves in the breeze,
Oh, joy! Let’s code with the greatest of ease! 🌼


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

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>.
    • Generate unit testing code for this file.
    • 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 generate unit testing code for this file.
    • @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 generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @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.

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 as 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 resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

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.

Copy link

@coderabbitai coderabbitai bot left a comment

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, codebase verification and nitpick comments (1)
examples/react/react-app/src/dojo/generated/setup.ts (1)

14-14: Evaluate the use of console logging for debugging.

The console log statement for torii.poseidonHash(["1"]) is useful for debugging, but ensure it does not leak sensitive information and is appropriate for the production environment. Consider using a more robust logging mechanism if needed.

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between 6e07bfb and fae3cac.

Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing (15)
  • examples/dojo-starter (1 hunks)
  • examples/react/react-app/package.json (2 hunks)
  • examples/react/react-app/src/dojo/generated/setup.ts (2 hunks)
  • examples/react/react-pwa-app/package.json (1 hunks)
  • examples/react/react-threejs/package.json (1 hunks)
  • packages/core/package.json (1 hunks)
  • packages/create-burner/package.json (1 hunks)
  • packages/create-dojo/package.json (1 hunks)
  • packages/react/package.json (1 hunks)
  • packages/state/package.json (1 hunks)
  • packages/torii-client/package.json (1 hunks)
  • packages/torii-wasm/build.sh (1 hunks)
  • packages/torii-wasm/package.json (1 hunks)
  • packages/utils-wasm/package.json (1 hunks)
  • packages/utils/package.json (1 hunks)
Files skipped from review due to trivial changes (4)
  • examples/dojo-starter
  • examples/react/react-app/package.json
  • packages/create-burner/package.json
  • packages/torii-wasm/build.sh
Additional comments not posted (14)
packages/torii-client/package.json (1)

21-21: Verify compatibility with TypeScript ^5.5.4.

The TypeScript dependency has been updated. Ensure that the codebase is compatible with the new version, as it may introduce breaking changes or new features.

packages/create-dojo/package.json (1)

25-25: Verify compatibility with TypeScript ^5.5.4.

The TypeScript version in the devDependencies has been updated. Ensure that the development environment is compatible with the new version.

packages/state/package.json (1)

21-21: Verify compatibility with TypeScript ^5.5.4.

The TypeScript version in the devDependencies has been updated. Ensure that the codebase is compatible with the new version, as it may introduce breaking changes or new features.

packages/utils-wasm/package.json (1)

27-27: Verify compatibility with TypeScript 5.5.4.

The TypeScript version has been updated. Ensure that the codebase is compatible with this version and that the build process works correctly.

packages/utils/package.json (1)

24-24: Verify compatibility with TypeScript 5.5.4.

The TypeScript version has been updated. Ensure that the codebase is compatible with this version and that the build process works correctly.

packages/core/package.json (1)

27-27: Verify compatibility with TypeScript 5.5.4.

The TypeScript version has been updated. Ensure that the codebase is compatible with this version and that the build process works correctly.

packages/torii-wasm/package.json (4)

7-8: Approved: Relative path updates.

The changes from absolute to relative paths in the main, browser, module, and types fields improve portability and consistency.

Also applies to: 14-15


17-24: Approved: Explicit file inclusion.

Explicitly listing files in the files field improves clarity and control over the package's exported content.


27-27: Approved: Simplified sideEffects.

The simplification of the sideEffects field to include only the web JavaScript file reflects a more modular approach.


31-32: Verify dependency version changes.

The TypeScript update and wasm-pack downgrade may affect the build process. Ensure compatibility with the project's requirements.

packages/react/package.json (1)

34-34: Approved: TypeScript version update.

The update to TypeScript ^5.5.4 likely includes enhancements and bug fixes. Ensure compatibility with the project's requirements.

examples/react/react-pwa-app/package.json (1)

52-52: Approved: TypeScript version update.

The update to TypeScript ^5.5.4 likely includes enhancements and bug fixes. Ensure compatibility with the project's requirements.

examples/react/react-app/src/dojo/generated/setup.ts (1)

8-8: Verify the removal of WeierstrassSignatureType.

Ensure that the removal of WeierstrassSignatureType does not affect the functionality elsewhere in the codebase.

examples/react/react-threejs/package.json (1)

80-80: TypeScript version update.

The typescript dependency has been updated from ^5.0.3 to ^5.5.4. Ensure that the project is compatible with this new version, and consider testing for any breaking changes or new features that might affect the codebase.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

Commits

Files that changed from the base of the PR and between fae3cac and ec4b6fe.

Files ignored due to path filters (1)
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing (2)
  • .github/workflows/ci.yaml (1 hunks)
  • packages/torii-wasm/package.json (1 hunks)
Files skipped from review due to trivial changes (1)
  • .github/workflows/ci.yaml
Files skipped from review as they are similar to previous changes (1)
  • packages/torii-wasm/package.json

@ponderingdemocritus ponderingdemocritus merged commit d65742d into main Aug 17, 2024
4 checks passed
@ponderingdemocritus ponderingdemocritus deleted the alpha-6 branch August 17, 2024 15:23
@coderabbitai coderabbitai bot mentioned this pull request Sep 12, 2024
4 tasks
@coderabbitai coderabbitai bot mentioned this pull request Oct 3, 2024
This was referenced Oct 31, 2024
@coderabbitai coderabbitai bot mentioned this pull request Mar 19, 2025
5 tasks
@coderabbitai coderabbitai bot mentioned this pull request Jun 5, 2025
5 tasks
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.

1 participant