Skip to content
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

refactor(language.rust): check wasmwasi target and return error if mismatched #1382

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

anthony-gomez-fastly
Copy link
Contributor

@anthony-gomez-fastly anthony-gomez-fastly commented Jan 28, 2025

Breaking change to support Rust 1.84 and newer

BREAKING CHANGE:
Only the wasm32-waip1 build target is accepted if a non default config is provided

All Submissions:

  • Have you followed the guidelines in our Contributing document?
  • Have you checked to ensure there aren't other open Pull Requests for the same update/change?

New Feature Submissions:

  • Does your submission pass tests?

Changes to Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • Have you successfully run tests with your changes locally?

Are there any considerations that need to be addressed for release?

this is a breaking change and will require a major version bump to prevent breakages

@anthony-gomez-fastly anthony-gomez-fastly force-pushed the CDTOOL-1004-support-rust-1.84 branch 6 times, most recently from 5283bcd to 97ea81b Compare January 29, 2025 20:45
@anthony-gomez-fastly anthony-gomez-fastly marked this pull request as ready for review January 29, 2025 20:45
Integralist
Integralist previously approved these changes Jan 30, 2025
@Integralist
Copy link
Collaborator

LGTM, and I've approved the PR but we'll need either @kpfleming or @philippschulte to handle merging this PR and the subsequent new major release.

philippschulte
philippschulte previously approved these changes Jan 30, 2025
Copy link
Member

@philippschulte philippschulte left a comment

Choose a reason for hiding this comment

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

This looks great! I compared your changes to what Kevin recommended in the ticket. We're not cutting a new release before this has been tested and approved by Kevin. I would recommend to build binaries and share it internally for testing.

@@ -144,12 +147,17 @@ func (r *Rust) Dependencies() map[string]string {

// Build compiles the user's source code into a Wasm binary.
func (r *Rust) Build() error {
var wasmWasiTarget = r.config.WasmWasiTarget
if wasmWasiTarget != RustWasmWasiTarget {
return fmt.Errorf("your WasmWasi target in your config was %s, please change it to %s", wasmWasiTarget, RustWasmWasiTarget)
Copy link
Member

Choose a reason for hiding this comment

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

This helps to get it compiled but maybe it should also list the other required compute project changes. I am not sure about that just something to think about. Also do we already have a public page with instructions or is this something we decided not to do anymore?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

good question, the vibe i was getting is that we generally don't expect people to provide their own configs and that they'll use the default. But it's good to check that assumption, i'll poke around

…smatched

Breaking change to support Rust 1.84 and newer

BREAKING CHANGE:
Only the wasm32-waip1 build target is accepted if a non default config is provided
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants