Skip to content

Conversation

@Vighnesh-V
Copy link
Collaborator

Run all the tests in your project via:

lute test

Run some of the tests in a directory via:

lute test filter/path/directory

@Vighnesh-V Vighnesh-V marked this pull request as ready for review November 11, 2025 03:39
@Vighnesh-V Vighnesh-V force-pushed the lute-test-all branch 2 times, most recently from ef2f7da to a53a809 Compare November 11, 2025 05:09
@Vighnesh-V Vighnesh-V marked this pull request as draft November 11, 2025 05:13
@Vighnesh-V Vighnesh-V force-pushed the lute-test-all branch 2 times, most recently from 9c2d5a3 to cfdac1b Compare November 12, 2025 03:10
vrn-sn pushed a commit that referenced this pull request Nov 12, 2025
This use after free manifested intermittently when running lots and lots
of tests at a time in this PR:
#557.

The cause of this uaf happens because we do not close the `fs_event_t`
handle. When the `WatchHandle` wrapper gets closed, it invoked
`uv_event_stop` but not `uv_close`, so the memory associated with the
handle gets freed, but `libuv` doesn't know that this handle is closed.
This causes uv's internal data structures to get messed up and we may
accidentally touch this freed memory causing the Use-After-Free.

`WatchHandle::close` already invokes `uv_event_stop`, so we can remove
this from the implementation of `closeHandle`.
@Vighnesh-V Vighnesh-V force-pushed the lute-test-all branch 5 times, most recently from 0c42ac0 to 61d24e8 Compare November 12, 2025 20:05
@Vighnesh-V Vighnesh-V marked this pull request as ready for review December 3, 2025 00:53
Comment on lines +47 to +48
suite:case("lute test runs tests in discovery folder", function(assert)
-- Run lute test on tests/cli/discovery folder
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

if we dont do this, lute test calls itself recursively.

Copy link
Contributor

@annieetang annieetang left a comment

Choose a reason for hiding this comment

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

could u make a note about why we aren't using this in CI for now? or a follow up issue for it

@Vighnesh-V Vighnesh-V merged commit 5b0676b into primary Dec 3, 2025
11 checks passed
@Vighnesh-V Vighnesh-V deleted the lute-test-all branch December 3, 2025 02:24
@Vighnesh-V
Copy link
Collaborator Author

Created a follow up issue for running this in CI here: #634. I'm going to spend some time tomorrow digging into this to figure out exactly why the @Batteries require fails with lute test and update the issue, but for now, we just print an error and skip over that test.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants