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

chore: integrate wash into the repository #807

Merged
merged 66 commits into from
Oct 30, 2023

Conversation

rvolosatovs
Copy link
Member

@rvolosatovs rvolosatovs commented Oct 26, 2023

Feature or Problem

Integrate wash into the workspace and CI pipelines.

cargo build -p wash-cli will now produce a wash binary in workspace target (also, cargo build --workspace, for example)
That means that nix build '.#wasmcloud-${target}' now also produce both binaries reproducibly-built

I had to switch to native Windows builds due to rust-lang/rust#92212, which is now hit by wash, but not wasmcloud. We can revisit this if/when either:

  • wash dependency set becomes smaller
  • issue is fixed upstream
  • using MSVC on Linux is feasible

Things done:

  • Addressed cargo audit issues
  • Cleaned up the wash-cli code originally such that we could simply have a second binary in root-level src/bin, but I have since switched the approach and moved the binary back to crates/wash-cli. I've left the improvements in.
  • washboard MUST be a subdirectory of wherever wash-cli Cargo.toml is located, now that's crates/wash-cli.

Some things may still be broken - there's a lot of hidden details in configs etc. (like the wash snapcraft config), but I tried my best to address everything. It's best to address anything left in follow-ups to minimize diff and get this one over the line, archive wash repo

Related Issues

Release Information

Consumer Impact

Testing

Built on platform(s)

  • x86_64-linux
  • aarch64-linux
  • x86_64-darwin
  • aarch64-darwin
  • x86_64-windows

Tested on platform(s)

  • x86_64-linux
  • aarch64-linux
  • x86_64-darwin
  • aarch64-darwin
  • x86_64-windows

Unit Test(s)

Acceptance or Integration

Manual Verification

connorsmith256 and others added 30 commits October 17, 2023 21:37
Signed-off-by: Connor Smith <connor.smith.256@gmail.com>
Bumps [lucide-react](https://github.com/lucide-icons/lucide/tree/HEAD/packages/lucide-react) from 0.287.0 to 0.288.0.
- [Release notes](https://github.com/lucide-icons/lucide/releases)
- [Commits](https://github.com/lucide-icons/lucide/commits/0.288.0/packages/lucide-react)

---
updated-dependencies:
- dependency-name: lucide-react
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
…rn/washboard/lucide-react-0.288.0

build(deps): Bump lucide-react from 0.287.0 to 0.288.0 in /washboard
Bumps [vite](https://github.com/vitejs/vite/tree/HEAD/packages/vite) from 4.4.11 to 4.5.0.
- [Release notes](https://github.com/vitejs/vite/releases)
- [Changelog](https://github.com/vitejs/vite/blob/v4.5.0/packages/vite/CHANGELOG.md)
- [Commits](https://github.com/vitejs/vite/commits/v4.5.0/packages/vite)

---
updated-dependencies:
- dependency-name: vite
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) from 18.2.13 to 18.2.14.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom)

---
updated-dependencies:
- dependency-name: "@types/react-dom"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.8.6 to 20.8.7.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Lachlan Heywood <lachieh@users.noreply.github.com>
This PR fixes some flakiness in E2E tests -- what was happening was
that in that in-between tests (particularly the `integration_stop.rs`
suite) `TestWashInstance`s were not having enough time to shut down,
and failing calls to `wash get hosts` were causing a failure.

The serial tests work in such a way that once one of the tests  failes
in a way that leaves `nats-server`/`wasmcloud_host` processes around,
the rest will fail (e.x. `wash` commands behave differently with a
host already running).

In *theory* we should be able to get rid of the serial tests in the
future  with more aggressive port randomization and the use of `wash
ctx`  and augmentation to the `TestWashInstance` machinery (the main
reason we couldn't in the past was that hosts would clobber each
other,  and could not be shut down individually).

This commit allows for failure of `wash get hosts` that is used in
testing machinery (within a timeout), which fixes the issue.

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
…rn/washboard/vite-4.5.0

build(deps-dev): Bump vite from 4.4.11 to 4.5.0 in /washboard
…rn/washboard/types/react-dom-18.2.14

build(deps-dev): Bump @types/react-dom from 18.2.13 to 18.2.14 in /washboard
…rn/washboard/types/node-20.8.7

build(deps-dev): Bump @types/node from 20.8.6 to 20.8.7 in /washboard
Bumps [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) from 18.2.28 to 18.2.29.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: "@types/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
fix(ui): update washboard build files
…rn/washboard/types/react-18.2.29

build(deps-dev): Bump @types/react from 18.2.28 to 18.2.29 in /washboard
This commit refactors some of the testing code to:

- ensure we always print integration test output (save time root
causing in CI and elsewhere)
- consistent use of TARGET to choose which test to run
- use system provided randomized ports (port 0)
- fix some uses of context
- remove some process scanning that was never used

This commit also includes changes test flake fixes from
wasmCloud/wash#921

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
…esting-code-refactor

refactor: various fixes to testing code
Bumps [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) from 18.2.29 to 18.2.30.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: "@types/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
…rn/washboard/types/react-18.2.30

build(deps-dev): Bump @types/react from 18.2.29 to 18.2.30 in /washboard
Bumps [thiserror](https://github.com/dtolnay/thiserror) from 1.0.49 to 1.0.50.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](dtolnay/thiserror@1.0.49...1.0.50)

---
updated-dependencies:
- dependency-name: thiserror
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Connor Smith <connor.smith.256@gmail.com>
Signed-off-by: Connor Smith <connor.smith.256@gmail.com>
Bumps [eslint](https://github.com/eslint/eslint) from 8.51.0 to 8.52.0.
- [Release notes](https://github.com/eslint/eslint/releases)
- [Changelog](https://github.com/eslint/eslint/blob/main/CHANGELOG.md)
- [Commits](eslint/eslint@v8.51.0...v8.52.0)

---
updated-dependencies:
- dependency-name: eslint
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) from 18.2.30 to 18.2.31.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react)

---
updated-dependencies:
- dependency-name: "@types/react"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) from 20.8.7 to 20.8.8.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node)

---
updated-dependencies:
- dependency-name: "@types/node"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@typescript-eslint/parser](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/parser) from 6.8.0 to 6.9.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/parser/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.9.0/packages/parser)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/parser"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [eslint-plugin-import](https://github.com/import-js/eslint-plugin-import) from 2.28.1 to 2.29.0.
- [Release notes](https://github.com/import-js/eslint-plugin-import/releases)
- [Changelog](https://github.com/import-js/eslint-plugin-import/blob/main/CHANGELOG.md)
- [Commits](import-js/eslint-plugin-import@v2.28.1...v2.29.0)

---
updated-dependencies:
- dependency-name: eslint-plugin-import
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [actions/setup-node](https://github.com/actions/setup-node) from 3 to 4.
- [Release notes](https://github.com/actions/setup-node/releases)
- [Commits](actions/setup-node@v3...v4)

---
updated-dependencies:
- dependency-name: actions/setup-node
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [@typescript-eslint/eslint-plugin](https://github.com/typescript-eslint/typescript-eslint/tree/HEAD/packages/eslint-plugin) from 6.8.0 to 6.9.0.
- [Release notes](https://github.com/typescript-eslint/typescript-eslint/releases)
- [Changelog](https://github.com/typescript-eslint/typescript-eslint/blob/main/packages/eslint-plugin/CHANGELOG.md)
- [Commits](https://github.com/typescript-eslint/typescript-eslint/commits/v6.9.0/packages/eslint-plugin)

---
updated-dependencies:
- dependency-name: "@typescript-eslint/eslint-plugin"
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
As the component model and WASI are still maturing, the
components-first codebases built with `wash` should reflect the
experimental nature of support to related tooling.

This commit marks both components as experimental at two levels -- a
custom section in the Wasm metadata (as a custom section) and as a
tag on the signed wasmCloud actor that is produced.

Signed-off-by: Victor Adossi <vadossi@cosmonic.com>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
@rvolosatovs rvolosatovs marked this pull request as ready for review October 30, 2023 13:09
@rvolosatovs rvolosatovs requested review from a team as code owners October 30, 2023 13:09
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Signed-off-by: Roman Volosatovs <rvolosatovs@riseup.net>
Copy link
Member

@brooksmtownsend brooksmtownsend left a comment

Choose a reason for hiding this comment

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

LGTM

Dockerfile Show resolved Hide resolved
@brooksmtownsend brooksmtownsend merged commit f2bc010 into wasmCloud:main Oct 30, 2023
30 checks passed
Copy link
Contributor

@connorsmith256 connorsmith256 left a comment

Choose a reason for hiding this comment

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

Reviewing post-merge to help me understand, and to file at least one follow-up. Huge thank you for getting this migration over the line 🙌

flake.nix Outdated Show resolved Hide resolved
"crates/wash-cli/Dockerfile"
"crates/wash-cli/docs"
"crates/wash-cli/Makefile"
"crates/wash-cli/README.md"
Copy link
Contributor

Choose a reason for hiding this comment

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

This looks a little odd to ignore

Copy link
Member Author

Choose a reason for hiding this comment

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

actually the README does affect the cargo doc build, you're right, I'll remove that

.github/workflows/wash.yml Show resolved Hide resolved
@@ -1,5 +1,4 @@
[advisories]
ignore = [
"RUSTSEC-2020-0071", # `time` localtime_r segfault
"RUSTSEC-2022-0093", # `ed25519-dalek` Oracle attack, remove once https://github.com/deislabs/bindle/pull/368 is merged
Copy link
Contributor

Choose a reason for hiding this comment

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

Is this one still needed? The linked bindle PR has been merged

Copy link
Member Author

Choose a reason for hiding this comment

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

there has been no release

Copy link
Member Author

Choose a reason for hiding this comment

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

.github/CODEOWNERS Show resolved Hide resolved
crates/wash-cli/src/app/mod.rs Show resolved Hide resolved
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.

None yet

7 participants