Skip to content

Commit

Permalink
Merge branch 'main' into pierremtb/issue4711-Improve-shell-selection-…
Browse files Browse the repository at this point in the history
…guards-for-circular-shapes
  • Loading branch information
pierremtb authored Jan 8, 2025
2 parents 6ae164b + eb0850f commit e82ee3e
Show file tree
Hide file tree
Showing 209 changed files with 47,174 additions and 31,779 deletions.
4 changes: 2 additions & 2 deletions .codespellrc
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[codespell]
ignore-words-list: crate,everytime,inout,co-ordinate,ot,nwo,absolutey,atleast,ue,afterall
skip: **/target,node_modules,build,**/Cargo.lock,./docs/kcl/*.md,.yarn.lock,**/yarn.lock,./openapi/*.json,./src/lib/machine-api.d.ts
ignore-words-list: crate,everytime,inout,co-ordinate,ot,nwo,atleast,ue,afterall
skip: **/target,node_modules,build,dist,./out,**/Cargo.lock,./docs/kcl/*.md,.yarn.lock,**/yarn.lock,./openapi/*.json,./packages/codemirror-lang-kcl/test/all.test.ts,tsconfig.tsbuildinfo
46 changes: 25 additions & 21 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,24 +5,28 @@

version: 2
updates:
- package-ecosystem: 'npm' # See documentation for possible values
directory: '/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- franknoirot
- irev-dev
- package-ecosystem: 'github-actions' # See documentation for possible values
directory: '/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- adamchalmers
- jessfraz
- package-ecosystem: 'cargo' # See documentation for possible values
directory: '/src/wasm-lib/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- adamchalmers
- jessfraz
- package-ecosystem: 'npm' # See documentation for possible values
directory: '/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- franknoirot
- irev-dev
- package-ecosystem: 'github-actions' # See documentation for possible values
directory: '/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- adamchalmers
- jessfraz
- package-ecosystem: 'cargo' # See documentation for possible values
directory: '/src/wasm-lib/' # Location of package manifests
schedule:
interval: 'weekly'
reviewers:
- adamchalmers
- jessfraz
groups:
serde-dependencies:
patterns:
- "serde*"
16 changes: 14 additions & 2 deletions .github/workflows/build-apps.yml
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,13 @@ jobs:
CSC_KEY_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
CSC_KEYCHAIN: ${{ secrets.APPLE_SIGNING_IDENTITY }}
WINDOWS_CERTIFICATE_THUMBPRINT: ${{ secrets.WINDOWS_CERTIFICATE_THUMBPRINT }}
run: yarn electron-builder --config --publish always
DEBUG: "electron-notarize*"
# TODO: Fix electron-notarize flakes. The logs above should help gather more data on failures
uses: nick-fields/[email protected]
with:
timeout_minutes: 10
max_attempts: 3
command: yarn electron-builder --config --publish always

- name: List artifacts in out/
run: ls -R out
Expand Down Expand Up @@ -228,7 +234,13 @@ jobs:
CSC_KEY_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
CSC_KEYCHAIN: ${{ secrets.APPLE_SIGNING_IDENTITY }}
WINDOWS_CERTIFICATE_THUMBPRINT: ${{ secrets.WINDOWS_CERTIFICATE_THUMBPRINT }}
run: yarn electron-builder --config --publish always
DEBUG: "electron-notarize*"
# TODO: Fix electron-notarize flakes. The logs above should help gather more data on failures
uses: nick-fields/[email protected]
with:
timeout_minutes: 10
max_attempts: 3
command: yarn electron-builder --config --publish always

- uses: actions/upload-artifact@v4
if: ${{ env.IS_RELEASE == 'true' }}
Expand Down
8 changes: 5 additions & 3 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ permissions:
jobs:

check-rust-changes:
if: github.event.pull_request.draft == false
runs-on: ubuntu-latest
outputs:
rust-changed: ${{ steps.filter.outputs.rust }}
Expand All @@ -35,7 +34,6 @@ jobs:
- 'src/wasm-lib/**'
electron:
if: github.event.pull_request.draft == false
timeout-minutes: 60
name: playwright:electron:${{ matrix.os }} ${{ matrix.shardIndex }} ${{ matrix.shardTotal }}
strategy:
Expand Down Expand Up @@ -129,9 +127,12 @@ jobs:
shell: bash
run: yarn tron:package
- name: Run ubuntu/chrome snapshots
if: ${{ matrix.os == 'namespace-profile-ubuntu-8-cores' && matrix.shardIndex == 1 }}
shell: bash
# TODO: break this in its own job, for now it's not slowing down the overall execution as ubuntu is the quickest,
# but we could do better. This forces a large 1/1 shard of all 20 snapshot tests that runs in about 3 minutes.
run: |
PLATFORM=web yarn playwright test --config=playwright.config.ts --retries="3" --update-snapshots --grep=@snapshot --shard=${{ matrix.shardIndex }}/${{ matrix.shardTotal }}
PLATFORM=web yarn playwright test --config=playwright.config.ts --retries="3" --update-snapshots --grep=@snapshot --shard=1/1
env:
CI: true
NODE_ENV: development
Expand All @@ -152,6 +153,7 @@ jobs:
continue-on-error: true
run: rm -r test-results
- name: check for changes
if: ${{ matrix.os == 'namespace-profile-ubuntu-8-cores' && matrix.shardIndex == 1 }}
shell: bash
id: git-check
run: |
Expand Down
38 changes: 36 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -337,13 +337,47 @@ For individual testing:
yarn test abstractSyntaxTree -t "unexpected closed curly brace" --silent=false
```

Which will run our suite of [Vitest unit](https://vitest.dev/) and [React Testing Library E2E](https://testing-library.com/docs/react-testing-library/intro/) tests, in interactive mode by default.
Which will run our suite of [Vitest unit](https://vitest.dev/) and [React Testing Library E2E](https://testing-library.com/docs/react-testing-library/intro) tests, in interactive mode by default.

### Rust tests

**Dependencies**

- `KITTYCAD_API_TOKEN`
- `cargo-nextest`
- `just`

#### Setting KITTYCAD_API_TOKEN
Use the production zoo.dev token, set this environment variable before running the tests

#### Installing cargonextest

```
cd src/wasm-lib
cargo search cargo-nextest
cargo install cargo-nextest
```

#### just
install [`just`](https://github.com/casey/just?tab=readme-ov-file#pre-built-binaries)

#### Running the tests

```bash
# With just
# Make sure KITTYCAD_API_TOKEN=<prod zoo.dev token> is set
# Make sure you installed cargo-nextest
# Make sure you installed just
cd src/wasm-lib
just test
```

```bash
# Without just
# Make sure KITTYCAD_API_TOKEN=<prod zoo.dev token> is set
# Make sure you installed cargo-nextest
cd src/wasm-lib
KITTYCAD_API_TOKEN=XXX cargo test -- --test-threads=1
export RUST_BRACKTRACE="full" && cargo nextest run --workspace --test-threads=1
```

Where `XXX` is an API token from the production engine (NOT the dev environment).
Expand Down
2 changes: 2 additions & 0 deletions docs/kcl/KNOWN-ISSUES.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,3 +24,5 @@ once fixed in engine will just start working here with no language changes.
chamfer cases work currently.

- **Appearance**: Changing the appearance on a loft does not work.

- **Helix**: Currently sweeping a helix does not work.
42 changes: 42 additions & 0 deletions docs/kcl/circleThreePoint.md

Large diffs are not rendered by default.

41 changes: 26 additions & 15 deletions docs/kcl/helix.md

Large diffs are not rendered by default.

43 changes: 43 additions & 0 deletions docs/kcl/helixRevolutions.md

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions docs/kcl/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ layout: manual
* [`ceil`](kcl/ceil)
* [`chamfer`](kcl/chamfer)
* [`circle`](kcl/circle)
* [`circleThreePoint`](kcl/circleThreePoint)
* [`close`](kcl/close)
* [`cm`](kcl/cm)
* [`cos`](kcl/cos)
Expand All @@ -47,6 +48,7 @@ layout: manual
* [`getOppositeEdge`](kcl/getOppositeEdge)
* [`getPreviousAdjacentEdge`](kcl/getPreviousAdjacentEdge)
* [`helix`](kcl/helix)
* [`helixRevolutions`](kcl/helixRevolutions)
* [`hole`](kcl/hole)
* [`hollow`](kcl/hollow)
* [`import`](kcl/import)
Expand Down Expand Up @@ -80,6 +82,7 @@ layout: manual
* [`pi`](kcl/pi)
* [`polar`](kcl/polar)
* [`polygon`](kcl/polygon)
* [`pop`](kcl/pop)
* [`pow`](kcl/pow)
* [`profileStart`](kcl/profileStart)
* [`profileStartX`](kcl/profileStartX)
Expand Down
2 changes: 1 addition & 1 deletion docs/kcl/mirror2d.md

Large diffs are not rendered by default.

39 changes: 39 additions & 0 deletions docs/kcl/pop.md

Large diffs are not rendered by default.

11 changes: 7 additions & 4 deletions docs/kcl/rem.md

Large diffs are not rendered by default.

Loading

0 comments on commit e82ee3e

Please sign in to comment.