Skip to content

Conversation

@mikavilpas
Copy link
Collaborator

This PR demonstrates that #127 can indeed be solved by changing the name of the then combinator to something else. Here I purposefully chose the horrible name thenceforth (wiktionary 🙂) to indicate that a better name should be come up with.

It's a bit difficult to demonstrate the fix because of the setup. Let me describe how I verified that it works:

  1. clone the issue reproduction repo https://github.com/katangafor/parjs-vitest-error
  2. I used use nodejs 20.9.0 (others might work too, haven't tried)
  3. setup a local link to the parjs monorepo using this diff (might need to vary the path):
Details

diff --git a/package.json b/package.json
index 4686781..4a9ef19 100644
--- a/package.json
+++ b/package.json
@@ -15,6 +15,6 @@
     "vitest": "^0.34.6"
   },
   "dependencies": {
-    "parjs": "^0.16.1"
+    "parjs": "file:../parjs/packages/parjs/"
   }
 }

  1. Check out this PR's branch in the parjs monorepo and issue yarn && yarn build (might need to do it twice, but it will work)
  2. in the issue reproduction repo, issue yarn && yarn vitest to see that the test passes and does not hang vitest indefinitely

To reproduce the issue and see that the test hangs without the fix, do these steps:

  1. in the parjs monorepo
    • revert the fix using git revert
    • run yarn build (maybe twice)
  2. in the issue reproduction repo
    • run yarn for good luck I guess (might not be needed, haven't tried)
    • run the test again with the command above. It should now hang forever because the fix in parjs has been reverted.

@mikavilpas mikavilpas requested a review from GregRos January 18, 2025 19:55
@mikavilpas mikavilpas marked this pull request as draft January 18, 2025 19:55
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.

2 participants