* Revert "Disable text-to-cad tests post kw arg merge (#5252)"
This reverts commit 8a9d50226f.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Fix to invalidate cache when top-level annotations change
* Change to BTreeMap to allow deterministic iteration
* Fix execution cache to look at annotations
* Start implementing a "prepareToEdit" callback for extrude
* Start of generic edit flow for operations
* Actually invoking command bar send generically on double-click
* Refactor: break out non-React hook helper to calculate Kcl expression value
* Add unit tests, fmt
* Integrate helper to get calculated KclExpression
* Clean up unused imports, simplify use of `programMemoryFromVariables`
* Implement basic extrude editing
* Refactor: move DefaultPlanesStr to its own lib file
* Add support for editing offset planes
* Add Edit right-click menu option
* Turn off edit flow for sketch for now
* Add e2e tests for sketch and offset plane editing, fix bug found with offset plane editing
* Add failing e2e extrude edit test
* Remove action version of extrude AST mod
* Fix behavior when adding a constant while editing operation, fixing e2e test
* Patch in changes from 61b02b5703
* Remove shell's prepareToEdit
* Add other Surface types to `artifactIsPlaneWithPaths`
* refactor: rename `item` to `operation`
* Allow `prepareToEdit` to fail with a toast, signal sketch-on-offset is unimplemented
* Rework sketch e2e test to test several working and failing cases
* Fix tsc errors related to making `codeRef` optional
* Make basic error messages more friendly
* fmt
* Reset modifyAst.ts to main
* Fix broken artifactGraph unit test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Remove unused import
* Look at this (photo)Graph *in the voice of Nickelback*
* Make the offset plane insert at the end, not one before
* Fix bug caught by e2e test failure with "Command needs review" logic
* Update src/machines/modelingMachine.ts
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Remove console logs per @pierremtb
* Update src/components/CommandBar/CommandBarHeader.tsx
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Use better programMemory init thanks @jtran
* Fix tsc post merge of #5068
* Fix logic for `artifactIsPlaneWithPaths` post-merge
* Need to disable the sketch-on-face case now that artifactGraph is in Rust. Will active in a future PR (cc @jtran)
* Re-run CI after snapshots
* Update FeatureTreePane to not use `useCommandsContext`, missed during merge
* Fix merge issue, import location change on edited file
* fix click test step, which I believe is waiting for context scripts to load
* Convert toolbarFixture.exeIndicator to getter
We need to convert all these selectors on fixtures to getters, because
they can go stale if called on the fixture constructor.
* Missed a dumb little thing in toolbarFixture.ts
* Fix goof with merge
* fmt
* Another dumb missed thing during merge
I gotta get used to the LazyGit merge tool I'm not good at it yet
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Conver sceneFixture's exeIndicator to a getter
Locators on fixtures will be frozen from the time of the fixture's
initialization, I'm increasingly convinced
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Post-kwargs E2E test cleanup
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Update gizmo e2e flow test camera values
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Disable snapshot commit bot on main
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Restrict snapshot bot git add dir
* Clean up sanps
* Other git add .
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Clean up after bot (bad bot)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Remove -a from -am
* Clean up
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
A few issues:
- There was no description of how `|>` works
- Need to explain our keyword arguments implementation
- It was using old syntax for `angledLine` which now takes an object as its first parameter, not an array
* Move Helix button to a section with offset plane (3d 'construction' elements)
Fixes#5234
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Release new kcl-lib and derive-docs
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* cargo update, etc
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor execution/mod.rs (code motion)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor caching out of ExecutorContext plus some tidying up
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Move caching logic to inside execution
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Bump vitest to 1.6.1 and 2.1.9
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bad bot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* WIP: allow snapshot bot to trigger CI
* To revert: change toolbars button order to trigger snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Revert "To revert: change toolbars button order to trigger snapshots"
This reverts commit d6e2550921.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Clean up identical snaps
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bad bot
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* WIP: disable more tests
* Fix lint and add 2 windows skips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Two more skips on win
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* More skips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* More skips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* More skips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* One more skip
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* More skips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Replace many win32 skips with tag @skipWin
* More clean upp
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Part of #4600.
PR: https://github.com/KittyCAD/modeling-app/pull/4826
# Changes to KCL stdlib
- `line(point, sketch, tag)` and `lineTo(point, sketch, tag)` are combined into `line(@sketch, end?, endAbsolute?, tag?)`
- `close(sketch, tag?)` is now `close(@sketch, tag?)`
- `extrude(length, sketch)` is now `extrude(@sketch, length)`
Note that if a parameter starts with `@` like `@sketch`, it doesn't have any label when called, so you call it like this:
```
sketch = startSketchAt([0, 0])
line(sketch, end = [3, 3], tag = $hi)
```
Note also that if you're using a `|>` pipeline, you can omit the `@` argument and it will be assumed to be the LHS of the `|>`. So the above could be written as
```
sketch = startSketchAt([0, 0])
|> line(end = [3, 3], tag = $hi)
```
Also changes frontend tests to use KittyCAD/kcl-samples#139 instead of its main
The regex find-and-replace I use for migrating code (note these don't work with multi-line expressions) are:
```
line\(([^=]*), %\)
line(end = $1)
line\((.*), %, (.*)\)
line(end = $1, tag = $2)
lineTo\((.*), %\)
line(endAbsolute = $1)
lineTo\((.*), %, (.*)\)
line(endAbsolute = $1, tag = $2)
extrude\((.*), %\)
extrude(length = $1)
extrude\(([^=]*), ([a-zA-Z0-9]+)\)
extrude($2, length = $1)
close\(%, (.*)\)
close(tag = $1)
```
# Selected notes from commits before I squash them all
* Fix test 'yRelative to horizontal distance'
Fixes:
- Make a lineTo helper
- Fix pathToNode to go through the labeled arg .arg property
* Fix test by changing lookups into transformMap
Parts of the code assumed that `line` is always a relative call. But
actually now it might be absolute, if it's got an `endAbsolute` parameter.
So, change whether to look up `line` or `lineTo` and the relevant absolute
or relative line types based on that parameter.
* Stop asserting on exact source ranges
When I changed line to kwargs, all the source ranges we assert on became
slightly different. I find these assertions to be very very low value.
So I'm removing them.
* Fix more tests: getConstraintType calls weren't checking if the
'line' fn was absolute or relative.
* Fixed another queryAst test
There were 2 problems:
- Test was looking for the old style of `line` call to choose an offset
for pathToNode
- Test assumed that the `tag` param was always the third one, but in
a kwarg call, you have to look it up by label
* Fix test: traverse was not handling CallExpressionKw
* Fix another test, addTagKw
addTag helper was not aware of kw args.
* Convert close from positional to kwargs
If the close() call has 0 args, or a single unlabeled arg, the parser
interprets it as a CallExpression (positional) not a CallExpressionKw.
But then if a codemod wants to add a tag to it, it tries adding a kwarg
called 'tag', which fails because the CallExpression doesn't need
kwargs inserted into it.
The fix is: change the node from CallExpression to CallExpressionKw, and
update getNodeFromPath to take a 'replacement' arg, so we can replace
the old node with the new node in the AST.
* Fix the last test
Test was looking for `lineTo` as a substring of the input KCL program.
But there's no more lineTo function, so I changed it to look for
line() with an endAbsolute arg, which is the new equivalent.
Also changed the getConstraintInfo code to look up the lineTo if using
line with endAbsolute.
* Fix many bad regex find-replaces
I wrote a regex find-and-replace which converted `line` calls from
positional to keyword calls. But it was accidentally applied to more
places than it should be, for example, angledLine, xLine and yLine calls.
Fixes this.
* Fixes test 'Basic sketch › code pane closed at start'
Problem was, the getNodeFromPath call might not actually find a callExpressionKw,
it might find a callExpression. So the `giveSketchFnCallTag` thought
it was modifying a kwargs call, but it was actually modifying a positional
call.
This meant it tried to push a labeled argument in, rather than a normal
arg, and a lot of other problems. Fixed by doing runtime typechecking.
* Fix: Optional args given with wrong type were silently ignored
Optional args don't have to be given. But if the user gives them, they
should be the right type.
Bug: if the KCL interpreter found an optional arg, which was given, but
was the wrong type, it would ignore it and pretend the arg was never
given at all. This was confusing for users.
Fix: Now if you give an optional arg, but it's the wrong type, KCL will
emit a type error just like it would for a mandatory argument.
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Kevin Nadro <kevin@zoo.dev>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Turn off snapshot commit bot
Our team is actively investigating a recent spike in flaky WebRTC
connection behavior, which has impacted the web-only Playwright snapshot
tests particularly hard. The bot squashes other GH Actions in it's wake,
so I think we should turn it off so we can see the other E2E tests more
clearly
* Revert "Turn off snapshot commit bot"
This reverts commit ab80bdb08a.
* Revert "Turn off snapshot commit bot"
This reverts commit ab80bdb08a.
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* Test main e2e
* Create projects separately in home page tests
I think creating them in Promise.all was introducing nondeterminism and
making tests flaky.
* Query the homepage projects in an order-insensitive way
* Wait for ICE candidate gathering to complete before requesting video track
* Update src/lang/std/engineConnection.ts
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Fix create file e2e failure
* Yarn fmt
* Fix typo: s/that/this
yarn tsc was failing with this error:
```
src/lang/std/engineConnection.ts:1285:7 - error TS2304: Cannot find name 'that'.
1285 that.triggeredStart = false
~~~~
```
* Fix up revolve tests
* Turn off 3 flaky Windows tests
* Fix tags
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* ast mod
* point and click test
* tsc
* test test
* unit test edit
* topLevelRange
* disable unit test
* remove bad imports
* fix typo
* Fix cyclic dependency hell with getNodePathFromSourceRange
* tsc
* fix ImportStatement
* fix isValueZero
* pre-emptively ==> preemptively
* yarn fmt-check
* reenable the unit test
* fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* add test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* several treatments
* consolidate
* typos
* fix imports, consolidate
* consolidate import
* fix imports
* add tests
* stress test CI
* fix test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* fix tests
* clean test for fillets
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* test chamfers
* comments
* simplify main tests
* typo
* typo2
* remove import
* clean up comments
---------
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* WIP: Turn on link sharing in released apps with electron-builder
Fixes#5136
* Add import.meta.env defaults
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Add convenience scripts for windows development; fix protocol name for electron; enable share cmd
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Force release builds
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Fix lint
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* CSC_FOR_PULL_REQUEST: true for release build testing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Adding ://
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Back to debug builds
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Back to debug builds
* WIP: origin
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* To revert: Add logs and custom package version for easier testing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* More messing with env vars
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Messing with help from deep links docs
* Removed alerts
* Working on macos
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Working second window on windows. Cold start not yet working
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Handle windows cold start
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Clean up after macos testing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Replace tron:package (Forge) with tronb📦dev (Builder) for e2e
* Add new env var for web app link
* tronb:vite:dev for e2e
* Remove app.requestSingleInstanceLock() call
* Fix unit test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Revert snap changes
* Only nightly at first
* Remove test app
* Update package.json
* Update src/main.ts
* Remove fetch:wasm:windows
* Final line
* Clean up
* Back to test app for final test
* Fix tsc
* Back to https://app.dev.zoo.dev from vercel branch deploy
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add a setting that does nothing
* Make the setting actually change the interaction type
* fmt
* Bump `@kittycad/lib` to get the proper camera drag interaction types
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Fix camera orientation bugs to support proper camera resetting on "camera orbit" setting change (#5031)
* Add a setting that does nothing
* Make the setting actually change the interaction type
* fmt
* fix: up vector bug fix and camera reset fix. Pushing code to cleanup after debugging
* fix: deleting debugging code
* fix: removing debugging code
* fix: removing debugging console log
* fix: removing console log debugs
* fix: adding comment, restoring code from debugging
* fix: removed lookAt when the orientation is already set from the engine.. I do not think we should be recomputing it?
* fix: this fixes the bug because I was pointing to the getter not the value
* Remove unused imports
* Fix lint for unawaited Promise
* Remove pointless change
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Frank Noirot <frankjohnson1993@gmail.com>
* Re-run CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Re-run CI
* Add display attributes to try to fix cargo test
* Remove backwards compat test case
it's failing because I didn't add cameraOrbit to that type and I don't
want to
* Fix test value (prev user value would have been Spherical before Trackball)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kevin Nadro <nadr0@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* feature: implemented saving thumbnail.png to have project thumbnails in the home page
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* Fix the failing test by increasing window height (related to toast covering now-larger project tiles)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Make point-and-click Sweep generally available
Fixes#5156
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Remove replace /segment/face
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Selections change will be done in separate PR #5183
* Toolbar button
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Reset snaps
* Revert screenshot
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add testing the artifact graph snapshots when there's an execution error
* Update output to check artifact graph in error cases
* Rename helper function to be clearer
* Add test that has meaningful output, followed by an error
* Fix the '1 face' mislabelling of selection for sweep segments
Fixes#5182
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Reset snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Fix lint
* Revert snap
* Fix chamfer and fillet test selection
* Fix other test
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: adding unit test to test the parsing of the code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* chore: trying to console error more content for getNodeByPath since it is cryptic
* fix: removing testing unit test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fix: fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* fix: ...
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* fix: found da bug
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add engine message to dry run validation error toasts
Fixes#5174
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Add unit tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Reset snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Revert snapshot changes
* Fix lint
* Fix test
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Create a global appMachine
* Strip authMachine of side-effects
* Replace react-bound authMachine use with XState actor use
* Fix import goof
* Register auth commands directly!
* @lf94 feedback: conver `AuthNavigationHandler` to `useAuthNavigation`
* Uh, fix signing out thank you @lf94
* Fix tsc
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)"
This reverts commit 8dc50b6a26.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Migrate Extrude AST mod from XState action to actor
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* @lf94 feedback
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Amend project open test to show failing case
* Fix command config to use live context value
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Update src/lib/commandBarConfigs/projectsCommandConfig.ts
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Our team is actively investigating a recent spike in flaky WebRTC
connection behavior, which has impacted the web-only Playwright snapshot
tests particularly hard. The bot squashes other GH Actions in it's wake,
so I think we should turn it off so we can see the other E2E tests more
clearly
* fix: new Literal data structure update
* fix: updated the LiteralValue dereferencing and added some type narrowing helpers
* fix: updating formatting
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fix: implementing a safer dereference method until we update createLiteraly()
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* why is this fallback here
* fix: updating the type narrowing function
* fix: restore this... see if snapshots trigger again
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump
* bump
* Add number with units formatting as KCL (#5195)
* Add number with units formatting as KCL
* Change type assertion helper to check what we need
* Fix rectangle unit test
* fix: adding a wait for execution to prevent clicking before lines are rendered
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* fix: clear the previous DOM elements after page redirect
* fix: removed await delay since it can take awhile to destroy the sketch
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fix: added E2E test which actually caught a logic bug, moved the logic to the correct location
* fix: removing unused import
* fix: push main back...
* fix: restoring code to old state
* fix: moved cleanup code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Improve checking of import paths
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Import path kinds in AST
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Use import statement for foreign files
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor getNodePathFromSourceRange
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Add in a Node::ptr_eq helper
This looks a bit gross (I get it), but it's helpful when walking the
tree. It means we can construct nodes (via `into`) of borrows, and later
check to see if it's the same borrow later on if we need to walk the
tree multiple times or otherwise maintainer a pointer to a specific AST
entry.
The idea here is you could collect nodes, then traverse the tree again,
and know when you've reached the exact same node again.
* Rename `homeMachine` and accessories to `projectsMachine`
* Separate out `/home` route from `projectsMachine`
* Add logic to navigate out from deleted or renamed project
* Show a warning in the command palette for deleting a project
* Make it navigate when you create a project
* Update "New project" button to use command bar flow
Closes#2585
* More explicit warning message text
* Make projects watching code not run in web
* Tests first version: nested loops
* Tests second version: flattened
* Remove console logs
* Fix tsc
* @jtran feedback, use the type guard util
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Fix tests that relied on one-click, no-navigation project creation
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 7545b61b49.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 3d2e48732c.
* Add a mask to the state indicator to client-side scale test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix lint
* Fix tsc
* Add menu item to share link to file
* Forward query params while redirecting to /home or /file
* Add (broken) event logic and command triggering logic
* Fix a couple stray tests that still relied on the old way of creating projects
* De-flake another text that could be thrown off by toast-based selectors
* FMT
* Dumb test error because I was rushing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Ahhh more flaky toasts, they're everywhere!
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Side quest: Only register commands once, power their disabled status while selecting commands via optional actor
* Get query-triggered command working in browser too
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Tests always run on localhost, don't expect the prod origin
* rerun CI
* wip
* wip
* Everything's pretty much done but url.zoo.dev has been broken and we need to think about how to test reliably
* Merge branch 'main' into franknoirot/4088/create-file-url
* Add useCreateFileLinkQuery on Home page
* Get primary user flow working on desktop
* Rework to open browser app first, then send along to the desktop app if asked
* Styling updates to OpenInDesktopAppHandler
* Clean up unecessary file
* Merge branch 'main' into franknoirot/4088/create-file-url
* Separate creating `createFileUrl` and shortlink so it is unit testable
* Add E2E test for importing file from URL
* Add a couple component tests for OpenInDesktopAppHandler
* Fix the "existing project" user flow
* Add E2E test for "add to existing project" user flow
* Undo mistaken or unecessary changes
* Lints, fmt, tsc
* Fix unit test
* Fix broken rename and delete project commands
Something about the `optionsFromContext` config no longer works with file I/O-related commands. I suspect this has to do with our read/write loop patching
* Fix unit test, use kebab-case for url query param
* Use dev urls everywhere when configured that way
I think we were just using some constants that ended up returning bad
values for dev, it seemed to return a working shortlink when I went
through the flow.
* Clean up unneeded PROD_TOKEN
* Fix browser command flow, because we had made the projectMachine desktop-only on main
* Make the test executor a bit more patient (#5004)
* Fix so that all artifact commands are returned regardless of caching (#5005)
* Fix so that all artifact commands are returned regardless of caching
* Add some more docs and fix up old ones
* Add new lint to disallow use of confusing isNaN (#4999)
* Point-and-click Sweep (first PR) (#4989)
* Refactor 'Delete selection' as actor
Will fix#4662
* WIP logging
* WIP: working Solid3dGetExtrusionFaceInfo for loft
* Working wall deletion of loft
* Add offset plane deletion
* Add feature tree deletion of shell
* Clean up
* Revert "Clean up"
This reverts commit 214763cc2b.
* Clean up rust changes, taking the sketch with the most paths
* Working cap selection and deletion
* Clean up
* Add test for loft and offset plane deletion via selection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Set reenter: false as it was originally
* Passing test
* Add shell deletion via feature tree test
* Revert the migration to promise actor
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Use cmd.id as solid_id after latest engine merge
* Add feature tree deletion of offset plane and fix lint
* Add feature tree deletion of loft
* Clean up
* Better comment
* Lint fix
* Remove sketch sorting
* WIP: sweep point-and-click
* Working sweep
* Add test
* Make sweep a development command
* Fix tsc error
* Clean up for review
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Upgrade typescript-eslint from 5.62.0 to 8.19.1 and remove eslint-config-react-app (#5006)
* Fix lost lints and add new ones (#5011)
* Add eslint-plugin-jsx-a11y dependency
* Add jsx-a11y lint
* Add eslint-plugin-react-hooks dependency
* Add react hooks lints
* Ignore new react hooks lint in tests
* Add eslint-plugin-testing-library dependency
* Add testing-library lint
* Fix yarn lint to use all files recursively
* Developer workflow: added auto generated workspace file from vitest extension in vscode (#4997)
* chore: added auto generated workspace file from vitest extension in vscode
* fix: auto fmt fixes
* Change Dependabot PRs to always be made on Mondays (#5025)
* Add packages to Dependabot updates (#5024)
* Bump @lezer/generator from 1.7.1 to 1.7.2 (#5018)
Bumps [@lezer/generator](https://github.com/lezer-parser/generator) from 1.7.1 to 1.7.2.
- [Changelog](https://github.com/lezer-parser/generator/blob/main/CHANGELOG.md)
- [Commits](https://github.com/lezer-parser/generator/compare/1.7.1...1.7.2)
---
updated-dependencies:
- dependency-name: "@lezer/generator"
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump handlebars from 6.2.0 to 6.3.0 in /src/wasm-lib (#5012)
Bumps [handlebars](https://github.com/sunng87/handlebars-rust) from 6.2.0 to 6.3.0.
- [Release notes](https://github.com/sunng87/handlebars-rust/releases)
- [Changelog](https://github.com/sunng87/handlebars-rust/blob/master/CHANGELOG.md)
- [Commits](https://github.com/sunng87/handlebars-rust/compare/v6.2.0...v6.3.0)
---
updated-dependencies:
- dependency-name: handlebars
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump syn from 2.0.95 to 2.0.96 in /src/wasm-lib (#5015)
Bumps [syn](https://github.com/dtolnay/syn) from 2.0.95 to 2.0.96.
- [Release notes](https://github.com/dtolnay/syn/releases)
- [Commits](https://github.com/dtolnay/syn/compare/2.0.95...2.0.96)
---
updated-dependencies:
- dependency-name: syn
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Fix artifact types to be more accurate (#5022)
* Fix Cargo.lock to not have changes (#5034)
* Upgrade all wasm-bindgen dependencies together (#5037)
* Disable auto-updater on non-versioned builds (#5042)
* turns on helix from edge (#5036)
* updates for new lib
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* autocomplete
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* bump version
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* bump all the things
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* new samples
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* docs
Signed-off-by: Jess Frazelle <github@jessfraz.com>
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* ci: Add yarn test of packages/codemirror-lang-kcl (#5035)
* ci: Add yarn test of packages/codemirror-lang-kcl
* Fix CI error running tests
* Fix postcss config error
* Bump xstate from 5.17.4 to 5.19.2 (#5027)
* Hook up chamfer UI with AST-mod (#4694)
* button
* config
* hook up with ast
* cmd bar test
* button states fix and test
* little naming fix
* xState action to actor
* remove button state test updates
* fixture-based approach
* nightly
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update src/lib/toolbar.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Remove Redundant Fillet Button State Test (#5009)
delete obsolete test
* Bump @types/node from 20.14.9 to 22.10.6 in /packages/codemirror-lsp-client (#5041)
* custom axis and origin example for helix (#5057)
* custom axis and origin for helix
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* empty
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Bump typescript from 5.7.2 to 5.7.3 (#5021)
Bumps [typescript](https://github.com/microsoft/TypeScript) from 5.7.2 to 5.7.3.
- [Release notes](https://github.com/microsoft/TypeScript/releases)
- [Changelog](https://github.com/microsoft/TypeScript/blob/main/azure-pipelines.release.yml)
- [Commits](https://github.com/microsoft/TypeScript/compare/v5.7.2...v5.7.3)
---
updated-dependencies:
- dependency-name: typescript
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Refactor: break out `copyFileShareLink` into standalone function
* Add "Share file" to command palette
* Update dumb use of site URL instead of prod app URL
* fmt
* @lf94 nit
* @pierremtb spinner feedback
* Hide share link command and disable menu item for now
* Just comment out the command config for now
---------
Signed-off-by: dependabot[bot] <support@github.com>
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: Adam Sunderland <iterion@gmail.com>
Co-authored-by: Adam Sunderland <adam@kittycad.io>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Kevin Nadro <nadr0@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: max <margorskyi@gmail.com>
* fix: positioning of the badge for the sidebar buttons
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* bump since image is wrong
* bump since image is wrong
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* WIP: pw log error only
* Force tests to run on branch
* Remove all page.on('console', console.log)
* Remove context.console too
* Add --quiet flag
* Revert useless changes
* Supress stdio logs on e2e tests in CI
* fix: fixed selection range issue when doing a constraint when the KCL editor is closed
* fix: linter and tsc errors
* fix: trying to reuse logic instead?
* fix: removed console log
* Extra padding on 'Load a sample model' menu item
Fixes#5047
* Update src/components/ModelingSidebar/ModelingPanes/KclEditorMenu.module.css
Co-authored-by: Frank Noirot <frank@zoo.dev>
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Add dry-run validation for Sweep
Fixes#5095
* Add sweep test failing validation
* Make naming more consistent with engine
* Fix tests after big rename
* Fix tsc after main merge
* Separate content from ToolbarItemTooltip, make simple and "rich" versions
* Add support for dropdown-arrow-only tooltip
* Add toolbar-wide hover timeouts and clears to switch between simple and rich tooltips
* Fix the dropdown arrow button hover styling now that they're separate
* Add missing doc links to rich toolbar tooltips
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Re-run CI after snapshots
* fix codespell
* fmt
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Make all geometry KclValue variants into struct variants
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add units to geometry types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Show toolbar tooltips on hover only, hide when dropdowns are open
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Re-run CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix dumb mistake in command flow for #5083
* Add e2e test for creating projects with the default interpolated name
* Drop that number to 12 ain't got all day
* Why do I have a kcl-samples submodule hanging around?
* Empty commit to remove the submodule
We don't get much value from these, we can always run criterion or valgrind locally.
If we want to measure instruction counts, we should be using codspeed.io instead because
they support visualizing and tracking over time.
If we want to track performance over time we should be using Kevin's perf monitor machine.
* Add failing playwright test
* Make create generate a unique name if the given one collides
* Add a new consolidated getUniqueProjectName function with tests
* Use getUniqueProjectName
* Replace "New project" button text with "Create project"
cc @pierremtb
* Extend the e2e test to show the incrementing behavior
cc @lf94
* Start porting artifact graph creation to Rust
* Add most of artifact graph creation
* Add handling loft command from recent PR
* Refactor artifact merge code so that it errors when a new artifact type is added
* Add sweep subtype
* Finish implementation of build artifact graph
* Fix wasm.ts to use new combined generated ts-rs file
* Fix Rust lints
* Fix lints
* Fix up replacement code
* Add artifact graph to WASM outcome
* Add artifact graph to simulation test output
* Add new artifact graph output snapshots
* Fix wall field and reduce unreachable code
* Change field order for subtype
* Change subtype to be determined from the request, like the TS
* Fix plane sweep_id
* Condense code
* Change ID types to be properly optional
* Change to favor the new ID, the same as TS
* Fix to make error impossible
* Rename artifact type tag values to match TS
* Fix name of field on Cap
* Update outputs
* Change to use Rust source range
* Update output snapshots
* Add conversion to mermaid mind map and add to snapshot tests
* Add new mermaid mind map output
* Add flowchart
* Remove raw artifact graph from tests
* Remove JSON artifact graph output
* Update output file with header
* Update output after adding flowchart
* Fix flowchart to not have duplicate edges, one in each direction
* Fix not not output duplicate edges in flowcharts
* Change flowchart edge style to be more obvious when a direction is missing
* Update output after deduplication of edges
* Fix not not skip sketch-on-face artifacts
* Add docs
* Fix edge iteration order to be stable
* Update output after fixing order
* Port TS artifactGraph.test.ts tests to simulation tests
* Add grouping segments and solid2ds with their path
* Update output flowcharts since grouping paths
* Remove TS artifactGraph tests
* Remove unused d3 dependencies
* Fix to track loft ID on paths
* Add command ID to error messages
* Move artifact graph test code to a separate file since it's a large file
* Reduce function visibility
* Remove TS artifact graph code
* Fix spelling error with serde
* Add TODO for edge cut consumed ID
* Add comment about mermaid edge rank
* Fix mermaid flowchart edge cuts to appear as children of their edges
* Update output since fixing flowchart order
* Fix to always build the artifact graph even when there's a KCL error
* Add artifact graph to error output
* Change optional ID merge to match TS
* Remove redundant SourceRange definition
* Remove Rust-flavored default source range function
* Add helper for source range creation
* Update doc comment for the website
* Update docs after doc comment change
* Fix to save engine responses in execution cache
* Remove unused import
* Fix to not call WASM function before beforeAll callback is run
* Remove more unused imports
* WIP: mess with shell selection validation
Will eventually fix#4711
* Update from main
* WIP: not working yet
* Working loft dry run validator
* Clean up shell (still not working)
* Bump kittycad-modeling-cmds
* Clean up
* Add logging
* Add proper object_id and face_id mapping, still not working for shell
* Fix faceId
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Working validation after engine merge; Clean up
* Fix codespell
* Add pw test
* More clean up
* Back to basics
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Clean up
* Fix tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Remove kcl-samples
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* add locator
* new test
* remove old test
* separation of setup steps
* improved click reliability
* fix ubuntu
* ubuntu fix 2
* ubuntu fix 3
* flaky cmdbar ubuntu
* ubuntu fix second yellow
* ubuntu update
* enable test for windows
* step(Initial test setup)
* extra await, just in case
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* screenshot
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Use the project default units for the per-file unit default values
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Use per-file units in conversion functions
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* feat: enable/disable free camera aka allow orbit in sketch mode mvp
* fix: removing comments
* fix: logic for enabling and disabling in and out of sketch mode
* fix: fmt, linter, tsc fixes
* fix: added comment
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fix: current,prev check to no op the useeffect if the values are the same
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Make "Find and select command" global to commandBarMachine
* Make commands not removed based on their actor state, only disabled
* Sort commands better in CommandComboBox
* Break out sort logic, add a few unit tests
* Fix missed name change
* Needed to make one more change from source branch:
since `optionsFromContext` now only gets fired once, I/O-based options need to use the `options` config instead.
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Add dragging behavior to 3 point circle
Uses our talked about technique of calling Rust functions to calculate new
geometry coordinates and parameters. It works very well!
Need to have the modeling app show "edit sketch" still.
* Cargo fmt
* cargo fmt
* Address Jon's comments
* Fix clippy
* Dont use isNaN
* Make points easier to select (enlarge)
* Fix circle button not being activated
* Ensure efficiency of updating editor vs execution
* Make cargo clippy happy
* Add icon
* Add to stdLibMap
* Add to toolbar as "kcl-only"
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* Use std deprecation for int rather than a hack in the parser
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Don't allow an epsilon when converting floats to ints for property access
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fixup tests
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fix our golden standard tests (broken by new assemblies kcl-samples)
* Finally use the right combination of env vars
* Fix the manifest
* Continue to fix multiple file kcl-samples
* Fix loading in desktop app
* Type narrow for tsc
* fmt
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
* button
* config
* hook up with ast
* cmd bar test
* button states fix and test
* little naming fix
* xState action to actor
* remove button state test updates
* fixture-based approach
* nightly
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update src/lib/toolbar.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Refactor 'Delete selection' as actor
Will fix#4662
* WIP logging
* WIP: working Solid3dGetExtrusionFaceInfo for loft
* Working wall deletion of loft
* Add offset plane deletion
* Add feature tree deletion of shell
* Clean up
* Revert "Clean up"
This reverts commit 214763cc2b.
* Clean up rust changes, taking the sketch with the most paths
* Working cap selection and deletion
* Clean up
* Add test for loft and offset plane deletion via selection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Set reenter: false as it was originally
* Passing test
* Add shell deletion via feature tree test
* Revert the migration to promise actor
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Use cmd.id as solid_id after latest engine merge
* Add feature tree deletion of offset plane and fix lint
* Add feature tree deletion of loft
* Clean up
* Better comment
* Lint fix
* Remove sketch sorting
* WIP: sweep point-and-click
* Working sweep
* Add test
* Make sweep a development command
* Fix tsc error
* Clean up for review
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* feat: implemented axis or edge selection workflow in the commandbar
* fix: removing comment
* fix: removing console logs from testing
* fix: fixing lint and tsc errors
* fix: changed copy
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* [BUG] Shell point and click references the wrong feature
Fixes#4961
* Add test for sketch on face based on extrudes in pipe
* Add no extrude in pipe case
* Lint
* Add scene.waitForExecutionDone()
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Update src/lang/modifyAst/addShell.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Refactor 'Delete selection' as actor
Will fix#4662
* WIP logging
* WIP: working Solid3dGetExtrusionFaceInfo for loft
* Working wall deletion of loft
* Add offset plane deletion
* Add feature tree deletion of shell
* Clean up
* Revert "Clean up"
This reverts commit 214763cc2b.
* Clean up rust changes, taking the sketch with the most paths
* Working cap selection and deletion
* Clean up
* Add test for loft and offset plane deletion via selection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Set reenter: false as it was originally
* Passing test
* Add shell deletion via feature tree test
* Revert the migration to promise actor
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* Trigger CI
* Use cmd.id as solid_id after latest engine merge
* Add feature tree deletion of offset plane and fix lint
* Add feature tree deletion of loft
* Clean up
* Better comment
* Lint fix
* Remove sketch sorting
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add Rust side artifacts for startSketchOn face or plane
* Add Rust-generated artifacts to ExecOutcome
* Add output of artifact commands
* Add new output files
* Wire the artifact commands to the artifact graph creation
* Fix to use real PartialEq implemented in modeling commands
* Fix modeling commands with zero fields to work
* Fix missing artifactCommands field in errors
* Change artifact graph to be built from artifact commands
* Wire up ExecState artifacts, but not using them yet
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Remove unneeded local var
* Fix test to fail with a helpful error message when command isn't found
* Rename and deprecate orderedCommands
* Update comment about borrowing
* Move ArtifactCommand tracking to the EngineManager trait
* Update artifact commands since tracking in the engine
* Upgrade kittycad-modeling-cmds from 0.2.85 to 0.2.86
* Remove unneeded JsonSchema derive to speed up build
* Fix to not fail on floating point differences in CI
* Update artifact commands output since truncating floating point numbers
* Fix to ensure artifact commands get cleared after a clear scene
* Update artifact commands snapshot after clearing them on clear scene
* Remove all remnants of OrderedCommands
* Update output for new simulation tests
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Skip the out/ directory produced by yarn tron:package
* Skip all dist/ dirs
Produced when building rollup packages like codemirror-lang-kcl.
* Skip typescript build info
* Fix typo instead of excluding file
---------
Co-authored-by: Matt Mundell <matt@mundell.me>
* chore: skeleton code to initialize and detect the global WASM panic
* chore: implementing a reimport method to fix the wasm instance being bricked
* fix: cleaning up tsc/lint
* fix: renaming file to be more accurate
* fix: added toast message
* fix: types...
* fix: typed the functions with arg spreads
* fix: Hook into markdown-generated anchors to avoid e.g breaking the desktop app
* add comment
* Disable eslint on copied line from ts-stack
---------
Co-authored-by: marc2332 <mespinsanz@gmail.com>
* Add failing test for current behavior
* Change stream behavior so that stream is played regardless of `isExecuting`
* Change expected pixel color
* Widen possible pixel color diff because local and CI produce slightly different colors
* general clean up
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* implementing naive array pop
* multi-profile follow up. (#4802)
* multi-profile work
* fix enter sketch on cap
* fix coderef problem for walls and caps
* allow sketch mode entry from circle
* clean up
* update snapshot
* Look at this (photo)Graph *in the voice of Nickelback*
* trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* add test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix how expression index is corrected, to make compatible with offset planes
* another test
* tweak test
* more test tweaks
* break up test to fix it hopfully
* fix onboarding test
* remove bad comment
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* get ready to bump (kcl-lib and friends) world (#4794)
get ready to bump world
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* Revert multi-profile (#4812)
* Revert "multi-profile follow up. (#4802)"
This reverts commit 2b2ed470c1.
* Revert "multi profile (#4532)"
This reverts commit 04e586d07b.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Re-run CI after snapshots
* Re-run CI after snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Re-run CI after snapshots
* Add `fixme` to onboarding test
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add tracking of operations for the feature tree (#4746)
* Add operations tracking for the timeline
* Change to only track certain stdlib functions as operations
* Update gen files
* Add operations to simulation snapshot tests
* Add tracking of positional function calls
* Fix generated field names to be camel case in TS
* Fix generated TS field names to match and better docs
* Fix order of ops with patternTransform
* Fix sweep to be included
* Add new expected test outputs
* Add tracking for startSketchOn
* Update ops output to include startSketchOn
* Fix serde field name
* Fix output field name
* Add tracking of operations that fail
* Add snapshots of operations even when there's a KCL execution error
* Add ops output for error executions
* Add operations output to executor error
* Update op source ranges
* Remove tracking of circle() and polygon() since they're not needed
* Update output without circle and polygon
* Fix to track patternCircular3d and patternLinear3d
* Remove tracking for mirror2d
* Update ops output
* Fix to track the correct source range of function definitions
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Change KCL completion to use new object/record syntax (#4815)
* Reserve syntax for units of measure (#4783)
* Allow underscores but only for un-referenced names
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Support numeric suffixes for UoM types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* UoM type arguments
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* warnings -> non-fatal errors
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* type ascription
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Whole module imports (#4767)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Support completions from import statements (#4768)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Implements boolean logical and/or in kcl (#4678)
* redoing bool logic impl on latest main
* adding snapshot tests (removing .new)
* removing accidental change smh:(
* accepting client side scene snapshot
* accepting png snapshot and triggering ci
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* accepting png again?
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting grid visibility snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting png snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting png snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* accepting png snapshot
* rerunning simtest creation to get ops.snap files
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Annotations syntax and per-file default units preparatory work (#4822)
* Parse annotations
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Propagate settings from annotations to exec_state
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* KCL: Unlabeled first param defaults to % (#4817)
Part of #4600
KCL functions can declare one special argument that doesn't require a label on its parameter when called.
This PR will default that arg to % (the current pipeline) if not given.
* Deprecate startSketchAt() stdlib function (#4819)
* Deprecate startSketchAt() stdlib function
* Remove uses of startSketchAt() from the doc tests
* Update docs
* Add dry-run validation for Loft (#4820)
* WIP: mess with shell selection validation
Will eventually fix#4711
* Update from main
* WIP: not working yet
* Working loft dry run validator
* Clean up shell (still not working)
* Bump kittycad-modeling-cmds
* Clean up
* Add logging
* Add proper object_id and face_id mapping, still not working for shell
* Fix faceId
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Add dry-run validation to Loft
Checks one box for #4711
* Add extra check for non solid2ds
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Double click label on sketch to dimension (#4816)
* feat: double click segment label to dimension length, POC, need to clean up code!
* fix: cleaning up the PR for review
* fix: cleaning for the PR. Adding more comments and moving some logic
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: mergining main, auto linter and tsc fixes. Need to make some more
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: tsc errors are resolved
* chore: added test for constraint
* fix: fixing overlay bug since length labels can now be clicked.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* KCL: Show beautiful Miette errors when a KCL example test fails (#4829)
* KCL: Show beautiful Miette errors when a KCL example test fails
Background: KCL example tests are generated from the stdlib KCL examples in the `#[stdlib]` macro in derive-docs.
Problem: When these tests fail, they output a really unhelpful error message like Kcl(Semantic(KclErrorDetails { source_ranges: [156, 160, 0], message: "Expected a sketch but found array" } )).
Solution: Use miette. Now the errors highlight the KCL code that failed and show exactly what went wrong, on which line, presenting nice diagnostics that look like cargo/rustc output.
* Update helix snapshots
* Move all tests over to electron (#4484)
* Move all tests over to electron
* Pass the correct param to playwright-electron.sh
* Add shebang to script and add macos-14-large as a target
* Get sketch-tests.spec.ts passing in electron
* Try out 4 workers
* Got testing-segment-overlays passing
* Pass testing-selections.spec.ts
* Go back to fix up sketch-tests test
* Pass various.spec.ts, by far the hardest one
* Pass can-sketch-on-all-planes... with ease
* Pass command bar tests
* fmt
* Completely fix code mirror text navigating for tests
* Pass debug pane tests
* Pass desktop export tests
* Pass editor tests
* Pass file tree tests
* Pass onboarding tests
* Corrected a fixme in file-tree.spec!
* Painfully fix hardcoded coordinates in point-click.spec
* Pass machine.spec tests
* Pass projects, fought hard with filechooser
* Pass regresion-tests.spec tests
* Pass network and connection tests
* Pass camera-movement.spec tests
* Extreme time eaten by gizmo test fixes. All passing now.
* Merge main (tests changed x_x) and pass all constraints.spec tests (pain)
* Pass another painful spec suite: testing-settings
* Pass perspective-toggle, interesting note
* Pass samples loading tests
* Pass app header tests
* Pass text-to-cad tests
* Pass segment-overlays (minor ache) and ability to switch to web if needed :)
* Fix a ton of syntax changes and deflake 2 more tests (pain)
* Correct all tsc errors
* Remove to-electron script
* Add an f-ton of shit because playwright doesnt want S P R E A D
* Try CI again
* Stop snapshots of exports (already test in e2e)
* Fix flake in double click editor
* Hopefully help CI flake
* Fixmes, fixmes everywhere
* One more fixme to settings
* Skip another code pane flake
* Port jess's projects.spec tests
* fixup
* Reuse electron window; difficult task
* Rebased and refixed
* Remove duplicate cases
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Reduce the workers to something CI can handle
* Lower it further, we need to think about the others
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Fix the last tests and tsc errors
* Timeout to 120 and windows-2022-16core
* Fix windows runner detection, enable concurrency temporarily
* Hopefully this time fix windows runner detection
* Comment out Vector, add back removed camera test code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Fix camera tests again
* Massively deflake a whole class of tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Try new CI and fix small onboarding test
* Derp
* No github tuning
* Try mac
* Add back all the OS
* Lord, hallow be thy name
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* One last try with window-16-cores
* Trigger CI
* Try AWS Windows runner
* Passing on windows locally with a few skips
* Skip more win tests, add back all three oses
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Add two more fixmes
* 2 more fixmes
* skip segment overlays on win32
* Another fixme
* Trigger CI
* Trigger CI
* Quick clean up
* Move all tests over to electron
* Pass the correct param to playwright-electron.sh
* Add shebang to script and add macos-14-large as a target
* Get sketch-tests.spec.ts passing in electron
* Try out 4 workers
* Got testing-segment-overlays passing
* Pass testing-selections.spec.ts
* Go back to fix up sketch-tests test
* Pass various.spec.ts, by far the hardest one
* Pass can-sketch-on-all-planes... with ease
* Pass command bar tests
* fmt
* Completely fix code mirror text navigating for tests
* Pass debug pane tests
* Pass desktop export tests
* Pass editor tests
* Pass file tree tests
* Pass onboarding tests
* Corrected a fixme in file-tree.spec!
* Painfully fix hardcoded coordinates in point-click.spec
* Pass machine.spec tests
* Pass projects, fought hard with filechooser
* Pass regresion-tests.spec tests
* Pass network and connection tests
* Pass camera-movement.spec tests
* Extreme time eaten by gizmo test fixes. All passing now.
* Merge main (tests changed x_x) and pass all constraints.spec tests (pain)
* Pass another painful spec suite: testing-settings
* Pass perspective-toggle, interesting note
* Pass samples loading tests
* Pass app header tests
* Pass text-to-cad tests
* Pass segment-overlays (minor ache) and ability to switch to web if needed :)
* Fix a ton of syntax changes and deflake 2 more tests (pain)
* Correct all tsc errors
* Remove to-electron script
* Add an f-ton of shit because playwright doesnt want S P R E A D
* Try CI again
* Stop snapshots of exports (already test in e2e)
* Fix flake in double click editor
* Hopefully help CI flake
* Fixmes, fixmes everywhere
* One more fixme to settings
* Skip another code pane flake
* Port jess's projects.spec tests
* fixup
* Reuse electron window; difficult task
* Rebased and refixed
* Remove duplicate cases
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Reduce the workers to something CI can handle
* Lower it further, we need to think about the others
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Fix the last tests and tsc errors
* Timeout to 120 and windows-2022-16core
* Fix windows runner detection, enable concurrency temporarily
* Hopefully this time fix windows runner detection
* Comment out Vector, add back removed camera test code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Fix camera tests again
* Massively deflake a whole class of tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Try new CI and fix small onboarding test
* Derp
* No github tuning
* Try mac
* Add back all the OS
* Lord, hallow be thy name
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Try AWS Windows runner
* Passing on windows locally with a few skips
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fmt, tsc, lint
* Enable two fixmes again
* Fix lint, codespell, fmt
* Fix lint
* Don't run e2e on draft, add back concurrency, clean up
* One last windows skip
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* Add blank line to discord bot message (#4814)
* Add blank link to discord bot message
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Implement some basic cache program generation (#4840)
Implement some basic cache program generation
A bit ago, @jessfraz added the ability to control reexecution from the
executor. When we did this, it used the digest to determine if there
was a code change rather than a non-code change (whitespace, comment,
etc).
This allows the creation of a new program to be run without clearing the
scene. This, in conjunction with being able to delete Engine objects by
ID will allow us to do some clever stuff when incrementally executing
a program.
I'm still working on something a bit more advanced, but a good first
step to derisk some of the caching behavior here fully is to implement a
basic "changed program" stub.
This process the ast programs (old and new) if it doesn't exactly match.
This would have been a complete refresh before this commit.
1) Check all overlapping top-level statements of the body of the new and
old AST and ensure they all match.
- If this is true, this means that one of the two AST programs has more
elements then the other, and they all otherwise match (addition or
deletion of the end of the program). We continue to #2 in this
case.
- If this is false, we have a meaingful difference in a section of
overlapping code. This will result in a cache miss and rebuild
the scene. We short-cut here and the scene is rebuilt.
2) Check the lengths of the two bodies.
- If they're the same, we shouldn't have even been called. We will
short-cut with a noop cache return (no clear, no program).
- if the old ast is longer, we've removed instructions from the
program. We can't delete things now, so this will result in a cache
miss and rebuild the scene. We short-cut here and the scene is
rebuilt.
- If the new ast is longer, we have an insertion of code at the end.
3) construct a new program using only the new elements from the new
ast, and return a `CacheResult` that *does not clear the scene*.
This means nothing will be rebuilt, and only a new object will polp
onto the scene. This is the first case where we diverge with
existing behavior.
Signed-off-by: Paul R. Tagliamonte <paul@zoo.dev>
* Fix mac issue after electron test migration PR (#4842)
Fix mac issue after electron test migration pR
* Remove guards from modeling commands in the toolbar (#4800)
* Remove guards from modeling commands in the toolbar
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Remove the deprecated function, update doc comment for the one still in use
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Remove more selection check functions that are no longer used
* Update E2E tests that assumed the extrude button could be disabled due to selection
* Update a few fillet tests that expected the button to disable based on selection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* Prompt to edit (#4830)
* initial plumbing for getting the new option into the cmd-bar
* start of prompt edit
* update AI poll
* add spinner
* more prompt engineering
* add success toast, allowing user's to reject code
* select code that changed in prompt to edit
* selection in scene should not disappear when opening prompt cmd
* tweak
* fmt
* add tests
* some clean up
* clean up
* fix tests
* Yeet telemetry to text to cad endpoint (#4847)
yeet telemetry to text to cad endpoint
* Tweak prompt wording (#4846)
tweak prompt wording
* update discord bot (#4837)
* Re-enable test 'code pane closed at start' after electron migration (#4841)
* Re-enable 'code pane closed at start'
Relates to #4838
* Enable test on current branch
* Revert "Enable test on current branch"
This reverts commit 0d970b9ad6.
* Add 3-point circle tool (#4832)
* Add 3-point circle tool
This adds a 1st pass for the 3-point circle tool.
There is disabled code to drag around the 3 points and redraw the circle and
a triangle created by those points. It will be enabled in a follow-up PR
when we have circle3Point in the stdlib.
For now, all it does is after the 3rd click, will insert circle center-radius
KCL code for users to modify.
* PR comments
* First draft of a feature tree pane (#4782)
* Fix e2e default planes tests to use mask on state indicator (#4849)
* Fix e2e default planes tests to use mask on state indicator
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix: don't error on failure to fetch privacy settings (#4799)
* fix: dont error on failure to fetch privacy settings
* Add console warning when we ignore it
---------
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
* Match package license to LICENSE file (#4882)
* Remove the old Loft GitHub issue link in the toolbar (#4848)
Now that it's available, it shouldn't be there anymore.
* Fix fuzz crate lints and update deps (#4873)
* Fix fuzz to use new API
* Fix fuzz Cargo.toml lints and update lock
* Use app foreground color for focus outline button color so there's no hue collision (#4894)
Towards #4851
* Add support for float numbers in rem() arguments (#4858)
* Add support for float numbers in rem() arguments
* Update docs
* Rename to prevent name collision in docs
* Update docs after rename to NumberArg
* Fix parameter types to follow naming convention
* Change doc comment description to not refer to floating point
* Update docs after NumberArg doc change
* Change function to be more condensed
* Change to not try to preserve ints
* Update docs to use f64
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add auto-retries to macOS build notarization (#4892)
* Add DEBUG=electron-notarize* to build-apps
* Force IS_RELEASE: true
* Temp: Disable version setting based on tag
* Remove deprecated notarize.teamId and add retry logic
* Revert "Remove deprecated notarize.teamId and add retry logic"
This reverts commit 6ff98d784d.
* Retry only on macOS
* Better retry logic for macOS
* Use nick-fields/retry
* Clean up Temp: commits for PR
* Clean up
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Bump nanoid from 3.3.7 to 3.3.8 (#4731)
Bumps [nanoid](https://github.com/ai/nanoid) from 3.3.7 to 3.3.8.
- [Release notes](https://github.com/ai/nanoid/releases)
- [Changelog](https://github.com/ai/nanoid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ai/nanoid/compare/3.3.7...3.3.8)
---
updated-dependencies:
- dependency-name: nanoid
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Enable enter for autocompletions in the command palette KCL input (#4896)
* Enable enter for autocompletions in the command palette KCL input
* Oops I commented out code for the variable name input
Thanks for the catch @pierremtb
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Bump rollup from 4.21.0 to 4.29.1 (#4888)
* Bump rollup from 4.21.0 to 4.29.1
Bumps [rollup](https://github.com/rollup/rollup) from 4.21.0 to 4.29.1.
- [Release notes](https://github.com/rollup/rollup/releases)
- [Changelog](https://github.com/rollup/rollup/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rollup/rollup/compare/v4.21.0...v4.29.1)
---
updated-dependencies:
- dependency-name: rollup
dependency-type: indirect
...
Signed-off-by: dependabot[bot] <support@github.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Louder Windows codesign errors (#4762)
* WIP: Silent failure in signWin.js
Fixes#4582
* Temp: force release build
* Fake throw
* Temp: another test
* Clean up for merge
* Add parsing keyword function calls inside pipelines (#4907)
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Remove draft PR filter on e2e tests (#4908)
* Add three point circle stdlib function (#4893)
* Add parsing keyword function calls inside pipelines
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Add three point circle stdlib function
* Generate new documentation
* Fix 20:20 for the circle three point test
* Convert to using keyword arguments
* Wtf yo
* Remove unused structure
* Use the new simulation tests
* Regenerate documentation
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Move the base CodeMirror KCL support to a local package (#4897)
* Move CodeMirror LRLanguage to new file
This separates the base language support from the LSP and color picker.
* Move the base CodeMirror KCL support to a local package
* Start CodeMirror grammar tests
* Exclude vitest config in tsconfig
* Add KCL path to tsconfig
* Remove stray import
* Drop extension from import
* Use __filename for commonjs compat
* Check exec return before access
* Build ES and CJS to dist
* Format
* Exclude all.test.ts from codespell
This is to work around "fileTests" imported from Lezer. Future codespell versions look
like they'll allow the code to be annotated, which would be nicer.
---------
Co-authored-by: Matt Mundell <matt@mundell.me>
* Fix typo in README (#3843)
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* remove backwards compatibility for snake case in objects (#4920)
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* CM KCL: Support `=` in record init (#4933)
Support `=` in record init
Co-authored-by: Matt Mundell <matt@mundell.me>
* Bump clap from 4.5.21 to 4.5.23 in /src/wasm-lib (#4928)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.21 to 4.5.23.
- [Release notes](https://github.com/clap-rs/clap/releases)
- [Changelog](https://github.com/clap-rs/clap/blob/master/CHANGELOG.md)
- [Commits](https://github.com/clap-rs/clap/compare/clap_complete-v4.5.21...clap_complete-v4.5.23)
---
updated-dependencies:
- dependency-name: clap
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump @kittycad/lib from 2.0.7 to 2.0.12 (#4922)
Bumps [@kittycad/lib](https://github.com/KittyCAD/kittycad.ts) from 2.0.7 to 2.0.12.
- [Release notes](https://github.com/KittyCAD/kittycad.ts/releases)
- [Commits](https://github.com/KittyCAD/kittycad.ts/compare/v2.0.7...v2.0.12)
---
updated-dependencies:
- dependency-name: "@kittycad/lib"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump anyhow from 1.0.94 to 1.0.95 in /src/wasm-lib (#4929)
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.94 to 1.0.95.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.94...1.0.95)
---
updated-dependencies:
- dependency-name: anyhow
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump url from 2.5.3 to 2.5.4 in /src/wasm-lib (#4930)
Bumps [url](https://github.com/servo/rust-url) from 2.5.3 to 2.5.4.
- [Release notes](https://github.com/servo/rust-url/releases)
- [Commits](https://github.com/servo/rust-url/compare/v2.5.3...v2.5.4)
---
updated-dependencies:
- dependency-name: url
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump wasm-streams from 0.4.1 to 0.4.2 in /src/wasm-lib (#4926)
Bumps [wasm-streams](https://github.com/MattiasBuelens/wasm-streams) from 0.4.1 to 0.4.2.
- [Release notes](https://github.com/MattiasBuelens/wasm-streams/releases)
- [Changelog](https://github.com/MattiasBuelens/wasm-streams/blob/main/CHANGELOG.md)
- [Commits](https://github.com/MattiasBuelens/wasm-streams/compare/v0.4.1...v0.4.2)
---
updated-dependencies:
- dependency-name: wasm-streams
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump @csstools/postcss-oklab-function from 4.0.2 to 4.0.7 (#4923)
Bumps [@csstools/postcss-oklab-function](https://github.com/csstools/postcss-plugins/tree/HEAD/plugins/postcss-oklab-function) from 4.0.2 to 4.0.7.
- [Changelog](https://github.com/csstools/postcss-plugins/blob/main/plugins/postcss-oklab-function/CHANGELOG.md)
- [Commits](https://github.com/csstools/postcss-plugins/commits/HEAD/plugins/postcss-oklab-function)
---
updated-dependencies:
- dependency-name: "@csstools/postcss-oklab-function"
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* fix: writes to disk when the user accepts the prompt to edit (#4942)
* fix: writes to disk when the user accepts the prompt to edit
* fix: then catch
* Make circle3Point tool an actor (#4906)
* Reduce the amount of data sent to TS and make new fields opt-in (#4913)
* Reduce the amount of data sent back to JS/TS from WASM
* Remove unneeded derives since we shouldn't expose these types
* Alias type to be clearer
* Bump syn from 2.0.87 to 2.0.95 to be compatible with modeling-cmds 0.… (#4945)
Bump syn from 2.0.87 to 2.0.95 to be compatible with modeling-cmds 0.2.86
* fix out of range error (#4931)
* fix out of range error
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* remove console logs
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* add a regression test
Signed-off-by: Jess Frazelle <github@jessfraz.com>
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* Run chrome e2e snapshots only on linux (#4947)
* Run chrome e2e snapshots only on linux
* Wtf is this 1-indexed
* Force 1/1 sharding
* Add TODO
* Nadro/3079/screenshot improvements (#3917)
* chore: swapped screenshot to only use the video stream
* feat: video stream screenshot, native electron screenshot
* fix: auto tsc, fmt, xgen, lint
* fix: fixing tsc errors
* fix: removing debug console.log
* fix: renaming ScreenShot to Screenshot
* fix: deleting console log from debugging
* fix: bug with what source was referenced
* fix: using a productName
* fix: improving usage for native screenshots and detecthing support
* fix: fmt
* chore: updated rust test documentation
* fix: typo in readme
* fix: leaving package.json and yarn.lock the same as main??
* bump
* bump
* bump again
* bump again2
* feat: implemented zoom to fit on code change if previous AST was empty (#3925)
* feat: implemented zoom to fit on code change if previous AST was empty
* feat: implementing selectAll text logic to enable select all and copy and paste and zoom to fit will work
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: clarifying comment in _isAstEmpty
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* bump again
* fix: fixing new type since this branch is old
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Add dependabot group for all serde dependencies (#4944)
* Fix formatting of dependabot.yml
* Add dependabot group for all serde dependencies
* CM KCL: = and => are optional in fn declarations (#4941)
CM KCL: `=` and `=>` are optional in fn declarations
Co-authored-by: Matt Mundell <matt@mundell.me>
* Bump ts-rs from 10.0.0 to 10.1.0 (#4949)
* Add toolbar buttons for text-to-cad and prompt-to-edit (#4938)
* Add toolbar buttons for text-to-cad and prompt-to-edit
Resolves#4890
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* `preventDefault` on <kbd>Enter</kbd> with textarea input so buttons aren't clicked as well
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* Bump quote from 1.0.37 to 1.0.38 in /src/wasm-lib (#4951)
Bumps [quote](https://github.com/dtolnay/quote) from 1.0.37 to 1.0.38.
- [Release notes](https://github.com/dtolnay/quote/releases)
- [Commits](https://github.com/dtolnay/quote/compare/1.0.37...1.0.38)
---
updated-dependencies:
- dependency-name: quote
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* array pop with unlabled kw arg
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Signed-off-by: Paul R. Tagliamonte <paul@zoo.dev>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Kevin Nadro <nadr0@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
Co-authored-by: Paul Tagliamonte <paul@zoo.dev>
Co-authored-by: Josh Gomez <114548659+jgomez720@users.noreply.github.com>
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
Co-authored-by: Matt Mundell <32057441+mattmundell@users.noreply.github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Matt Mundell <matt@mundell.me>
Co-authored-by: alteous <david@harvey-macaulay.com>
* Add toolbar buttons for text-to-cad and prompt-to-edit
Resolves#4890
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* `preventDefault` on <kbd>Enter</kbd> with textarea input so buttons aren't clicked as well
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* feat: implemented zoom to fit on code change if previous AST was empty
* feat: implementing selectAll text logic to enable select all and copy and paste and zoom to fit will work
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: clarifying comment in _isAstEmpty
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* bump again
* fix: fixing new type since this branch is old
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* bump
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* chore: swapped screenshot to only use the video stream
* feat: video stream screenshot, native electron screenshot
* fix: auto tsc, fmt, xgen, lint
* fix: fixing tsc errors
* fix: removing debug console.log
* fix: renaming ScreenShot to Screenshot
* fix: deleting console log from debugging
* fix: bug with what source was referenced
* fix: using a productName
* fix: improving usage for native screenshots and detecthing support
* fix: fmt
* chore: updated rust test documentation
* fix: typo in readme
* fix: leaving package.json and yarn.lock the same as main??
* bump
* bump
* bump again
* bump again2
* Move CodeMirror LRLanguage to new file
This separates the base language support from the LSP and color picker.
* Move the base CodeMirror KCL support to a local package
* Start CodeMirror grammar tests
* Exclude vitest config in tsconfig
* Add KCL path to tsconfig
* Remove stray import
* Drop extension from import
* Use __filename for commonjs compat
* Check exec return before access
* Build ES and CJS to dist
* Format
* Exclude all.test.ts from codespell
This is to work around "fileTests" imported from Lezer. Future codespell versions look
like they'll allow the code to be annotated, which would be nicer.
---------
Co-authored-by: Matt Mundell <matt@mundell.me>
* Add parsing keyword function calls inside pipelines
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Add three point circle stdlib function
* Generate new documentation
* Fix 20:20 for the circle three point test
* Convert to using keyword arguments
* Wtf yo
* Remove unused structure
* Use the new simulation tests
* Regenerate documentation
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Enable enter for autocompletions in the command palette KCL input
* Oops I commented out code for the variable name input
Thanks for the catch @pierremtb
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Add DEBUG=electron-notarize* to build-apps
* Force IS_RELEASE: true
* Temp: Disable version setting based on tag
* Remove deprecated notarize.teamId and add retry logic
* Revert "Remove deprecated notarize.teamId and add retry logic"
This reverts commit 6ff98d784d.
* Retry only on macOS
* Better retry logic for macOS
* Use nick-fields/retry
* Clean up Temp: commits for PR
* Clean up
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add support for float numbers in rem() arguments
* Update docs
* Rename to prevent name collision in docs
* Update docs after rename to NumberArg
* Fix parameter types to follow naming convention
* Change doc comment description to not refer to floating point
* Update docs after NumberArg doc change
* Change function to be more condensed
* Change to not try to preserve ints
* Update docs to use f64
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix: dont error on failure to fetch privacy settings
* Add console warning when we ignore it
---------
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
* Fix e2e default planes tests to use mask on state indicator
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add 3-point circle tool
This adds a 1st pass for the 3-point circle tool.
There is disabled code to drag around the 3 points and redraw the circle and
a triangle created by those points. It will be enabled in a follow-up PR
when we have circle3Point in the stdlib.
For now, all it does is after the 3rd click, will insert circle center-radius
KCL code for users to modify.
* PR comments
* Re-enable 'code pane closed at start'
Relates to #4838
* Enable test on current branch
* Revert "Enable test on current branch"
This reverts commit 0d970b9ad6.
* initial plumbing for getting the new option into the cmd-bar
* start of prompt edit
* update AI poll
* add spinner
* more prompt engineering
* add success toast, allowing user's to reject code
* select code that changed in prompt to edit
* selection in scene should not disappear when opening prompt cmd
* tweak
* fmt
* add tests
* some clean up
* clean up
* fix tests
* Remove guards from modeling commands in the toolbar
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Remove the deprecated function, update doc comment for the one still in use
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Remove more selection check functions that are no longer used
* Update E2E tests that assumed the extrude button could be disabled due to selection
* Update a few fillet tests that expected the button to disable based on selection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-macos-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
Implement some basic cache program generation
A bit ago, @jessfraz added the ability to control reexecution from the
executor. When we did this, it used the digest to determine if there
was a code change rather than a non-code change (whitespace, comment,
etc).
This allows the creation of a new program to be run without clearing the
scene. This, in conjunction with being able to delete Engine objects by
ID will allow us to do some clever stuff when incrementally executing
a program.
I'm still working on something a bit more advanced, but a good first
step to derisk some of the caching behavior here fully is to implement a
basic "changed program" stub.
This process the ast programs (old and new) if it doesn't exactly match.
This would have been a complete refresh before this commit.
1) Check all overlapping top-level statements of the body of the new and
old AST and ensure they all match.
- If this is true, this means that one of the two AST programs has more
elements then the other, and they all otherwise match (addition or
deletion of the end of the program). We continue to #2 in this
case.
- If this is false, we have a meaingful difference in a section of
overlapping code. This will result in a cache miss and rebuild
the scene. We short-cut here and the scene is rebuilt.
2) Check the lengths of the two bodies.
- If they're the same, we shouldn't have even been called. We will
short-cut with a noop cache return (no clear, no program).
- if the old ast is longer, we've removed instructions from the
program. We can't delete things now, so this will result in a cache
miss and rebuild the scene. We short-cut here and the scene is
rebuilt.
- If the new ast is longer, we have an insertion of code at the end.
3) construct a new program using only the new elements from the new
ast, and return a `CacheResult` that *does not clear the scene*.
This means nothing will be rebuilt, and only a new object will polp
onto the scene. This is the first case where we diverge with
existing behavior.
Signed-off-by: Paul R. Tagliamonte <paul@zoo.dev>
* Add blank link to discord bot message
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Move all tests over to electron
* Pass the correct param to playwright-electron.sh
* Add shebang to script and add macos-14-large as a target
* Get sketch-tests.spec.ts passing in electron
* Try out 4 workers
* Got testing-segment-overlays passing
* Pass testing-selections.spec.ts
* Go back to fix up sketch-tests test
* Pass various.spec.ts, by far the hardest one
* Pass can-sketch-on-all-planes... with ease
* Pass command bar tests
* fmt
* Completely fix code mirror text navigating for tests
* Pass debug pane tests
* Pass desktop export tests
* Pass editor tests
* Pass file tree tests
* Pass onboarding tests
* Corrected a fixme in file-tree.spec!
* Painfully fix hardcoded coordinates in point-click.spec
* Pass machine.spec tests
* Pass projects, fought hard with filechooser
* Pass regresion-tests.spec tests
* Pass network and connection tests
* Pass camera-movement.spec tests
* Extreme time eaten by gizmo test fixes. All passing now.
* Merge main (tests changed x_x) and pass all constraints.spec tests (pain)
* Pass another painful spec suite: testing-settings
* Pass perspective-toggle, interesting note
* Pass samples loading tests
* Pass app header tests
* Pass text-to-cad tests
* Pass segment-overlays (minor ache) and ability to switch to web if needed :)
* Fix a ton of syntax changes and deflake 2 more tests (pain)
* Correct all tsc errors
* Remove to-electron script
* Add an f-ton of shit because playwright doesnt want S P R E A D
* Try CI again
* Stop snapshots of exports (already test in e2e)
* Fix flake in double click editor
* Hopefully help CI flake
* Fixmes, fixmes everywhere
* One more fixme to settings
* Skip another code pane flake
* Port jess's projects.spec tests
* fixup
* Reuse electron window; difficult task
* Rebased and refixed
* Remove duplicate cases
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Reduce the workers to something CI can handle
* Lower it further, we need to think about the others
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Fix the last tests and tsc errors
* Timeout to 120 and windows-2022-16core
* Fix windows runner detection, enable concurrency temporarily
* Hopefully this time fix windows runner detection
* Comment out Vector, add back removed camera test code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Fix camera tests again
* Massively deflake a whole class of tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Try new CI and fix small onboarding test
* Derp
* No github tuning
* Try mac
* Add back all the OS
* Lord, hallow be thy name
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* One last try with window-16-cores
* Trigger CI
* Try AWS Windows runner
* Passing on windows locally with a few skips
* Skip more win tests, add back all three oses
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-16-cores)
* Add two more fixmes
* 2 more fixmes
* skip segment overlays on win32
* Another fixme
* Trigger CI
* Trigger CI
* Quick clean up
* Move all tests over to electron
* Pass the correct param to playwright-electron.sh
* Add shebang to script and add macos-14-large as a target
* Get sketch-tests.spec.ts passing in electron
* Try out 4 workers
* Got testing-segment-overlays passing
* Pass testing-selections.spec.ts
* Go back to fix up sketch-tests test
* Pass various.spec.ts, by far the hardest one
* Pass can-sketch-on-all-planes... with ease
* Pass command bar tests
* fmt
* Completely fix code mirror text navigating for tests
* Pass debug pane tests
* Pass desktop export tests
* Pass editor tests
* Pass file tree tests
* Pass onboarding tests
* Corrected a fixme in file-tree.spec!
* Painfully fix hardcoded coordinates in point-click.spec
* Pass machine.spec tests
* Pass projects, fought hard with filechooser
* Pass regresion-tests.spec tests
* Pass network and connection tests
* Pass camera-movement.spec tests
* Extreme time eaten by gizmo test fixes. All passing now.
* Merge main (tests changed x_x) and pass all constraints.spec tests (pain)
* Pass another painful spec suite: testing-settings
* Pass perspective-toggle, interesting note
* Pass samples loading tests
* Pass app header tests
* Pass text-to-cad tests
* Pass segment-overlays (minor ache) and ability to switch to web if needed :)
* Fix a ton of syntax changes and deflake 2 more tests (pain)
* Correct all tsc errors
* Remove to-electron script
* Add an f-ton of shit because playwright doesnt want S P R E A D
* Try CI again
* Stop snapshots of exports (already test in e2e)
* Fix flake in double click editor
* Hopefully help CI flake
* Fixmes, fixmes everywhere
* One more fixme to settings
* Skip another code pane flake
* Port jess's projects.spec tests
* fixup
* Reuse electron window; difficult task
* Rebased and refixed
* Remove duplicate cases
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Reduce the workers to something CI can handle
* Lower it further, we need to think about the others
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Update package.json
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Fix the last tests and tsc errors
* Timeout to 120 and windows-2022-16core
* Fix windows runner detection, enable concurrency temporarily
* Hopefully this time fix windows runner detection
* Comment out Vector, add back removed camera test code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Fix camera tests again
* Massively deflake a whole class of tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: macos-14-large)
* Try new CI and fix small onboarding test
* Derp
* No github tuning
* Try mac
* Add back all the OS
* Lord, hallow be thy name
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Try AWS Windows runner
* Passing on windows locally with a few skips
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: namespace-profile-ubuntu-8-cores)
* fmt, tsc, lint
* Enable two fixmes again
* Fix lint, codespell, fmt
* Fix lint
* Don't run e2e on draft, add back concurrency, clean up
* One last windows skip
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Pierre Jacquier <pierre@zoo.dev>
* KCL: Show beautiful Miette errors when a KCL example test fails
Background: KCL example tests are generated from the stdlib KCL examples in the `#[stdlib]` macro in derive-docs.
Problem: When these tests fail, they output a really unhelpful error message like Kcl(Semantic(KclErrorDetails { source_ranges: [156, 160, 0], message: "Expected a sketch but found array" } )).
Solution: Use miette. Now the errors highlight the KCL code that failed and show exactly what went wrong, on which line, presenting nice diagnostics that look like cargo/rustc output.
* Update helix snapshots
* feat: double click segment label to dimension length, POC, need to clean up code!
* fix: cleaning up the PR for review
* fix: cleaning for the PR. Adding more comments and moving some logic
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: mergining main, auto linter and tsc fixes. Need to make some more
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: tsc errors are resolved
* chore: added test for constraint
* fix: fixing overlay bug since length labels can now be clicked.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* WIP: mess with shell selection validation
Will eventually fix#4711
* Update from main
* WIP: not working yet
* Working loft dry run validator
* Clean up shell (still not working)
* Bump kittycad-modeling-cmds
* Clean up
* Add logging
* Add proper object_id and face_id mapping, still not working for shell
* Fix faceId
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Add dry-run validation to Loft
Checks one box for #4711
* Add extra check for non solid2ds
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Part of #4600
KCL functions can declare one special argument that doesn't require a label on its parameter when called.
This PR will default that arg to % (the current pipeline) if not given.
* Parse annotations
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Propagate settings from annotations to exec_state
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* redoing bool logic impl on latest main
* adding snapshot tests (removing .new)
* removing accidental change smh:(
* accepting client side scene snapshot
* accepting png snapshot and triggering ci
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* accepting png again?
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting grid visibility snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting png snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* accepting png snapshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* accepting png snapshot
* rerunning simtest creation to get ops.snap files
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Allow underscores but only for un-referenced names
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Support numeric suffixes for UoM types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* UoM type arguments
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* warnings -> non-fatal errors
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* type ascription
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add operations tracking for the timeline
* Change to only track certain stdlib functions as operations
* Update gen files
* Add operations to simulation snapshot tests
* Add tracking of positional function calls
* Fix generated field names to be camel case in TS
* Fix generated TS field names to match and better docs
* Fix order of ops with patternTransform
* Fix sweep to be included
* Add new expected test outputs
* Add tracking for startSketchOn
* Update ops output to include startSketchOn
* Fix serde field name
* Fix output field name
* Add tracking of operations that fail
* Add snapshots of operations even when there's a KCL execution error
* Add ops output for error executions
* Add operations output to executor error
* Update op source ranges
* Remove tracking of circle() and polygon() since they're not needed
* Update output without circle and polygon
* Fix to track patternCircular3d and patternLinear3d
* Remove tracking for mirror2d
* Update ops output
* Fix to track the correct source range of function definitions
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Revert "multi-profile follow up. (#4802)"
This reverts commit 2b2ed470c1.
* Revert "multi profile (#4532)"
This reverts commit 04e586d07b.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Re-run CI after snapshots
* Re-run CI after snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Re-run CI after snapshots
* Add `fixme` to onboarding test
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* multi-profile work
* fix enter sketch on cap
* fix coderef problem for walls and caps
* allow sketch mode entry from circle
* clean up
* update snapshot
* Look at this (photo)Graph *in the voice of Nickelback*
* trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* add test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix how expression index is corrected, to make compatible with offset planes
* another test
* tweak test
* more test tweaks
* break up test to fix it hopfully
* fix onboarding test
* remove bad comment
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* multi-profile work
* another test
* clean up
* cover a quirk with a test
* last of tests
* fix typos
* Fix source range in snap test
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
When engine merged their big extrude ID bugfix,
they changed the response for extrudes on face.
Basically there's no longer a start face for
something you extrude from a face, because there
just isn't. There's a hole in a previous face,
it's just a gap.
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Bump wasm-bindgen from 0.2.91 to 0.2.99 and wasm-bindgen-futures from 0.4.44 to 0.4.49
* Upgrade in the kcl crate also
* Update web-sys version constraint to match lock
Remove non code from Digests
@jessfraz and I talked it over; for the time being we're going to remove
comments from the AST digest. We already exclude source position, so
this is just increasing the degree to which we're going to ignore things
that are not germane to execution.
Before, we'd digest *some* but not all of the comments in the AST.
Silly, I know, right?
So, this code:
```
firstSketch = startSketchOn('XY')
|> startProfileAt([-12, 12], %)
|> line([-24, 0], %) // my thing
|> close(%)
|> extrude(6, %)
```
Would digest differently than:
```
firstSketch = startSketchOn('XY')
|> startProfileAt([-12, 12], %)
|> line([-24, 0], %)
|> close(%)
|> extrude(6, %)
```
Which is wrong. We've fully divested of hashing code comments, so this
will now hash to be the same. Hooray.
* More Walk cleanup
- The `Node` type contained two enums by mistake. Those have been
removed.
- Export the `Visitor` and `Visitable` traits, as I start to migrate
stuff to them.
- Add a wrapper to pull the `digest` off the node without doing a
`match` elsewhere.
* update camera controls to Zoo
* update e2e and initial settings
* update types and camera controls ts
* update mod.rs test
* update test, test locally
* Refactor ContextMenu to be able to take a guard and other event types
* refactor: break out ViewControlMenu into its own component
* Add ViewControlMenu to Stream, but only on right-click non-drag mouseup
* Fix lints
* Don't use `useCallback` for contextmenu guard
* Update context menu position on subsequent right-clicks
* Reapply "More aggressive using of cache on engine settings changes (#4691)" (#4729)
This reverts commit 3f1f40eeba.
* Add a utility to get all the current values from the settings object
* Use an XState selector to get the latest settings snapshot for WASM
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
* selection stuff
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* trigger CI
* fix bugs
* some edge cut stuff
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* fix sketch mode issues
* fix more tests, selection in sketch related
* more test fixing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger ci
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger ci
* more sketch mode selection fixes
* fix unit tests
* rename function
* remove .only
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* lint
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* fix bad pathToNode issue
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* fix sketch on face
* migrate a more selections types
* migrate a more selections types
* fix code selection of fillets
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* fix bad path to node, looks like a race
* migrate a more selections types
* migrate a more selections types
* fix cmd bar selections
* fix cmd bar selections
* fix display issues
* feat: implementing axis selection for point and click revolve
* feat: enforcing selection of 2 options for axis rotation
* feat: added negative rotations for the revolve
* fix: fmt, tsc fixes
* migrate a more selections types
* Revert "migrate a more selections types"
This reverts commit 0d0e453bbb.
* migrate a more selections types
* clean up1
* clean up 2
* chore: improving the copy after discussing with Frank
* fix: merge main fixes
* chore: was able to add a seg to a line. Does not check if one exists already
* saving off some code
* chore: moving revolveSketch into own file for readability, improving variable names instead of node1
* chore: renaming more variables for readability
* chore: more renaming
* fix: allows creating a custom rotation on axis
* fix: added opposite edge logic and adj, need to error handle still
* fix: use other import
* feat: point and click on edges, crude implementation
* feat: implemented toast message and returned error message from validation
* fix: auto linter
* fix: addressing tsc errors
* fix: fighting typescript
* fix: cleaning up PR
* fix: trying to resolve more typescript issues
* fix: save off tsc fixes
* fix: adding comments
* fix: resolving tsc errors
* fix: tsc errors
* fix: auto linter fixes and tsc fixes
* fix:??
* fix: revolve ast works with declaration
* fix: retry logic to make sure the disable dry run actually runs
* fix: codespell typo
---------
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Part of https://github.com/KittyCAD/modeling-app/issues/4600
You can now call a user-defined function via keyword args. E.g.
```
fn increment(@x) {
return x + 1
}
fn add(@x, delta) {
return x + delta
}
two = increment(1)
three = add(1, delta: 2)
```
* Add test with tag parameter
* Fix to not define TagIdentifiers pointing to nothing
* Add fixed test output
* Rename function to be clearer
* Remove optional param so that unparse works
* Fix to not allow redefining tags
* Fix to only ever define tags in memory when used with stdlib functions
* Fix to not define local variables when non-literal tag declarator is used
* Add removing mutability
* Change function signature since it isn't falliable
* Refactor TokenStream (and some minor changes to Token)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Tidy up lexer tests
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
# Problem
Before this PR, our formatter reformats
```
squares_out = reduce(arr, 0, fn (i, squares) {
return 1
})
```
to
```
squares_out = reduce(arr, 0, (i, squares) {
return 1
})
```
i.e. it removes the `fn` keyword from the closure. This keyword is required, so, our formatter turned working code into invalid code.
# Cause
When this closure parameter is formatted, the ExprContext is ::Decl, so `Expr::recast` skips adding the `fn` keyword. The reason it's ::Decl is because the `squares_out = ` declaration sets it, and no subsequent call sets the context to something else.
# Solution
When recasting a call expression, set the context for every argument to `ExprContext::Other`.
* Fix nightly release page link in bottom bar
Fixes#4713
* Working now
* Cleaner
* Add IS_NIGHTLY var to make these checks more consistent
* Review from Kevin
* Update url for settings content too
* start a rework of the walk module
I'd like to have the code explicitly recurse in the visitor rather than
implicitly. This allows the calling code to build up an idea of the
depth of each node, or skip parts of the AST entirely.
i'm going to rebuild this enough to get the old API to work before
looking to merge this.
I've also discovered a number of new AST types that were just papered
over and/or excluded entirely -- I'm going to have to go through and
make sure that both Digest and the walker are still current, or if we
silently added types or, more likely, fields getting ignored.
* Extend KCL argument input
* Migrate length constraint to be a command
* Add ability for `kcl` arguments to provide an initial variable name
* Move named variable flow into command palette
* Fix one e2e test
* Remove unwanted `ZERO` behavior when length constraint has no `variableName`
* Fix issue with `getSelectionCountByType` with sketches not yet in artifactGraph
* Update broken constraint tests
* Look at this (photo)Graph *in the voice of Nickelback*
* Fix segment overlays tests, which had out-of-date selectors
* Return early from `useConvertToVariable` if no selectionRanges
* Fixup for review comment from #4677 (#4696)
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Invalidate nightly bucket files after publish (#4627)
* Invalidate nightly bucket files after publish
* Fix conflict resolution
* Add some more warnings (#4697)
* Add installation instructions for all platforms (#4592)
* Add installation instructions for all platforms
Fixes#4511
* Typo
* Typo2
* Improve linux instructions, thanks @TomPridham
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
---------
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
* Bump node to v22.12.0 (LTS) (#4706)
* Point-and-click Shell (#4666)
* WIP: experimenting with Loft UI
Relates to #4470
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Add selection guard
* Working loft for two sketches in the right hardcoded order
* First pass at handling more than 2 sketches
* WIP selections
* WIP selections
* More checks
* Appends the loft line after the 'last' sketch in the code
* Clean up
* Enable multiple selections after the button click
* First point-click loft test (not working locally, loft gets inserted at the wrong place)
* Lint
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Clean up and working pw test
* Add test for doesSceneHaveSweepableSketch with count = 2
* Clean up loftSketches function
* Add pw test for preselected sketches
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Move to fromPromise-based Actor
* Move error logic out of loftSketches, fix pw tests
* Remove comments
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Fix typo
* Revert snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* WIP: initial shell code addition
* Rollback pw values to pre cam change
* WIP: more additions
* WIP: closer
* WIP: first time working shell mod
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Add extrude lookup for more generic shell
* Handle walls
* Add pw tests for cap shell
* Add shell wall test
* Fix lint
* Add selection guard and clean up
* Lint fix
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* WIP mutliple faces
* WIP circular dep
* Lint
* Look at this (photo)Graph *in the voice of Nickelback*
* Trigger CI
* Working multi-face shell across types
* Cap and wall pw test
* Apply suggestions from Frank's review
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Fix test annotations
* Add unit tests for doesSceneHaveExtrudedSketch
* Manual resolution of snapshot conflicts
* Fix assertParse
* Updated pathToNode construct
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* More aggressive using of cache on engine settings changes (#4691)
* move around the files for cache to better localtions
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* cleanup
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* udpates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* cleanup
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* ensure we can change the grid setting via the command bar
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* pass thru all setttings
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* fix playwright test
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* emoty
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix use of `as`
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* WIP: experimenting with Loft UI
Relates to #4470
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Add selection guard
* Working loft for two sketches in the right hardcoded order
* First pass at handling more than 2 sketches
* WIP selections
* WIP selections
* More checks
* Appends the loft line after the 'last' sketch in the code
* Clean up
* Enable multiple selections after the button click
* First point-click loft test (not working locally, loft gets inserted at the wrong place)
* Lint
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Clean up and working pw test
* Add test for doesSceneHaveSweepableSketch with count = 2
* Clean up loftSketches function
* Add pw test for preselected sketches
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Move to fromPromise-based Actor
* Move error logic out of loftSketches, fix pw tests
* Remove comments
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Fix typo
* Revert snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* WIP: initial shell code addition
* Rollback pw values to pre cam change
* WIP: more additions
* WIP: closer
* WIP: first time working shell mod
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Add extrude lookup for more generic shell
* Handle walls
* Add pw tests for cap shell
* Add shell wall test
* Fix lint
* Add selection guard and clean up
* Lint fix
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* WIP mutliple faces
* WIP circular dep
* Lint
* Look at this (photo)Graph *in the voice of Nickelback*
* Trigger CI
* Working multi-face shell across types
* Cap and wall pw test
* Apply suggestions from Frank's review
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Fix test annotations
* Add unit tests for doesSceneHaveExtrudedSketch
* Manual resolution of snapshot conflicts
* Fix assertParse
* Updated pathToNode construct
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
When declaring a function, its first parameter is allowed to be prefixed with `@`. This means that when users call this function, they don't have to label this argument.
Only the first parameter is allowed this prefix, no others.
Part of https://github.com/KittyCAD/modeling-app/issues/4600
* fix: make variable declaration errors Cut instead of Backtrace
* fix: clippy, move comma to empty case and add test
* fix: add missing TokenType case
* fix: incorrect fn args after merge
* fix: clippy lint
* fix: update error message being looked for in e2e test
---------
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Parse more import syntax
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Remove unnecessary Vec from VariableDeclaration
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Parse export import
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Factor out an execution module
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* imports: constants, globs, export import
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* test fixups
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Pure refactor, should not change any behaviour.
Previously, optional parameters in KCL function calls always set the parameter to KclNone.
As of this PR, they can be set to KCL literals in addition to KCL none. However the parser does not actually ever use this (that'll be in a follow-up PR).
Also adds a `labeled: bool` to all parameters, which is always true. But it lays the groundwork for the unlabeled first parameter in a follow-up PR.
* Send multiple errors and warnings to the frontend and LSP
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactor the parser to use CompilationError for parsing errors rather than KclError
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Refactoring: move CompilationError, etc.
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Integrate compilation errors with the frontend and CodeMirror
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fix tests
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Review comments
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Fix module id/source range stuff
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* More test fixups
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
We don't have any of these, and I don't think it's
worth the complexity. The goal was to let us write
KCL stdlib functions in KCL not Rust. But who cares
really. We can always put this back if we need it.
* Fix broken test from previous PR
* Look at this (photo)Graph *in the voice of Nickelback*
* void
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Part of https://github.com/KittyCAD/modeling-app/issues/4600
Adds support for keyword arguments to the stdlib, and calling stdlib functions with keyword arguments.
So far, I've changed one function: `rem`. Previously you would have used `rem(7, 2)` but now it's `rem(7, divisor: 2)`.
This is a proof-of-concept. If it's approved, we will:
1. Support closures with keyword arguments, and calling them
2. Move the rest of the stdlib to use kw arguments
* Fix default planes to be created in deterministic order
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* WIP: experimenting with Loft UI
Relates to #4470
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Add selection guard
* Working loft for two sketches in the right hardcoded order
* First pass at handling more than 2 sketches
* WIP selections
* WIP selections
* More checks
* Appends the loft line after the 'last' sketch in the code
* Clean up
* Enable multiple selections after the button click
* First point-click loft test (not working locally, loft gets inserted at the wrong place)
* Lint
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Clean up and working pw test
* Add test for doesSceneHaveSweepableSketch with count = 2
* Clean up loftSketches function
* Add pw test for preselected sketches
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Move to fromPromise-based Actor
* Move error logic out of loftSketches, fix pw tests
* Remove comments
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Fix typo
* Revert snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Make some fields of lint::Discovered public again; update kittycad
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Empty commit to try to unstick CI
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* update fn syntax
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Trigger CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* refactor code mod and tests
* tsc
* make lint happy
* remove dumby data
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
KCL functions are a weird edge case, and the `FunctionExpression` field should not be included in its public API. That field is only there for implementation details, it shouldn't be exposed to users.
What's worse is that `FunctionExpression` includes a `Program` so every single AST node wound up being included in our docs.
* fix: only count something as a directory if it has children
* fix: playwright tests
* fix: return 0 if you cant find the projectfolder
* fix: remove folder count from e2e tests since it is unused currently
---------
Co-authored-by: Tom Pridham <pridham.tom@gmail.com>
* Implement the functionality
* Another fmt
* Fix handler to not rely on modelingMachine's context,
because that creates an implicit race
* Write an E2E test
* Fix tsc and fmt
* Use artifactGraph helpers for more concise code
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Fix up imports and whatnot from commit 2bfc5f5c
* Make early return more clear with curly braces
* Whoops should have linted
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Make `=` and `=>` optional in function declarations
And requires `:` for return types
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Tests
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Format types in function decls
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Require in anon function decls
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Add a code mod for offset plane
* Add support for default plane selections to our `otherSelections` object
* Make availableVars work without a selection range
(because default planes don't have one)
* Make default planes selectable in cmdbar even if AST is empty
* Add offset plane command and activate in toolbar
* Avoid unnecessary error when sketching on offset plane by returning early
* Add supporting test features for offset plane E2E test
* Add WIP E2E test for offset plane
Struggling to get local electron test suite running properly
* Typos
* Lints
* Fix test by making it a web-based one:
I couldn't use the cmdBar fixture with an electron test for some reason.
* Update src/lib/commandBarConfigs/modelingCommandConfig.ts
* Update src/machines/modelingMachine.ts
* Revert changes to `homePageFixture`, as they were unused
* @Irev-Dev feedback: convert action to actor, fix machine layout
* Update plane icon to be not dashed, follow conventions closer
* fix selection bugs found by QA-wolf
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* trigger ci
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* AST: Factor shebangs out of non-code metadata and into Progam
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Empty commit to try to unstick CI
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Right now our KCL tests output a debug representation of the KCLError
value. This works OK, but it's difficult to read an error like
"runtime error: SourceRange([44, 48])" because I don't fucking know what
the 44th character in my KCL program is.
In the modeling app, source ranges are turned into nice red squiggly
underlines in the editor. I want nice squiggly underline when I run the
Rust unit tests too, damnit. The JS world should NEVER have fancy toys
that I, a Rust programmer, cannot access. I deserve this. I need this.
So anyway instead of snapshotting debug repr, snapshot a fancy error
via the miette library.
Some clients (e.g. the simulation tests) want to know why a KCL program failed. Was it because of a network error? Or because the client wasn't authorized properly? Or was it a KCL runtime type error?
It's difficult for clients to ask these questions, because the interpreter just returns Anyhow error, basically just a string.
Instead, we should return different variants of an Error enum for different kinds of errors.
This lets us render nice Cargo-style error messages that show the exact KCL line where an error occurred, instead of just printing off a source range. We have that in the CLI, but I'd like it for running normal KCL unit tests.
# Testing
This is a pure refactor, it doesn't change any behaviour, it just stops hiding the specific error types via anyhow. No testing needed. If it compiles, it works.
* Add nightly link in about sectoin
* Add nightly detection
* Lint
* Change APP_NAME to PACKAGE_NAME
* To be improved: working implementation on mac for click to download
* Revert "To be improved: working implementation on mac for click to download"
This reverts commit 7ced32a533.
* Nevermind, will process on the website
* Release KCL, KCL test server and derive-docs
derive-docs 0.1.31
kcl-test-server 0.1.17
kcl-lib 0.2.25
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
KCL stdlib has a function `patternTransform` which works for 3D solids. This adds a similar function `patternTransform2d` which, as you might have guessed, is like `patternTransform` but for 2D. I know. I'm really, really really good at naming things.
This shares almost all of its implementation with 3D patterns via 💖the power of traits💖
This will assist with https://github.com/KittyCAD/modeling-app/issues/4543
* WIP: Improve current nightly implementation
* Add nightly icons
* Clean up script
* Clean up
* Clean up
* Clean up2
* Clean up3
* WIP: Make the release process non-blocking
First commit to fix#4522
* Quick fix
* Test release and updater-test
* Try nightly build
* WIP nightly tag creation
* Change of direction
* Quick fix
* Test nightly
* Better release notes for nightly
* Migrate to artifact@v4 and prepare publish release
* Fix out-yml for artifact@v4
* Progress towards publish-release
* merge-multiple: true
* Add dependency
* Clean up. Change direction again on updater-test (now with RELEASE workflow)
* Clean up and test release builds
* Fix name
* Clean up, add README
* Add release notes override, another release test
* Fake release version & better draft release
* Test nightly
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Clean up and first attempt at publish-release-apps
* Add GH_TOKEN
* Add github-token to download-artifact step
* Add github-token to all download-artifact steps
* Add checkout and node steps
* Clean up
* Remove whitespace
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Quick typo
* Add Kevin's semantic-release.sh script to replace make-release.sh
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Fix argument error to point to the arg at the call site
* Change MemoryFunction to accept Vec<Arg> instead of Vec<KclValue>
* Rename variable to be clearer
* Fix one more argument error message
* Clean up from PR feedback
* selection stuff
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* trigger CI
* fix bugs
* some edge cut stuff
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* trigger CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* fix sketch mode issues
* fix more tests, selection in sketch related
* more test fixing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger ci
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Trigger ci
* more sketch mode selection fixes
* fix unit tests
* rename function
* remove .only
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* lint
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* fix bad pathToNode issue
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* fix sketch on face
* migrate a more selections types
* migrate a more selections types
* fix code selection of fillets
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* migrate a more selections types
* fix bad path to node, looks like a race
* migrate a more selections types
* migrate a more selections types
* fix cmd bar selections
* fix cmd bar selections
* fix display issues
* migrate a more selections types
* Revert "migrate a more selections types"
This reverts commit 0d0e453bbb.
* migrate a more selections types
* clean up1
* clean up 2
* fix types after main merge
* review tweaks
* fix wall selection bug
* Update src/lang/std/engineConnection.ts
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* add franks TODO comment
* fix type after main merge, plus a touch of clean up
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
If the key and value in an object literal use the same identifier, allow abbreviating it.
Basically these two are now equivalent:
```
x = 2
obj = { x: x, y: 3}
```
```diff
x = 2
- obj = { x: x, y: 3}
+ obj = { x, y: 3}
```
This syntax is used in JS, Rust and probably elsewhere too.
Here's a more realistic example. Before:
```
radius = 10
startSketchAt([0, 0])
|> circle({center: [0, 0], radius: radius}, %)
```
After:
```diff
radius = 10
startSketchAt([0, 0])
- |> circle({center: [0, 0], radius: radius}, %)
+ |> circle({center: [0, 0], radius}, %)
```
Previously, this was the output of the formatter:
```
fn f = () => {
return () => {
return 1
}
}
```
Now the above will be reformatted as
```
fn f = () => {
return () => {
return 1
}
}
```
Much better!
* Make ast module private
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Make most other modules private
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Expand API to support CLI, Python bindings, and LSP crate
Signed-off-by: Nick Cameron <nrc@ncameron.org>
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
* Pass current file name through to export command
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Oops I needed a couple other things, not just that one line change
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Undo overriding of internal zipped file names
That was liable to cause conflicts and whatnot per @jessfraz feedback
* Update E2E test that was still looking for `output.gltf`
* Missed one other test my bad
* Should've just grepped for output.gltf to begin with
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Paul Tagliamonte <paul@zoo.dev>
* feat: implementing arcTo in standard library, first pass
* feat: computing center and radius for arcto
* fix: updating comment for arcTo
* fix: cargo fmt fix
* fix: bug, the x was used twice!
* fix: Cleaning up some code and adding more comments
* fix: this has to be removed
* fix: resolved merge conflicts with main and updated the codebase to remove the JSON stuff
* fix: addressing cargo clippy issues
* fix: typos
* fix: adding generated docs
* Update doc test snapshots
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Update offset_plane to actually create and show the plane in-engine
* Fix broken ability to use offsetPlanes in startSketchOn
* Make the newly-visible offset planes usable for sketching via UI
* Add a playwright test for sketching on an offset plane via point-and-click
* cargo clippy & cargo fmt
* Make `PlaneData` the first item of `SketchData` so autocomplete continues to work well for `startSketchOn`
* @nadr0 feedback re: `offsetIndex`
* From @jtran: "Need to call the ID generator so that IDs are stable."
* More feedback from @jtran and fix incomplete use of `id_generator` in last commit
* Oops I missed saving `isPathToNodeNumber` earlier 🤦🏻
* Make the distinction between `Plane` and `PlaneOrientationData` more clear per @nadr0 and @lf94's feedback
* Make `newPathToNode` less hardcoded, per @lf94's feedback
* Don't need to unbox and rebox `plane`
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Rearranging of enums and structs, but the offsetPlanes are still not used by their sketches
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Revert all my little newtype fiddling it's a waste of time.
* Update docs
* cargo fmt
* Remove log
* Print the unexpected diagnostics
* Undo renaming of `PlaneData`
* Remove generated PlaneRientationData docs page
* Redo doc generation after undoing `PlaneData` rename
* Impl FromKclValue for the new plane datatypes
* Clippy lint
* When starting a sketch, only hide the plane if it's a custom plane
* Fix FromKclValue and macro use since merge
* Fix to not convert Plane to PlaneData
* Make sure offset planes are `Custom` type
* SketchData actually doesn't need to be in a certain order
This avoids the autocompletion issue I was having.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* WIP: Fix linux updater 'mv' error
First commit to test the updater-test builds
* Downgrade electron-updater to 6.3.0
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Trigger CI
* Pin to 6.3.0
* Clean up
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix: big commit, doing this to save work then do a PR cleanup; center rectangle
* fix: making a center function for each scenario
* fix: reverting the update rectangle code since I have a center rectangle one
* fix: does not allow seletcing circle or rectangle tool while selecting a face
* chore: adding comment to better read the HTML
* fix: cleaning up for PR
* fix: pushing broken code for someone to checkout
* fix: fixed the typescript issues, removed the as keyword for my center rectangle expressions
* fix: removing comment
* fix: removed as for type narrowing checks
* Reapply "Deflake project settings override on desktop (#4370)" (#4450)
This reverts commit b11040c23c.
* Refactor writeToFile and updateCodeEditor to happen at appropriate times
* Turn error into warning about out of date AST.
* Rename setUp to setup
* ONLY reload current file on changes.
* If value is falsey then don't try to executeAst
* Fix up code based selections after constraints
* Correct any last missing code mods
* Update src/clientSideScene/ClientSideSceneComp.tsx
Remove eslint rule no-floating-promises
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Fixups
* Fix FileTree failing
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Rename ::from_mem_item to ::from_kcl_val
The old name is from a dark time lost to human memory,
when we had an enum called MemoryItem.
* Simplify the FromKclValue macros
There's only really need for one macro, not three.
Removes JSON from the KCL object model. Closes https://github.com/KittyCAD/modeling-app/issues/1130 -- it was filed on Nov 27 last year. Hopefully I close it before its one year anniversary.
Changes:
- Removed the UserVal variant from `enum KclValue`. That variant held JSON data.
- Replaced it with several new variants like Number, String, Array (of KCL values), Object (where keys are String and values are KCL values)
- Added a dedicated Sketch variant to KclValue. We used to have a variant like this, but I removed it as an experimental approach to fix this issue. Eventually I decided to undo it and use the approach of this PR instead.
- Removed the `impl_from_arg_via_json` macro, which implemented conversion from KclValue to Rust types by matching the KclValue to its UserVal variant, grabbing the JSON, then deserializing that into the desired Rust type.
- Instead, replaced it with manual conversion from KclValue to Rust types, using some convenience macros like `field!`
* Add on-click snapping behavior
* Fix math error with horizontal/vertical determination
* Move snap constant to where other sketch constants are
* fmt
* Fixing up some of the tests, some still need updating
* A couple other little PW test issues
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* Fix remaining tests that need updating
* Make `yarn lint` happy
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix description of angleToMatchLengthX
* Update docs
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* update doc regen instructions
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* Re-run CI after snapshots
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
* Add final error-less expectation to autocomplete test
* Fix failing test
* tweak to leave function in place
---------
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* Internal: Pass through `sweep.subType` in `expandSweep`
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* implement a simple startSketchOn / offsetPlane lint rule (#4384)
* Bump kittycad-modeling-cmds from 0.2.71 to 0.2.72 in /src/wasm-lib (#4356)
Bumps [kittycad-modeling-cmds](https://github.com/KittyCAD/modeling-api) from 0.2.71 to 0.2.72.
- [Commits](https://github.com/KittyCAD/modeling-api/compare/kittycad-modeling-cmds-0.2.71...kittycad-modeling-cmds-0.2.72)
---
updated-dependencies:
- dependency-name: kittycad-modeling-cmds
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump google-github-actions/upload-cloud-storage from 2.2.0 to 2.2.1 (#4364)
Bumps [google-github-actions/upload-cloud-storage](https://github.com/google-github-actions/upload-cloud-storage) from 2.2.0 to 2.2.1.
- [Release notes](https://github.com/google-github-actions/upload-cloud-storage/releases)
- [Changelog](https://github.com/google-github-actions/upload-cloud-storage/blob/main/CHANGELOG.md)
- [Commits](https://github.com/google-github-actions/upload-cloud-storage/compare/v2.2.0...v2.2.1)
---
updated-dependencies:
- dependency-name: google-github-actions/upload-cloud-storage
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Internal fix: make `expandPath` not assume path has associated sweep (#4386)
* Add a test that shows current error within `expandPath`
* Make `expandPath` not assume there is an associated sweep artifact
* Look at this (photo)Graph *in the voice of Nickelback*
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Bump happy-dom from 14.12.3 to 15.10.1 (#4404)
Bumps [happy-dom](https://github.com/capricorn86/happy-dom) from 14.12.3 to 15.10.1.
- [Release notes](https://github.com/capricorn86/happy-dom/releases)
- [Commits](https://github.com/capricorn86/happy-dom/compare/v14.12.3...v15.10.1)
---
updated-dependencies:
- dependency-name: happy-dom
dependency-type: direct:development
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump @electron-forge/maker-zip from 7.4.0 to 7.5.0 (#4394)
Bumps [@electron-forge/maker-zip](https://github.com/electron/forge) from 7.4.0 to 7.5.0.
- [Release notes](https://github.com/electron/forge/releases)
- [Changelog](https://github.com/electron/forge/blob/main/CHANGELOG.md)
- [Commits](https://github.com/electron/forge/compare/v7.4.0...v7.5.0)
---
updated-dependencies:
- dependency-name: "@electron-forge/maker-zip"
dependency-type: direct:development
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump uuid from 9.0.1 to 11.0.2 (#4393)
Bumps [uuid](https://github.com/uuidjs/uuid) from 9.0.1 to 11.0.2.
- [Release notes](https://github.com/uuidjs/uuid/releases)
- [Changelog](https://github.com/uuidjs/uuid/blob/main/CHANGELOG.md)
- [Commits](https://github.com/uuidjs/uuid/compare/v9.0.1...v11.0.2)
---
updated-dependencies:
- dependency-name: uuid
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump validator from 0.18.1 to 0.19.0 in /src/wasm-lib (#4396)
Bumps [validator](https://github.com/Keats/validator) from 0.18.1 to 0.19.0.
- [Changelog](https://github.com/Keats/validator/blob/master/CHANGELOG.md)
- [Commits](https://github.com/Keats/validator/commits)
---
updated-dependencies:
- dependency-name: validator
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump insta from 1.41.0 to 1.41.1 in /src/wasm-lib (#4400)
Bumps [insta](https://github.com/mitsuhiko/insta) from 1.41.0 to 1.41.1.
- [Release notes](https://github.com/mitsuhiko/insta/releases)
- [Changelog](https://github.com/mitsuhiko/insta/blob/master/CHANGELOG.md)
- [Commits](https://github.com/mitsuhiko/insta/compare/1.41.0...1.41.1)
---
updated-dependencies:
- dependency-name: insta
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump pyo3 from 0.22.5 to 0.22.6 in /src/wasm-lib (#4398)
Bumps [pyo3](https://github.com/pyo3/pyo3) from 0.22.5 to 0.22.6.
- [Release notes](https://github.com/pyo3/pyo3/releases)
- [Changelog](https://github.com/PyO3/pyo3/blob/v0.22.6/CHANGELOG.md)
- [Commits](https://github.com/pyo3/pyo3/compare/v0.22.5...v0.22.6)
---
updated-dependencies:
- dependency-name: pyo3
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump thiserror from 1.0.65 to 2.0.0 in /src/wasm-lib (#4397)
Bumps [thiserror](https://github.com/dtolnay/thiserror) from 1.0.65 to 2.0.0.
- [Release notes](https://github.com/dtolnay/thiserror/releases)
- [Commits](https://github.com/dtolnay/thiserror/compare/1.0.65...2.0.0)
---
updated-dependencies:
- dependency-name: thiserror
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump url from 2.5.2 to 2.5.3 in /src/wasm-lib (#4399)
Bumps [url](https://github.com/servo/rust-url) from 2.5.2 to 2.5.3.
- [Release notes](https://github.com/servo/rust-url/releases)
- [Commits](https://github.com/servo/rust-url/compare/v2.5.2...v2.5.3)
---
updated-dependencies:
- dependency-name: url
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Bump @types/ws from 8.5.12 to 8.5.13 (#4395)
Bumps [@types/ws](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/ws) from 8.5.12 to 8.5.13.
- [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases)
- [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/ws)
---
updated-dependencies:
- dependency-name: "@types/ws"
dependency-type: direct:development
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* File tree to act more like VS Code's file tree (#4392)
* File tree acts as VS Code's file tree
* Adjust test for new expectations
* Remove screenshot
* Actually remove this screenshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Fixing directory/file selection logic to deselect folders properly and always hightlight files. (#4408)
* File tree acts as VS Code's file tree
* Adjust test for new expectations
* Remove screenshot
* Actually remove this screenshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: fixed logic for selection
* fix: always show the current file
---------
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Bump happy-dom from 15.10.1 to 15.10.2 (#4409)
Bumps [happy-dom](https://github.com/capricorn86/happy-dom) from 15.10.1 to 15.10.2.
- [Release notes](https://github.com/capricorn86/happy-dom/releases)
- [Commits](https://github.com/capricorn86/happy-dom/compare/v15.10.1...v15.10.2)
---
updated-dependencies:
- dependency-name: happy-dom
dependency-type: direct:development
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Change Dependabot PR frequency to weekly (#4424)
* Update insta snapshots (#4423)
No meaningful changes, they just added a field to the frontmatter
* Fix KCL source ranges to know which source file they point to (#4418)
* Add ts_rs feature to work with indexmap
* Add feature for schemars to work with indexmap
* Add module ID to intern module paths
* Update code to use new source range with three fields
* Update generated files
* Update docs
* Fix wasm
* Fix TS code to use new SourceRange
* Fix TS tests to use new SourceRange and moduleId
* Fix formatting
* Fix to filter errors and source ranges to only show the top-level module
* Fix to reuse module IDs
* Fix to disallow empty path for import
* Revert unneeded Self change
* Rename field to be clearer
* Fix parser tests
* Update snapshots
* Change to not serialize module_id of 0
* Update snapshots after adding default module_id
* Move module_id functions to separate module
* Fix tests for console errors
* Proposal: module ID = 0 gets skipped when serializing tokens too (#4422)
Just like in AST nodes.
Also I think "is_top_level" communicates intention better than is_default
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Bump anyhow from 1.0.92 to 1.0.93 in /src/wasm-lib (#4417)
Bumps [anyhow](https://github.com/dtolnay/anyhow) from 1.0.92 to 1.0.93.
- [Release notes](https://github.com/dtolnay/anyhow/releases)
- [Commits](https://github.com/dtolnay/anyhow/compare/1.0.92...1.0.93)
---
updated-dependencies:
- dependency-name: anyhow
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Cut release v0.26.3 (#4427)
* Cut release v0.26.3
* Support new electron-builder env variable requirements for building in release mode
* Bump image from 0.25.3 to 0.25.5 in /src/wasm-lib (#4416)
Bumps [image](https://github.com/image-rs/image) from 0.25.3 to 0.25.5.
- [Changelog](https://github.com/image-rs/image/blob/main/CHANGES.md)
- [Commits](https://github.com/image-rs/image/compare/v0.25.3...v0.25.5)
---
updated-dependencies:
- dependency-name: image
dependency-type: direct:production
update-type: version-update:semver-patch
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* Nadro/3799/perf (#4145)
* chore: building out perf testing
* chore: adding my printing code for the different formats of the marks
* feat: adding invocation count table
* fix: markOnce iunstead
* fix: typescript additions
* fix: adding more types
* chore: adding telemetry panel as MVP, gonna remove the pane
* chore: view telemetry from command bar in file route and home route
* fix: deleting unused imports
* fix: deleting some unused files
* fix: auto cleanup
* chore: adding other routes, these will need to be moved...
* chore: moving some printing logic around and unit testing some of it
* fix: moving command init
* fix: removing debugging marks
* fix: adding some comments
* fix: fixed a bug with generating the go to page commands
* chore: adding will pages load within the router config
* chore: implementing marks for routes
* fix: auto fixes and checkers
* chore: implemented a route watcher at the root level...
* fix: auto fixes, removing unused code
* chore: timing for syntax highlighting and auto fixes
* fix: didAuth issue and syntax highlighting in the packaged application. Constructor name gets renamed
* fix: fixing typescript checks
* chore: adding mag bar chart icon for telemetry
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* chore: swapped telemetry icon for stopwatch
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* chore: writing telemetry to disk
* fix: auto fixers
* chore: getting args parsed for cli flags and writing telemetry file
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* chore: swapped mark for markOnce since we infinitely write marks to a JS array... need to solve this run time marking in another way. We only need this for startup right now
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* chore: writing raw marks to disk as well
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: cleaned up the testing names
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix fmt and codespell
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: moving this route loader data stuff
* chore: adding comment
* fix: fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* empty :(
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* empty :(
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
---------
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Paul Tagliamonte <paul@zoo.dev>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kevin Nadro <nadr0@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* fix: fixing on drag number inc/dec massive amount of unit tests
* fix: implemented all scenarios for inc/dec formatting
* fix: deleting unused code
* fix: clearer name
* fix: adding commments
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* fix: does this trigger the CI?
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: building out perf testing
* chore: adding my printing code for the different formats of the marks
* feat: adding invocation count table
* fix: markOnce iunstead
* fix: typescript additions
* fix: adding more types
* chore: adding telemetry panel as MVP, gonna remove the pane
* chore: view telemetry from command bar in file route and home route
* fix: deleting unused imports
* fix: deleting some unused files
* fix: auto cleanup
* chore: adding other routes, these will need to be moved...
* chore: moving some printing logic around and unit testing some of it
* fix: moving command init
* fix: removing debugging marks
* fix: adding some comments
* fix: fixed a bug with generating the go to page commands
* chore: adding will pages load within the router config
* chore: implementing marks for routes
* fix: auto fixes and checkers
* chore: implemented a route watcher at the root level...
* fix: auto fixes, removing unused code
* chore: timing for syntax highlighting and auto fixes
* fix: didAuth issue and syntax highlighting in the packaged application. Constructor name gets renamed
* fix: fixing typescript checks
* chore: adding mag bar chart icon for telemetry
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* chore: swapped telemetry icon for stopwatch
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* chore: writing telemetry to disk
* fix: auto fixers
* chore: getting args parsed for cli flags and writing telemetry file
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* chore: swapped mark for markOnce since we infinitely write marks to a JS array... need to solve this run time marking in another way. We only need this for startup right now
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* chore: writing raw marks to disk as well
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: cleaned up the testing names
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix fmt and codespell
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: moving this route loader data stuff
* chore: adding comment
* fix: fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* empty :(
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* empty :(
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Add ts_rs feature to work with indexmap
* Add feature for schemars to work with indexmap
* Add module ID to intern module paths
* Update code to use new source range with three fields
* Update generated files
* Update docs
* Fix wasm
* Fix TS code to use new SourceRange
* Fix TS tests to use new SourceRange and moduleId
* Fix formatting
* Fix to filter errors and source ranges to only show the top-level module
* Fix to reuse module IDs
* Fix to disallow empty path for import
* Revert unneeded Self change
* Rename field to be clearer
* Fix parser tests
* Update snapshots
* Change to not serialize module_id of 0
* Update snapshots after adding default module_id
* Move module_id functions to separate module
* Fix tests for console errors
* Proposal: module ID = 0 gets skipped when serializing tokens too (#4422)
Just like in AST nodes.
Also I think "is_top_level" communicates intention better than is_default
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* File tree acts as VS Code's file tree
* Adjust test for new expectations
* Remove screenshot
* Actually remove this screenshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* fix: fixed logic for selection
* fix: always show the current file
---------
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* File tree acts as VS Code's file tree
* Adjust test for new expectations
* Remove screenshot
* Actually remove this screenshot
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest-8-cores)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add a test that shows current error within `expandPath`
* Make `expandPath` not assume there is an associated sweep artifact
* Look at this (photo)Graph *in the voice of Nickelback*
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: implementing kclsamples in stand alone unit tests
* fix: fmt, lint, and tsc
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: fixed program memory and test file pattern. Don't know how to exclude though?
* fix: trying to fix the exclude logic
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* fix: bump CI
* fix:typo
* fix: had conflicting filters ope, now fixed
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Demonstrate simulation tests where we don't care about visuals, e.g. the double-map test.
The `just new-sim-test` now accepts an optional argument, `render_to_png` which can be either "true" or "false" (defaults to "true"). Tests like double_map that don't render anything can use false, rather than rendering an empty PNG with nothing in it.
This means the [tests under `no_visuals/`](https://github.com/KittyCAD/modeling-app/tree/v0.26.2/src/wasm-lib/tests/executor/inputs/no_visuals) can be entirely replaced by simulation tests. This is much better! For example, I moved `double_map.kcl` from a no_visuals test to a simulation test. Here's the file:
```
fn increment = (i) => {
return i + 1
}
xs = [0..2]
ys = xs
|> map(%, increment)
|> map(%, increment)
```
Previously the `no_visuals` test just checked that the program ran successfully without panicking. Now the simulation test lets you see the value of `xs` and `ys` and immediately see they're correct. If our map logic changes (for example, we have an off-by-one error and don't apply the `map` to the last element) it'll show up in the program memory snapshot.
* Visualize draft point when near axes (only works on XY rn due to quaternion rotation issue)
* Slightly better quaternion rotation
* Actually snap new profiles to the X and Y axis
* Add snapping behavior while dragging
* Fix flickering on non-XY planes
* Add some fixture additions to support click-and-drag tests
* Add new test to verify snapping behavior
* Make the editor test fixture auto-open and close as needed
* All feedback except absolute lines
* Use `lineTo` for lines that have snapped
* Get other existing tests passing after switching to `lineTo` when snapping
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Re-run CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
The idea behind this is to test all the various stages of executing KCL
separately, i.e.
- Start with a program
- Tokenize it
- Parse those tokens into an AST
- Recast the AST
- Execute the AST, outputting
- a PNG of the rendered model
- serialized program memory
Each of these steps reads some input and writes some output to disk.
The output of one step becomes the input to the next step. These
intermediate artifacts are also snapshotted (like expectorate or 2020)
to ensure we're aware of any changes to how KCL works. A change could
be a bug, or it could be harmless, or deliberate, but keeping it checked
into the repo means we can easily track changes.
Note: UUIDs sent back by the engine are currently nondeterministic, so
they would break all the snapshot tests. So, the snapshots use a regex
filter and replace anything that looks like a uuid with [uuid] when
writing program memory to a snapshot. In the future I hope our UUIDs will
be seedable and easy to make deterministic. At that point, we can stop
filtering the UUIDs.
We run this pipeline on many different KCL programs. Each keeps its
inputs (KCL programs), outputs (PNG, program memory snapshot) and
intermediate artifacts (AST, token lists, etc) in that directory.
I also added a new `just` command to easily generate these tests.
You can run `just new-sim-test gear $(cat gear.kcl)` to set up a new
gear test directory and generate all the intermediate artifacts for the
first time. This doesn't need any macros, it just appends some new lines
of normal Rust source code to `tests.rs`, so it's easy to see exactly
what the code is doing.
This uses `cargo insta` for convenient snapshot testing of artifacts
as JSON, and `twenty-twenty` for snapshotting PNGs.
This was heavily inspired by Predrag Gruevski's talk at EuroRust 2024
about deterministic simulation testing, and how it can both reduce bugs
and also reduce testing/CI time. Very grateful to him for chatting with
me about this over the last couple of weeks.
* fix auth test in engine
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* emoty
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add lsystem.kcl to tests
* Reduce iterations
* Fix the user settings flake shit (NOTE TO ALL FUTURE PEOPLE MODELING-APP DOES NOT WAIT FOR I/O IN SOME CASES BEFORE ROUTER NAVIGATION)
* Fix just lint to check all targets
* Fix yarn test:rust to lint all targets
* Remove redundant options
* Change cargo --all to --workspace
* Update readme to use just command
Without this, you can get a funny error message, such as:
assert failed because 42 != 42: number is not 42
I'm assuming an epsilon of zero is never useful because we're dealing
with floating point.
* accessing toast error correctly
* wrapping try-catch around fs.stat on cli arg
* implemented array push
* changing arg execution order for sketch arc
* addressing sketchFromKclValue error for Sketches in Uservals
* addressing 'update to He inside a test not wrapped in act(...' error
* yarn fmt fix
* implemented polygon stdlib function
* changing polygon inscribed arg description in docs
* addressing cargo clippy warning
* Add tangential arc unavailable reason tooltip
* fixing tsc errors
* preventing hidden dirs from showing up as projects and prohibits renaming projects as hidden
* adding unit test for desktop listProjects
* showing no completions when last typed word is a number
* fmt
* Make clippy happy
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* yarn tsc fix: added missing toast import in Home.tsx
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* regenerating markdown docs for incoming merge from main
---------
Co-authored-by: arnav <arnav@agupta.org>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Rename `homeMachine` and accessories to `projectsMachine`
* Separate out `/home` route from `projectsMachine`
* Add logic to navigate out from deleted or renamed project
* Show a warning in the command palette for deleting a project
* Make it navigate when you create a project
* Update "New project" button to use command bar flow
Closes#2585
* More explicit warning message text
* Make projects watching code not run in web
* Tests first version: nested loops
* Tests second version: flattened
* Remove console logs
* Fix tsc
* @jtran feedback, use the type guard util
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Fix tests that relied on one-click, no-navigation project creation
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 7545b61b49.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 3d2e48732c.
* Add a mask to the state indicator to client-side scale test
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix lint
* Fix tsc
* Fix a couple stray tests that still relied on the old way of creating projects
* De-flake another text that could be thrown off by toast-based selectors
* FMT
* Dumb test error because I was rushing
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Ahhh more flaky toasts, they're everywhere!
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
* Fix one test added since this PR was made
* Fix a few tests that failed due to changes since PR was made
* Prevent double selector issue in Ubuntu test
* Prevent *a different* double selector issue
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Tags can refer to either a surface, or a path. Tags track what they're
tagging with two fields: `Option<Path>` and `Option<Surface>`. This means
as more things can be tagged, we'll have a bunch of options and only one
can be Some at a given time. This should be an enum instead, so the
compiler can enforce that only one thing is being tagged.
Also I want to allow tags to refer to points, so I'd like to make this
enum before I add a new possible variant.
* Cut release v0.26.2
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add a radius length indicator to the circle sketch tool
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 15b078f641.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
See "Problem 2" in https://github.com/KittyCAD/modeling-app/issues/4297
This is a pure refactor, it should not change any behaviour at all.
It adds more information into the tag system, but nothing reads that
extra information yet. It will be used to address problem 3 of the above
issue.
* Update CameraControls.ts
* fix static analyzer error
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 0b63016217.
* Don't perform sketch click operations if a camera movement interaction also matches
* Don't `stopPropogation`, make selection listener early return if `wasDragging`
+ consolidate `wasDragging` set statements, add comments
* Codespell
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Separate debug/release electron-builder to help mac job
Will attempt to fix#4199
* Test BUILD_RELEASE: true
* Revert "Test BUILD_RELEASE: true"
This reverts commit f2c0c24432.
* Make electron test setting overrides not entirely replace default settings
* Add failing test
* Fix test by checking for healthy engine connection before executing demo code
* Fix one electron test that assumed all settings got wiped if you override any.
* 🤷🏻♂️ an engine-side camera position in one of the E2E tests changed by 0.01 randomly
* Buffer file writes, because writing to file after every keypress does bad things
* fix: kevin -- added timeouts for the time being since the workflow for saving data to disk is now changed
---------
Co-authored-by: Kevin Nadro <kevin@zoo.dev>
* Fix test settings to actually get used
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Export file size changed out from under us again, relax this test to just be above a reasonable size
* Missed on updated export expectation
* Wrong check, should just be greater than
* Fix E2E test, remove console log
* fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Sketchy rectangle commit fix
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Re-run CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 2ace7a3b0e.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Bump timeouts for snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Revert "KCL: Fix duplicate 'type' key"
This reverts commit f650281855.
* Revert "Remove duplicate "type" field in the snapshots (#4211)"
This reverts commit 824b4c823e.
* Remove duplicate "type" field in the snapshots
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Confirm
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Add syntax highlighting for comparison operators
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Confirm
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Split builds per os and per architecture to minimize artifacts size
Fixes#3920
* Add missing if case; Add nightly build updater support
* Fix linux x86_64
* Improve upload filtering
* Attempt to fix matrix
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Test release builds
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Clean up
* Clean up win arm64 builds
* Add temp fake-publish to check on artifacts
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Trigger CI
* Fix win arm
* Clean up
* Remove forced release builds
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Addresses #4080. (Not ready to close it yet.)
# Important
Requires a fix for #4147 before it can work in ZMA.
# Overview
```kcl
// numbers.kcl
export fn inc = (x) => {
return x + 1
}
```
```kcl
import inc from "numbers.kcl"
answer = inc(41)
```
This also implements multiple imports with optional renaming.
```kcl
import inc, dec from "numbers.kcl"
import identity as id, length as len from "utils.kcl"
```
Note: Imported files _must_ be in the same directory.
Things for a follow-up PR:
- #4147. Currently, we cannot read files in WebAssembly, i.e. ZMA.
- Docs
- Should be an error to `import` anywhere besides the top level. Needs parser restructuring to track the context of a "function body".
- Should be an error to have `export` anywhere besides the top level. It has no effect, but we should tell people it's not valid instead of silently ignoring it.
- Error message for cycle detection is funky because the Rust side doesn't actually know the name of the first file. Message will say "b -> a -> b" instead of "a -> b -> a" when "a" is the top-level file.
- Cache imported files so that they don't need to be re-parsed and re-executed.
* CI: Remove rust-cache from static analysis
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Look at this (photo)Graph *in the voice of Nickelback*
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Fixes#4150 by ignoring whitespace before a colon just like how whitespace after a colon is already ignored.
Added snapshot parser::parser_impl::snapshot_tests::bh for a kcl snippet that has whitespace before a colon.
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Closes#4021
Allows array ranges (e.g., `[0..10]`) to take expression instead of just numeric literals as their start and end values. Both expressions are required (we don't support `[0..]`, etc.).
I've created a new kind of expression in the AST. The alternative was to represent the internals of an array as some kind of pattern which could initially be fully explicit or ranges. I figured the chosen version was simpler and easier to extend to open ranges, whereas the latter would be easier to extend to mixed ranges or other patterns. I chose simpler, it'll be easy enough to refactor if necessary.
Parsing is tested implicitly by the tests of execution and unparsing.
---------
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
Previously, map was wrapping KCL values in a JSON object unnecessarily. The new `double_map` test would emit this error:
```
Syntax(KclErrorDetails {
source_ranges: [SourceRange([31, 32])],
message: "Invalid number: {\"type\":\"UserVal\",\"value\":1.0,\"__meta\":[{\"sourceRange\":[31,36]}]}"
})
```
In other words, the second `map` statement is being passed an array of JSON STRINGS, not an array of numbers.
The strings contain JSON stringified representations of user values which are numbers.
Bug is now fixed.
Josh Gomez requests pattern calculations take the total number of instances,
not the number of extra repetitions to do. This is how we designed the
patternTransform API, but we didn't do that for patternLinear/Circular.
* Add collapsible element to updater toast notification showing release notes
* Temp create release artifacts to test updater
* Fix tsc error
* Fix some styling, make release notes not appear if no notes are present
* Add component tests
* Remove test release builds
---------
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* add support for opposite and adjacent edges
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* update playwright
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* update unit tests
* enable button state checker for selections
* typos
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* trigger ci
* fix typo
* remove leave(node)
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* typo
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* pull getEdgeTagCall into a utility function
* mask model-state-indicator
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Rerun CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Rerun CI
* screenshot fix
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Don't mutate the user's `codeBasedSelections` when they apply a multi-selection constraint
* Fix to not mutate the input parameter
* Format
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Sort selections in order of appearance before applying `transformSecondarySketchLinesTagFirst`
* Add an integration test for this sorting behavior
* Remove console logs from test
* Upload release-notes.md on release
Contributes to #3984
* Test release builds with updater-test-release-notes
* Change to releaseNotesFile conf, tested locally
* Clean up for merge
* Add a loading toast when update download begins
* Temporarily turn on artifact builds to test
* fmt
* Oops forgot to rename where I used a type
* Update src/index.tsx
* Update src/index.tsx
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Add an `update-error` listener
* Flatten autoupdater hooks
* Revert "Temporarily turn on artifact builds to test"
This reverts commit e2e1991977.
* Switch branch to build-publish-apps on to this one
* Make the loading toast not attempt to display a version number
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* fmt
* Update .github/workflows/build-test-publish-apps.yml
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Pierre Jacquier <pierrejacquier39@gmail.com>
* Add ID generator to ExecState
* Change default plane IDs to be hardcoded
* Fix lint warning
* Add exposing ID generator as output of executor
* Change to use generated definition of ExecState in TS
* Fix IdGenerator to use camel case in TS
* Fix TS type errors
* Add exposing id_generator parameter
* Add using the previously generated ID generator
* wip: Add display of feature tree in debug pane
* Remove artifact graph augmentation
* Change default planes to use id generator instead of hardcoded UUIDs
* Fix to reuse previously generated IDs
* Add e2e test
* Change feature tree to be collapsed by default
* Remove debug prints
* Fix unit test to use execState
* Fix type to be more general
* Remove outdated comment
* Update derive-docs output
* Fix object display component to be more general
* Remove unused ArtifactId type
* Fix test to be less brittle
* Remove codeRef and pathToNode from display
* Fix to remove test.only
Co-authored-by: Frank Noirot <frank@zoo.dev>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Move plane conversion code to be next to type
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 3455cc951b.
* Rename file
* Rename components and add doc comments
* Revive the collapse button
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Confirm
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* bug: fixing multiple state issues with the engine and modeling app to enable/disable planes/axis/delete code
* fix: yarn tsc fmt lint xgen
* fix: adding a comment back that I deleted on accident
* fix: adding formatting back?
* fix: reverting syntax
* fix: removing click line tool because the line tool is automatically selected. Clicking this will exit
* fix: Fixed a E2E test that had a line tool workflow with no points
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* fix: added more documentation on the cut and release process
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Reload user settings when changed externally
* Fix to not use any
* Make sure listener doesn't already exist
* Fix up projects reloading
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* tentatively adding this
* Update src/components/ModelingMachineProvider.tsx
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Show shortcut in UI dialog
* Move command into modelingMachine action
* Add a menu item to the view menu
* Switch gizmo tests to use "deprecated" test setup in prep for new fixture-based test
* Add e2e test for center view to selection
* Bump @kittycad/lib to latest and fix tsc
* Bump @kittycad/lib to v2.0.7 to fix electron building
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Add syntax highlighting for if-else
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Fix CodeMirror syntax highlighting of variables without keyword
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: adding Kurt's fix for electron in the new CI CD files. Adding a forced failure to test
* chore: increasing max retry for electron to match the playwright browser retry count
* fix: debugging ci cd for playwright last report
* fix: changing the output dir for snapshot to a custom one to not overwrite the previous job runs failure
* fix: found out hidden files are excluded automatically, was a breaking change :(
* fix: output typo
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Delete test-results-snapshots/.last-run.json
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* fix: cleanup
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Delete test-results-snapshots/.last-run.json
* fix: removing this folder, should have been git ignored
* fix: do not need these anymore since the hidden files is fixed
* fix: removed hard coded failure for debugging
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: saving off package.json progress unit tests fail in main
* fix: implementing a one liner for unit tests
* fix: renaming test:unit:local
* chore: adding playwright tests
* fix: making package.json not destructive to keep same pipeline commands for now
* fix: reordering
* fix: added tags for OS tests, moved kill-port to dev depen
* fix: OS skipping at tag level
* fix: lint, fmt, tsc, etc...
* Look at this (photo)Graph *in the voice of Nickelback*
* fix: new formatting
* fix: removing the ci copy, do not like it
* Look at this (photo)Graph *in the voice of Nickelback*
* chore: updating readme with explanation on the commands for CI CD simulation locally
* fix: package.json command for unit test, removing cached breaking cache in unit tests
* fix: fixing copy and typos in README.md for CI CD section
* fix: adding a duplicate command for a better name. CI CD will use it in a future PR
* chore: trying to clean up the copy and commands for CI CD tests
* chore: porting the bash code in the YAML to a bash script then using matrix permutations to control the runtime
* fix: typos
* fix: another typo, missed these went porting to the bash script logic
* fix: I think I need the checkout action since it has the repo code?
* fix: wrote absolute path not the relative hidden path, ope
* fix: does this cache give me the yarn install of playwright?
* fix: yarn cannot find the binary, use the yarn command
* fix: remove all uses...?
* chore: adding bash script for electron runtimes
* fix: copy cleanup
* fix: typo when copy and pasting the exclude logic, ope
* fix: this is wrong
* fix: build:wasm is a requirement for yarn tsc
* fix: reorder?
* fix: renaming integrations to e2e
* fix: windows is complaining about a pipe issue in the bash script?
* fix: escaping double quotes in windows?
* chore: consolidating commands into 1 file and easier YAML configuation for electron
* chore: mapped multiple OS playwright browser into a single bash script
* fix: removing old bash scripts, renaming matrix jobs
* fix: missed deleting this when I added the if statements.
* chore: removing unused job, xstate typegen more more since v5
* fix: trying to get these two tests to pass on first try
* fix: auto fixes
* fix: removing old unit test command
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Log any Errors to stderr
This isn't perfect -- in fact, this is maybe not even very good at all,
but it's better than what we have today.
Currently, when we get an Erorr back from the WebSocket, we drop it in
kcl-lib. The web-app logs these to the console (I can't find my commit
doing that off the top of my head, but I remember doing it) -- so this
is some degree of partity.
This won't be very useful at all for wasm usage, but it will fix issues
with the zoo cli silently breaking with a "WebSocket Closed" error --
which is the same issue I was solving for in the desktop app too.
In the future perhaps this can be a real Error? I'm not totally sure
yet, since we can't align to the request-id, so we can't really tie it
to a specific call (yet).
* add to responses
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* add a test
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* clippy[
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* empty
* fix error
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates tests
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* docs
Signed-off-by: Jess Frazelle <github@jessfraz.com>
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Previously variable declaration required a keyword, e.g.
```kcl
let x = 4
const x = 4
var x = 4
```
These were all valid, and did the exact same thing. As of this PR, they're all still valid, but the KCL formatter will change them all to just:
```kcl
x = 4
```
which is the new preferred way to declare a constant.
But the formatter will remove the var/let/const keywords.
Closes https://github.com/KittyCAD/modeling-app/issues/3985
* Make web app warning banner in the middle of the screen and simpler
* Some dark mode styles were whack
* Better wording for second sentence
* Update text in popup and appearance of download link
* Make download link first in focus order
* chore: saving off package.json progress unit tests fail in main
* fix: implementing a one liner for unit tests
* fix: renaming test:unit:local
* chore: adding playwright tests
* fix: making package.json not destructive to keep same pipeline commands for now
* fix: reordering
* fix: added tags for OS tests, moved kill-port to dev depen
* fix: OS skipping at tag level
* fix: lint, fmt, tsc, etc...
* Look at this (photo)Graph *in the voice of Nickelback*
* fix: new formatting
* fix: removing the ci copy, do not like it
* Look at this (photo)Graph *in the voice of Nickelback*
* chore: updating readme with explanation on the commands for CI CD simulation locally
* fix: package.json command for unit test, removing cached breaking cache in unit tests
* fix: fixing copy and typos in README.md for CI CD section
* fix: adding a duplicate command for a better name. CI CD will use it in a future PR
* fix: this is wrong... removing it
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit f767dd46d4.
* fix: typos in README.md
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* wip on this
* wip on kcl-to-core tool
* Update conn_mock_core.rs
* stopping point
* wip
* use enum for is_mock for added versatility
* get at least circular patterns working to finish POC
* fmt
* fmt part 2
* Update Cargo.lock
* quick fix for tests
* quick fix
* more fixes
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu)
* get more cases of this working
* Update src/wasm-lib/kcl-to-core/src/conn_mock_core.rs
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu)
* kcl core gen plane code by default
* fmt
* fix build?
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix clippy errors
* Remove unneeded clippy allow
* post merge build fix attempt
* Add missing indexmap dependency
* Fix to use IndexMap instead of HashMap
* Migrate to kittycad-modeling-cmds
* fix build
* fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 991cdde15e.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit a4ae03c740.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 9a082e7c9f.
* Regenerate derive_docs
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit a8bdb35627.
* Fix e2e test failing by masking state indicator
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Confirm snapshot change
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm snapshot change
* Fix build from last merge with main
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Fix e2e test failing by masking state indicator
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Confirm snapshot change
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Confirm snapshot change
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
I had to revert https://github.com/KittyCAD/modeling-app/pull/4031 because it broke syntax highlighting. This is the same PR, but updated to fix syntax highlighting.
Highlighting broke because the KCL LSP could not determine how to autocomplete the `map` function. The first argument of `map` is `[KclValue]` and the LSP doesn't know any good suggestions for "any KCL value", so it error'd out. I am using the value `[0..9]` for this case now. Tested that syntax highlighting works again.
* Split builds per os and per architecture to minimize artifacts size
Fixes#3920
* Add missing if case; Add nightly build updater support
* Fix linux x86_64
I think when we make reduce work with objects,
we'll either keep the same function and make it
polymorphic, or we'll have namespaces/modules and
use Array.reduce and Object.reduce. Either way this
name can be changed.
* fix new file sketch mode issue
* initial extron app fixture
* Add tests for exiting sketch mode on file tree actions
* organise files
* before all after all clean up
* tweak after each
* makes typedKeys as unsafe
* update mask for draft line snapshots
* fix mask
* add fix again
* Preserve paragraph breaks in the KCL docs
The KCL docs on the website are hard to read, because they concatenate all
the paragraphs in my nicely-formatted docstrings in the stdlib functions
into one big paragraph. PR should fix this.
* Fix arc docs being split into two lines
The 'summary' section of the docs has a maximum line length, and if you
go over that length, your summary gets split into two lines weirdly.
Makes the arc docs shorter, so the summary is back to one line like
it should be.
* Update docs for pattern transform
* Add cameraProjection setting
* Add UI to toggle the user-level projection setting.
* Make cameraProjection setting respected at startup
* Add an E2E test for the perspective toggle
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Don't force user back into perspective when exiting sketch
* Make the projection setting more searchable
* Make `current` label apply to the default option if not set
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Re-run CI
* Ohh *cargo fmt*
* @lf94 feedback, fix found toggling bug, make command bar instantly toggle setting
* Roll back the instant toggling behavior, it breaks the tests
* Make ortho the default, keep tests using perspective
* Move projection below camera controls setting
* Fix up gizmo tests, which broke because the gizmo moved
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Look at this (photo)Graph *in the voice of Nickelback*
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Implement basic unit overwriting, update tests
* fix eslint warning
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 2ecf012c25.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* more recursive
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates;
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* fixes
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* add the format
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* get the descriptions again
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Also, there were some executor unit tests to test pattern transform. I realized they make more sense as example tests in the KCL stdlib for pattern transform. This way, they show up in the docs too. So I removed the unit tests (the examples now test these features instead).
Big thanks to Serena for fixing this on the engine side!
Also looks like the pictures from artifact graph were deleted, so GH Actions wants to put it back.
* Add event listener for theme media query to update engine theme
* tsc fixes
* Add a Playwright test for UI and engine theme switch
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Pattern transforms now have a new `rotation` parameter, letting you rotate each instance of the shape. Currently only rotation around the local origin (i.e. rotating the object around the center of its own bounding box) works correctly. Rotating around a global origin (i.e. center of the scene) will be fixed on the server side soon.
* sketch on chamfer start
* working
* step app from getting in weird state when selection face to sketch on
* sketch on chamfer tests
* clean up
* fix test
* fix click selections for chamfers, add tests
* fixture setup (#3964)
* initial break up
* rename main fixture file
* add more expect state pattern
* add fixture comment
* add comments to chamfer function
* typos
* works without pipeExpr
* Add custom updater model back after electron migration
Fixes#3872
* Enable release builds (temp)
* Lint & clean up
* Change approach to no user input, heads up with toast
* Re-enable prod builds
* Working toasts
* Only one toast
* Add missing type
* Clean up before review
* New toast design test
* Clean up
* Use theme colors, add link to changelog
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
* Add a shell script to get the list of KCL samples into the app
* Add support for overwriting current file with sample
* Move these KCL commands down into FileMachineProvider
* Add support for creating a new file on desktop
* Make it so these files aren't set to "renaming mode" right away
* Add support for initializing default values that are functions
* Add E2E tests
* Add a code menu item to load a sample
* Fix tsc issues
* Remove `yarn fetch:samples` from `yarn postinstall`
* Remove change to arg initialization logic, I was holding it wrong
* Switch to use new manifest file from kcl-samples repo
* Update tests now that we use proper sample titles
* Remove double-load from units menu test
* @jtran feedback
* Don't encode `https://` that's silly
* fmt
* Update e2e/playwright/testing-samples-loading.spec.ts
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Test feedback
* Add a test step to actually check the file contents were written to (@Irev-Dev feedback)
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Show user code while logging in
* fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* @jtran feedback
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 5ba9e4351a.
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* circle
* fix another example
* fix bad comment
* toPoint fix
* cargo fmt
* resolve most of the tests
* fix last test
* missed circle in bracket
* remove console error
* fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* trigger ci
* remove three dot menu for circle
* make sure circle can be extruded
* fix up after merge
* add extrude test for circle
* clean up
* typo
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 03f8eeb542.
* update docs again
* cmd bar test serialisation improvements
* tiny clean up
* fix after: Replace kittycad crate with kittycad-modeling-cmds
* fmt
* rename fix
* Update src/lib/toolbar.ts
Co-authored-by: Frank Noirot <frank@zoo.dev>
* add another error to list
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* image updates
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 505bb20bea.
* update markdown
* skip un reproducable windows test failure
* rust review
* leave issue todo comment
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* WIP: No more empty outputs from modeling API
Part of https://github.com/KittyCAD/modeling-api/issues/518
* Remove unused import
* Keep Empty in the API
* Fix TS type error due to upgrade to ts_rs 10.0.0
* Fix warning about unused use
* Fix more type errors from ts_rs upgrade
* De-flake settings override desktop test
* Update export test file sizes
---------
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
* bump the world
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit e095d2a990.
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* dumb ass logic bug with edge cuts
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* change order
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 1ad9eb315e.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 4004c9c1db.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 57d0d05d06.
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix: fixing logic around setting the perspective and position of perspective camera when leaving sketch mode
* fix: typo
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 60b12ffc54.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 9ab973c6c4.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* remove unused vars
* fix: fixed the positions of the mouse clicks since the zoom level has changed?
* fix: updating test to make it work with my new zoom level
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* Move file tree deletion tests into file-tree.spect.ts
* Move other file tree tests into file-tree.spec.ts
* Add tests that prove we show a deletion confirmation for folders
* Fix lint warning
lib.rs/kittycad-modeling-cmds is the source of our Modeling API. It gets included in our backend APIs, and those APIs generate OpenAPI specs which are read by `openapitor` which generates the lib.rs/kittycad crate. So basically, our modeling app is using the _generated code_ instead of the _handwritten code_.
This sucks -- if you add a new field to the modeling-api crate, you have to merge PRs to the engine, api-deux, and kittycad.rs before finally you can get the new field into the modeling-app. I was pretty embarrased when @mlfarrell asked how to get a new field into the modeling app and had to explain this whole bullshit cycle. Let's fix it.
Switching to use the kittycad-modeling-cmds (aka kcmc) crate directly should speed up our dev cycle.
* Bug fix: make dismiss during export not fire success toast
* Fix export fail test, since this failure errors early now
* Remove throttling from send side
* Move toast.loading out to when first engine command is sent, so it is shown immediately
* Use shared, named constants for toast messages
* Hook up a couple other error toasts to the `pendingExport.toastId`
* fix: just a one liner? forcing a revolve to be an extrude artifact
* fix: first step in renaming ExtrusionArtifact to SweepArtifact
* fix: renaming extrusion to sweep for a few things? need to do another pass
* fix: cleaning up comments, fixing unit tests for new key names
* fix: unit test update
* fix: removing TODO comments that are not needed
* fix: renaming more extrude/extrusion values to sweep
* fix: test:nowatch -u to update the vitests
* Look at this (photo)Graph *in the voice of Nickelback*
* fix: removing TODOs
* fix: forgot to update the extrudeEdge string in other files
* chore: adding e2e test to see if users can sketch on revolved face
* fix: removing garbage string
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* chore: Implemented a executeAst interrupt to stop processing a KCL program
* fix: added a catch since this promise was not being caught
* fix: fmt formatting, need to fix some tsc errors next.
* fix: fixing tsc errors
* fix: cleaning up comment
* fix: only rejecting pending modeling commands
* fix: adding constant for rejection message, adding rejection in WASM send command
* fix: tsc, lint, fmt checks
* feat: first pass over revolve with basic hard coded X axis
* fix: updated revolve status for DEV only
* fix: adding some TODOs to warn others about the Revolve MVP
* fix: fmt, lint, tsc checks
* fix: codespell got me
* fix: xstate v5 upgrade
* fix: removing this fix for a different PR. Not needed for initial MVP
* fix: renaming extrude function to sweep since it fixes extrude and revolve now
* fix: updating selection logic to support revolve
* fix: renaming extrude to sweep since it adds revolve
* fix: swapping as for type in function parameters
* fix: updated from object destruct to structuredClone
* fix: addressing PR comments
* fix: one other typo for return value of revolve
* Make light theme borders more contrasting
* Update icons in sidebar
* fix disabled styles on ActionIcon
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Update src/components/CustomIcon.tsx
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* trigger CI
* fmt
* Update "Make" button test locator to be more specific
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Add ExecState that combines ProgramMemory and DynamicState
* Remove unneeded clones
* Add exec_state parameter to all KCL stdlib functions
* Move pipe value into ExecState
* Add test for pipe substitution not leaking into function calls
* KCL: Better message on assertEqual function
Also add a new no-visual test for performance testing.
* Fix new array module to use ExecState
---------
Co-authored-by: Adam Chalmers <adam.chalmers@zoo.dev>
* Add updater-test back after electron migration
Fixes#3871
* Separate updater-test files more
* Push dummy 0.999.999 version to updater-test
* Push 0.255.255
* Revert dummy push commits
* Clean up
* initial console error whitelist
* add testInfo to the beforeEach
* set COLLECT_CONSOLE_ERRORS
* add more console errors
* temporarily set max_retrys to 0 instead of 4
* more console errors
* revert max retries back to 4
* add 'necessary' to complete sentence
* tweak env var name
* update whitelist
* test disabling flag
* update whitelist
* lint + enable for chrome only
* re-enabled on CI
* re-order whitelist
* create failOnConsoleErrors
* try update list
* add more to list
* tweak list again
* tweak again<
* tweak again
* tweak
* testInfo
* increase timeout
---------
Co-authored-by: ryanrosello-og <ry@zoo.dev>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
Adds an `arrayReduce` function to KCL stdlib. Right now, it can only reduce SketchGroup values because my implementation of higher-order KCL functions sucks. But we will generalize it in the future to be able to reduce any type.
This simplifies sketching polygons, e.g.
```
fn decagon = (radius) => {
let step = (1/10) * tau()
let sketch = startSketchAt([
(cos(0) * radius),
(sin(0) * radius),
])
return arrayReduce([1..10], sketch, (i, sg) => {
let x = cos(step * i) * radius
let y = sin(step * i) * radius
return lineTo([x, y], sg)
})
}
```
Part of #3842
* Update Onboarding Bracket
* update KCL header
* update text to go to last character in onboarding code and delete for error reporting
* update allowable tensile stress
* Update test
* fix text
* run prettier
* Make error message in tooltip not matter
* Image asset path needs to be relative on desktop
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* refactor clientSide scene
* start consolidate threejs segment funcitons
* rename stuff
* first pass of integrating threejs segment create and update into one
* reduce create segment complexity
* add color back in
* use input
* fix comment
* feedback changes
* test
* test + selection loop
* wipe as
* multi body multi fillet test
* make eslint happy again
* as fatality
* Revert "make eslint happy again"
This reverts commit 21a966b9b0.
* lint error fix
* Use Inter 4.0 as sans-serif font
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Host the Inter font locally
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Re-run CI
* Just use the variable font, it's the future
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Update test to expect new behavior (failing)
* Update behavior to match new test expectations
* Make reset button more clear
* Fix eslint issue
* Fix up separate test that relied on old reset logic
* bug: fixing the position and display of the segment labels during sketch mode
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: minor visual tweaks
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: adding border styling
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* feat: aligned the text to the slope of the line drawn
* fix: tsc, lint, fmt
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* fix: linter warnings for unused variable
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add lints for floating and misued promises
* Add logging async errors in main
* Add async error catch in test-utils
* Change any to unknown
* Trap promise errors and ignore more await warnings
* Add more ignores and toSync helper
* Fix more lint warnings
* Add more ignores and fixes
* Add more reject reporting
* Add accepting arbitrary parameters to toSync()
* Fix more lints
* Revert unintentional change to non-arrow function
* Revert unintentional change to use arrow function
* Fix new warnings in main with auto updater
* Fix formatting
* Change lints to error
This is what the recommended type checked rules do.
* Fix to properly report promise rejections
* Fix formatting
* Fix formatting
* Remove unused import
* Remove unused convenience function
* Move type helpers
* Fix to not return promise when caller doesn't expect it
* Add ignores to lsp code
* migrate settingsMachine
* Guard events with properties instead
* migrate settingsMachine
* Migrate auth machine
* Migrate file machine
* Migrate depracated types
* Migrate home machine
* Migrate command bar machine
* Version fixes
* Migrate command bar machine
* Migrate modeling machine
* Migrate types, state.can, state.matches and state.nextEvents
* Fix syntax
* Pass in modelingState into editor manager instead of modeling event
* Fix issue with missing command bar provider
* Fix state transition
* Fix type issue in Home
* Make sure no guards rely on event type
* Fix up command bar submission logic
* Home machine tweaks to get things running
* Fix AST fillet function args
* Handle "Set selection" when it is called by actor onDone
* Remove unused imports
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Fix injectin project to the fileTree machine
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit 4b43ff69d1.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
* Restore success toasts on file/folder deletion
* Replace casting with guarding against event.type
* Remove console.log
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
* Replace all instances of event casting with guards against event.type
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
Adds a new KCL executor benchmark which builds a `10` wide by `n` tall lego, with varying `n`. The benchmark runs a n = 1, 2, 3 etc build, so we can get an idea of how the speed changes with size.
This change improves execution speed by 25-36% depending on how many bumps there are. Tested by:
* Rust unit tests
* Open up modeling app, sketch a square, use the command palette to extrude it
* Open up the Bambu printer "poop chute" model, it all extrudes and works fine
Also fixes a bug: extrude, loft, revolve all trigger a GetExtrusionFaceInfo command. Due to a bug, the GetExtrusionFaceInfo command reused the Command ID from the previous extrude/loft/revolve. Fixed that.
* Make code editor go zoom again (reason: parsing is slow)
* Never build wasm bundle in dev mode
---------
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* Fix "Text-to-CAD functionality" electron test
* Make "Closing settings modal should go back..." test not run order-dependent
* Seeing if paneOpen is part of the run order-dependent story
* Fix mistake in selector for text-to-cad test
* Add resiliency to a couple flakes
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Update package.json
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Add Electron app drag handle to sign-in page
* Don't assign drag regions in web from JSX, results in dev-only console errors about unsupported style values
* chore: Implemented electron playwright test to swap between a small cube and large lego
* fix: updating comment
* fix: added debug panel and execution done calls
* fix: yarn tsc, fmt, lint
* fix: updating lint warnings
* fix: removing testing line of code that hangs forever :(
* fix: trying a longer timeout
* fix: narrowing the scope to not get multiple elements
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Cut release v0.25.0
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
---------
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@zoo.dev>
* Fix the project directory setting assignment from file
* Fix default project directory value initialization
* Add a couple tests for loading the app without project directory settings
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* trigger CI
* Object merging logic was bad, blew away other app settings if they existed
* Update silly little export file size expectation numbers
* Make rename timeout in test way shorter
* Fix silly little test issues
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* Remove isFirstRender because isExecuting means the same and remove building scene
* add small makefile util
* Remove waiting for building scene prompt
* Add a new model state indicator
* fmt lint tsc
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
* Some colors and export file size changes occurred engine-side, update tests to match
* Fix up focusrite example after adjacent edge switch
* Yay now the export file is yet another new size
* Update bracket example code and some test colors that broke
* Use a shorter KCL sample so we don't experience weird locator behavior
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* bump electron playwright timeout
* Relax color expectations a little bit, as they can be different on web and electron
* fix double export test
* unused var
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Re-run CI
* Bump getGreatestPixDiff comparisons from 10 to 15 in projects.spec.ts
* bump another pix diff to 15
* make retries work
* update expect numbers
* remove some logs
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
* WIP: enable build releases
Will eventually fix#3528
* Build on all branches
* WIP: electron-forge publish to gcs
* WIP env var
* WIP windows
* WIP checkout in publish
* Back to matrix for build-apps and upstream wasm build
* WIP
* WIP
* WIP
* WIP
* WIP
* WIP
* WIP clean up out upload with all dry runs
* WIP macos
* Clean up
* Add update-electron-app
* Bump version down to 0.24.11
* Explicit NODE_ENV=production
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Push dummy version 0.99.99
* Undo
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Trigger CI
* Lint
* Experiment with DMG and MSI
* Split up artifacts
* Executable name to Zoo Modeling App
* Linux kebab-case exe, autoUpdate on wix
* Experiment with electron-builder
* WIP
* fail-fast false
* tronb:vite
* DMG and NSIS
* Typo
* Disable updater for electron-builder tests, quick fix
* WIP macOS sign and notarize
* WIP Win signing
* CSC_FOR_PULL_REQUEST
* Comment out signingHashAlgorithms
* APPLE_APP_SPECIFIC_PASSWORD and move scripts
* notarize: true and change script link
* mac.notarize.teamid
* Clean up and first steps on auto updater
* Lint
* Add logs
* Work on nsis config
* More extensive configs
* Clean up
* Test push updater
* Push again; Fix lint
* Bump down to 0.24.11 to test, disable publish
* WIP mac updater
* Back to .12 to push zips
* Back to .11 to test
* Back to .12 to push to same dir
* Fix windows and names
* Back to .11 to test, no publish
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Push again .12
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Add publisherName as in certificate
* Back to 11 build
* Add msi target
* MSI params
* perMarchine: false
* .12 msi push
* WIP tauri bundle generation (macOS)
* Typo
* Universal build mac
* Test last_update tauri gen for macOS
* VERSION fix
* Add v to VERSION
* Add v to VERSION part 2
* Fix tar
* WIP windows updater
* WIP windows
* Change Compress-Archive to 7z on Windows
* 7z change
* Fix flag
* -mm Deflate
* -mm Copy and version .99
* perMachine true
* perMachine true
* Manual autoUpdater.quitAndInstall
* Test NSIS for tauri transition
* WIP
* No more universal for mac, last_download.json endpoint
* Typo in json
* Tweaks
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Fix typo in download.json
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 0d6d67ec2c.
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit b01bc589ab.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)"
This reverts commit 5deff7614f.
* Fix tauri update json for universal to arch specified
* Fix tauri update json for universal to arch specified part 2
* Fix tauri update json for universal to arch specified part 3
* Back to checkUpdateAndNotify, frames on window
* Clean up
* Default prod env values
* CI clean up
* More clean up
* Override if forge env not set
* Make basic-sketch test more robust
* Fix env vars set
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: 49lf <ircsurfer33@gmail.com>
* chore: Implemented a executeAst interrupt to stop processing a KCL program
* fix: added a catch since this promise was not being caught
* fix: fmt formatting, need to fix some tsc errors next.
* fix: fixing tsc errors
* fix: cleaning up comment
* fix: only rejecting pending modeling commands
* fix: adding constant for rejection message, adding rejection in WASM send command
* fix: tsc, lint, fmt checks
* fix circ dependency
---------
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
Previously, many KCL values could be deserialized as KCL None values.
This isn't good -- the only thing you should be able to possibly
deserialize as KCL None is KCL None.
Solution was to add a private field in KCL None, serialize it with a
special magic number value, and then check for that magic number when
deserializing
* Basic sign-in page layout
* Better responsive styling
* Add wipe animation
* Fix mobile button styling
* Add juicy on-load animation to logo in app header
* Make video card a link to the sample's code
* Fix video URL on bundled desktop app, add "open default browser" behavior to links
* Revert "Add juicy on-load animation to logo in app header"
This reverts commit c167569d7e.
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* Fix: regression on command bar buttons (remove drag)
* Revert "Fix: regression on command bar buttons (remove drag)"
This reverts commit 2404bcdf31.
* Make all elements opt-out of drag behavior by default, add comments around drag attribute
* Add vendor-specific user-select
* It won't do to make all elements opt-out, it ends up swallowing the drag events themselves!
* Sneaking in this email truncation nit that's bothered me
* Gotta remove that one more attempt at a generic "we made this clickable" element
* Make orbit continue to work when dragging over the AppHeader
---------
Co-authored-by: Frank Noirot <frank@kittycad.io>
* ensure auth device token is saved to a file so it persists upgrades and reinstalls
#3639
* write file on check log in
* write file on check log in
* clean up
* Change mouse controls display to be easier to understand
* Fix to not duplicate default camera controls
* Change "Scroll wheel" to "Scroll" on all platforms
* addFillet.ts - refactor existing code
* move logic from modelingMachine to addFillet
* rename getPathForSelection into getPathToExtrudeForSegmentSelection
* stuck with kclManager
* stuck 2
* remove engineless exe from fillet test
* pathToExtrudeNode properly tested
* resolve conflicts
* engine initialization update
* cleanup comments
* passed ExecuteArgs instead of Program to executeAst
* afterAll engineCommandManager.tearDown
* resolve conflicts
* mutateAstForRadiusInsertion
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* save banner from hulk mutations
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* sweet errors
* purging the as
* make type of getNodeFromPath safe again
* as cleaning part 2
* cleared mutation logic
* last bits
* make the linter happy
---------
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* fix: Updating the playwright tests section
* fix: cleaning up formatting for playwright test markdown
* fix: autocomplete put a 3rd *
* chore: e2e playwright for change of base unit in multiple scenarios
* fix: fmt auto format
* fix: fmt and clean up for PR
* fix: removing typo
* fix: added the ) formatting back
* fix: linting errors + formatting
* fix: removing unused testing code from previous logic
---------
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Part of https://github.com/KittyCAD/engine/issues/2504:
The engine accepts this 'replay' flag now, so, accept it too and send it up to the engine.
Part of https://github.com/KittyCAD/cli/issues/847
The engine sends 'session data' now (like the API Call ID). The CLI executes KCL using this executor, and would like to get the session data after execution.
* Fix Commands button to show correct shortcut
* Fix onboarding to use the same shortcut reference
* Rename test file to be more general
* Add test for commands button text
* Remove outdated reference to Ctrl+/
* Change shortcut separator to be + and no spaces
* Add JSDocs and improve comments
* Add unit tests
* Change control modifier to regular ASCII caret
* Add browser test and fix platform detection
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Add useful debug info to the error message
* Fix to display metaKey as Super on Linux
* Revert "A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)"
This reverts commit f8da90d5d2.
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Approve snapshots
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* Test: Can load a file with CRLF line endings #3616
* first arg stuff??
* Fix paths in playwright for windows
* Fix line ending replace on windows
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: Adam Sunderland <iterion@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: Adam Sunderland <adam@kittycad.io>
* Don't chop off file name from file path
* Add a test to confirm file deletion works (as long as you have a main.kcl)
* Add TODO test for when main.kcl doesn't exist
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* Make the bad prompt test generate a new prompt each run
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
Co-authored-by: Jonathan Tran <jonnytran@gmail.com>
Co-authored-by: 49fl <ircsurfer33@gmail.com>
* exporting createProjectAndRenameIt, going to be used for a third time
* feat: added e2e test to test project name retention after onboarding plays
* fix: formatting, adding Page type
* fix: resolved linter warnings, wrong syntax and function name typo
* Fix path splitting issues on windows
* Fix path splitting issue on routeLoaders
* Enable some e2e tests
* Swap enabled e2e tests
* Working bare-min project parse
* Make tsc happy
* Clean up & enable more tests
* Fix paths in browser
* Fix tests for windows
fmt
* Clean up wasm side
* Make build:wasm windows compatible
* More paths cleanup & some tests
* Remove sleep
* Use new config sturcture in parseroute
* Clean up debugger
* Fix: on settings close go back to the same file (#3549)
* Fix: on settings close go back to the same file
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* shit aint working yo
* Get that page a-loading
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* Fmt
* Comment out currently failing win32 tests
* Ignore tsc for electron monkey-patch
* Force line-endings to only
* Fix tsc
* Enable more tests
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* Avoid modifying global for tests
---------
Co-authored-by: 49fl <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Frank Noirot <frank@kittycad.io>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* Fix existing: Extrude from command bar selects extrude line after #3545
* remove as
---------
Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
We can store Rust types like `SketchGroup` as their own variant of `KclValue`, or as `KclValue::UserVal`. Sometimes we store in one and try to read from the other, which fails. This causes bugs, like #3338.
Instead, we should use either ::SketchGroup or ::UserVal, and stop using the other. If we stopped using ::UserVal, we'd need a new variant for every Rust type we wanted to build, including user-defined types. So I don't think that's practical.
Instead, we should store every KCL value by de/serializing it into UserVal. This is a first step along that path, removing just the SketchGroup variants. If it goes well, we can remove the other specialized variants too.
My only concern is there might be performance implications from how frequently we convert between serde_json::Value and Rust types via Serde. But I'm not too worried -- there's no parsing JSON strings, just traversing serde_json::Value trees. This isn't great for performance but I think it'll probably be miniscule in comparison to doing all the API calls.
* Add the unexpected token to the error message
This is helpful during development where there's nothing to point at
the character index.
* Update more tests
* Fix the behavior so that we navigate to the new file path
* This change is done in other PRs but is also necessary here
* Add an Electron Playwright test for renaming a file
* Add tests for renaming dir, one is failing
* Don't need that console.warn
* Add DeepPartial utility type
* Fix settings parsing so that project path parsing is fixed
* Move URL check after DOM checks
* Revert this fallback behavior from https://github.com/KittyCAD/modeling-app/pull/3564 as we don't need it now that config parsing is fixed
* Make new bad prompt each run
* Fix onboarding asset path in web
* Remove double parsing of settings config
* Remove unused imports
* More unused imports
* Fix broken rename test
* Update src/lib/desktop.ts
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Add test for renaming file we do not have open
* fmt
---------
Co-authored-by: Kurt Hutten <k.hutten@protonmail.ch>
* Add electron test for persisting open panes
* Debugging persistence across test runs
* Trigger addInitScript for electron
* Remove init of PERSIST_MODELING_CONTEXT key
* Remove unused code
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
---------
Co-authored-by: 49lf <ircsurfer33@gmail.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* Fix to convert electron platform name darwin to macos
* Remove unneeded async
* Fix to handle other possible platform strings
* Add electron test for user sidebar menu text
* Fix formatting
* fix app version, make more dry
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* updates
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* empty
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
* empty
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* A snapshot a day keeps the bugs away! 📷🐛 (OS: windows-latest)
* empty
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
* Fix a couple issues with settings reset on web & electron
* A snapshot a day keeps the bugs away! 📷🐛 (OS: ubuntu-latest)
---------
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Co-authored-by: Jess Frazelle <jessfraz@users.noreply.github.com>
* electron test code with error loading
Signed-off-by: Jess Frazelle <github@jessfraz.com>
* Look at this (photo)Graph *in the voice of Nickelback*
---------
Signed-off-by: Jess Frazelle <github@jessfraz.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Compared to other CAD software, getting Zoo Modeling App up and running is quick and straightforward across platforms. It's about 100MB to download and is quick to install.
## Windows
1. Download the [Zoo Modeling App installer](https://zoo.dev/modeling-app/download) for Windows and for your processor type.
2. Once downloaded, run the installer `Zoo Modeling App-{version}-{arch}-win.exe` which should take a few seconds.
3. The installation happens at `C:\Program Files\Zoo Modeling App`. A shortcut in the start menu is also created so you can run the app easily by clicking on it.
## macOS
1. Download the [Zoo Modeling App installer](https://zoo.dev/modeling-app/download) for macOS and for your processor type.
2. Once downloaded, open the disk image `Zoo Modeling App-{version}-{arch}-mac.dmg` and drag the applications to your `Applications` directory.
3. You can then open your `Applications` directory and double-click on `Zoo Modeling App` to open.
## Linux
1. Download the [Zoo Modeling App installer](https://zoo.dev/modeling-app/download) for Linux and for your processor type.
2. Install the dependencies needed to run the [AppImage format](https://appimage.org/).
- On Ubuntu, install the FUSE library with these commands in a terminal.
```bash
sudo apt update
sudo apt install libfuse2
```
- Optionally, follow [these steps](https://github.com/probonopd/go-appimage/blob/master/src/appimaged/README.md#initial-setup) to install `appimaged`. It is a daemon that makes interacting with AppImage files more seamless.
- Once installed, copy the downloaded `Zoo Modeling App-{version}-{arch}-linux.AppImage` to the directory of your choice, for instance `~/Applications`.
- `appimaged` should automatically find it and make it executable. If not, run:
download at [zoo.dev/modeling-app/download](https://zoo.dev/modeling-app/download)
A CAD application from the future, brought to you by the [Zoo team](https://zoo.dev).
@ -57,7 +57,7 @@ yarn install
followed by:
```
yarn build:wasm-dev
yarn build:wasm
```
or if you have the gh cli installed
@ -66,15 +66,15 @@ or if you have the gh cli installed
./get-latest-wasm-bundle.sh # this will download the latest main wasm bundle
```
That will build the WASM binary and put in the `public` dir (though gitignored)
That will build the WASM binary and put in the `public` dir (though gitignored).
finally, to run the web app only, run:
Finally, to run the web app only, run:
```
yarn start
```
If you're not an KittyCAD employee you won't be able to access the dev environment, you should copy everything from `.env.production` to `.env.development` to make it point to production instead, then when you navigate to `localhost:3000` the easiest way to sign in is to paste `localStorage.setItem('TOKEN_PERSIST_KEY', "your-token-from-https://zoo.dev/account/api-tokens")` replacing the with a real token from https://zoo.dev/account/api-tokens ofcourse, then navigate to localhost:3000 again. Note that navigating to localhost:3000/signin removes your token so you will need to set the token again.
If you're not an KittyCAD employee you won't be able to access the dev environment, you should copy everything from `.env.production` to `.env.development` to make it point to production instead, then when you navigate to `localhost:3000` the easiest way to sign in is to paste `localStorage.setItem('TOKEN_PERSIST_KEY', "your-token-from-https://zoo.dev/account/api-tokens")` replacing the with a real token from https://zoo.dev/account/api-tokens ofcourse, then navigate to localhost:3000 again. Note that navigating to `localhost:3000/signin` removes your token so you will need to set the token again.
### Development environment variables
@ -91,17 +91,17 @@ Third-Party Cookies".
## Desktop
To spin up the desktop app, `yarn install` and `yarn build:wasm-dev` need to have been done before hand then
To spin up the desktop app, `yarn install` and `yarn build:wasm` need to have been done before hand then
```
yarn electron:start
yarn tron:start
```
This will start the application and hot-reload on changed.
This will start the application and hot-reload on changes.
Devtools can be opened with the usual Cmd/Ctrl-Shift-I.
Devtools can be opened with the usual Cmd-Opt-I (Mac) or Ctrl-Shift-I (Linux and Windows).
To build, run `yarn electron:package`.
To build with electron-builder, run `yarn tronb:package:dev` (or `yarn tronb:package:prod` to point to the .env.production variables)
## Checking out commits / Bisecting
@ -110,8 +110,7 @@ Which commands from setup are one off vs need to be run every time?
The following will need to be run when checking out a new commit and guarantees the build is not stale:
```bash
yarn install
yarn wasm-prep
yarn build:wasm-dev # or yarn build:wasm for slower but more production-like build
yarn build:wasm
yarn start # or yarn build:local && yarn serve for slower but more production-like build
```
@ -129,39 +128,63 @@ Before you submit a contribution PR to this repo, please ensure that:
## Release a new version
#### 1. Bump the versions by running `./make-release.sh` and create a Cut Release PR
#### 1. Create a 'Cut release $VERSION' issue
That will create the branch with the updated json files for you:
- run `./make-release.sh` or `./make-release.sh patch` for a patch update;
- run `./make-release.sh minor` for minor; or
- run `./make-release.sh major` for major.
It will be used to document changelog discussions and release testing.
After it runs you should just need the push the branch and open a PR.
**Important:** It needs to be prefixed with `Cut release v` to build in release mode and a few other things to test in the best context possible, the intent would be for instance to have `Cut release v1.2.3` for the `v1.2.3` release candidate.
#### 2. Push a new tag
The PR may then serve as a place to discuss the human-readable changelog and extra QA. The `make-release.sh` tool suggests a changelog for you too to be used as PR description, just make sure to delete lines that are not user facing.
Create a new tag and push it to the repo. The `semantic-release.sh` script will automatically bump the minor part, which we use the most. For instance going from `v0.27.0` to `v0.28.0`.
#### 2. Smoke test artifacts from the Cut Release PR
```
VERSION=$(./scripts/semantic-release.sh)
git tag $VERSION
git push origin --tags
```
The release builds can be find under the `artifact` zip, at the very bottom of the `ci` action page for each commit on this branch.
This will trigger the `build-apps` workflow, set the version, build & sign the apps, and generate release files as well as updater-test artifacts.
We don't have a strict process, but click around and check for anything obvious, posting results as comments in the Cut Release PR.
The workflow should be listed right away [in this list](https://github.com/KittyCAD/modeling-app/actions/workflows/build-apps.yml?query=event%3Apush)).
The other `ci` output in Cut Release PRs is `updater-test`, because we don't have a way to test this fully automated, we have a semi-automated process. Download updater-test zip file, install the app, run it, expect an updater prompt to a dummy v0.99.99, install it and check that the app comes back at that version (on both macOS and Windows).
#### 3. Manually test artifacts
#### 3. Merge the Cut Release PR
##### Release builds
This will kick the `create-release` action, that creates a _Draft_ release out of this Cut Release PR merge after less than a minute, with the new version as title and Cut Release PR as description.
The release builds can be found under the `out-{arch}-{platform}` zip files, at the very bottom of the `build-apps` summary page for the workflow (triggered by the tag in 2.).
Manually test against this [list](https://github.com/KittyCAD/modeling-app/issues/3588) across Windows, MacOS, Linux and posting results as comments in the issue.
##### Updater-test builds
The other `build-apps` output in the release `build-apps` workflow (triggered by 2.) is `updater-test-{arch}-{platform}`. It's a semi-automated process: for macOS, Windows, and Linux, download the corresponding updater-test artifact file, install the app, run it, expect an updater prompt to a dummy v0.255.255, install it and check that the app comes back at that version.
The only difference with these builds is that they point to a different update location on the release bucket, with this dummy v0.255.255 always available. This helps ensuring that the version we release will be able to update to the next one available.
If the prompt doesn't show up, start the app in command line to grab the electron-updater logs. This is likely an issue with the current build that needs addressing (or the updater-test location in the storage bucket).
Head over to https://github.com/KittyCAD/modeling-app/releases, the draft release corresponding to the merged Cut Release PR should show up at the top as _Draft_. Click on it, verify the content, and hit _Publish_.
Head over to https://github.com/KittyCAD/modeling-app/releases/new, pick the newly created tag and type it in the _Release title_ field as well.
#### 5. Profit
Hit _Generate release notes_ as a starting point to discuss the changelog in the issue. Once done, make sure _Set as the latest release_ is checked, and hit _Publish release_.
A new Action kicks in at https://github.com/KittyCAD/modeling-app/actions, which can be found under `release` event filter.
A new `publish-apps-release` will kick in and you should be able to find it [here](https://github.com/KittyCAD/modeling-app/actions?query=event%3Arelease). On success, the files will be uploaded to the public bucket as well as to the GitHub release, and the announcement on Discord will be sent.
#### 5. Close the issue
If everything is well and the release is out to the public, the issue tracking the release shall be closed.
## Fuzzing the parser
@ -189,12 +212,22 @@ For more information on fuzzing you can check out
### Playwright tests
You will need a `./e2e/playwright/playwright-secrets.env` file:
```bash
$ touch ./e2e/playwright/playwright-secrets.env
$ cat ./e2e/playwright/playwright-secrets.env
token=<dev.zoo.dev/account/api-tokens>
snapshottoken=<your-snapshot-token>
```
For a portable way to run Playwright you'll need Docker.
#### Generic example
After that, open a terminal and run:
```bash
docker run --network host --rm --init -it playwright/chrome:playwright-1.43.1
docker run --network host --rm --init -it playwright/chrome:playwright-x.xx.x
```
and in another terminal, run:
@ -203,21 +236,27 @@ and in another terminal, run:
PW_TEST_CONNECT_WS_ENDPOINT=ws://127.0.0.1:4444/ yarn playwright test --project="Google Chrome" <test suite>
```
An example of a `<test suite>` is: `e2e/playwright/flow-tests.spec.ts`
YOU WILL NEED A PLAYWRIGHT-SECRETS.ENV FILE:
#### Specific example
open a terminal and run:
```bash
# ./e2e/playwright/playwright-secrets.env
token=<your-token>
snapshottoken=<your-snapshot-token>
docker run --network host --rm --init -it playwright/chrome:playwright-1.46.0
```
and in another terminal, run:
```bash
PW_TEST_CONNECT_WS_ENDPOINT=ws://127.0.0.1:4444/ yarn playwright test --project="Google Chrome" e2e/playwright/command-bar-tests.spec.ts
```
then replace "your-token" with a dev token from dev.zoo.dev/account/api-tokens
run a specific test change the test from `test('...` to `test.only('...`
(note if you commit this, the tests will instantly fail without running any of the tests)
**Gotcha**: running the docker container with a mismatched image against your `./node_modules/playwright` will cause a failure. Make sure the versions are matched and up to date.
run headed
```
@ -289,7 +328,7 @@ yarn start
and finally:
```
yarn test:nowatch
yarn test:unit
```
For individual testing:
@ -298,14 +337,103 @@ 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
```bash
cd src/wasm-lib
cargo test
**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
# 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
exportRUST_BRACKTRACE="full"&& cargo nextest run --workspace --test-threads=1
```
Where `XXX` is an API token from the production engine (NOT the dev environment).
We recommend using [nextest](https://nexte.st/) to run the Rust tests (its faster and is used in CI). Once installed, run the tests using
```
cd src/wasm-lib
KITTYCAD_API_TOKEN=XXX cargo run nextest
```
### Mapping CI CD jobs to local commands
When you see the CI CD fail on jobs you may wonder three things
- Do I have a bug in my code?
- Is the test flaky?
- Is there a bug in `main`?
To answer these questions the following commands will give you confidence to locate the issue.
#### Static Analysis
Part of the CI CD pipeline performs static analysis on the code. Use the following commands to mimic the CI CD jobs.
The following set of commands should get us closer to one and done commands to instantly retest issues.
```
yarn test-setup
```
> Gotcha, are packages up to date and is the wasm built?
```
yarn tsc
yarn fmt-check
yarn lint
yarn test:unit:local
```
> Gotcha: Our unit tests have integration tests in them. You need to run a localhost server to run the unit tests.
#### E2E Tests
**Playwright Electron**
These E2E tests run in electron. There are tests that are skipped if they are ran in a windows, linux, or macos environment. We can use playwright tags to implement test skipping.
```
yarn test:playwright:electron:local
yarn test:playwright:electron:windows:local
yarn test:playwright:electron:macos:local
yarn test:playwright:electron:ubuntu:local
```
> Why does it say local? The CI CD commands that run in the pipeline cannot be ran locally. A single command will not properly setup the testing environment locally.
#### Some notes on CI
@ -336,25 +464,12 @@ PS: for the debug panel, the following JSON is useful for snapping the camera
</details>
### Tauri e2e tests
#### Windows (local only until the CI edge version mismatch is fixed)
For how to contribute to KCL, [see our KCL README](https://github.com/KittyCAD/modeling-app/tree/main/src/wasm-lib/kcl).
### Logging
To display logging (to the terminal or console) set `ZOO_LOG=1`. This will log some warnings and simple performance metrics. To view these in test runs, use `-- --nocapture`.
To enable memory metrics, build with `--features dhat-heap`.
File diff suppressed because one or more lines are too long
Some files were not shown because too many files have changed in this diff
Show More
Reference in New Issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.