getting hard to debug error in socksjs code while running cypress test
tnrich opened this issue ยท 4 comments
tnrich commented
Hello there,
I'm hitting the following error while trying to run a cypress test.
I don't really understand why this error is being hit or why it has no real stack trace. Any insight you might have would be quite helpful. Here's the linked issue in the cypress repo: cypress-io/cypress#2823
Thanks!
tnrich commented
brycekahle commented
This is the JSONP transport being used. For some reason, the function it is trying to use, does not exist. I would suggest checking your SockJS versions for both client and server.
tnrich commented
Here is what I could find about sockjs in my project:
Thomass-MacBook-Pro:openVectorEditorTgen tnrich$ yarn why sockjs
yarn why v1.10.1
[1/4] ๐ค Why do we have the module "sockjs"...?
[2/4] ๐ Initialising dependency graph...
[3/4] ๐ Finding dependency...
[4/4] ๐ก Calculating file sizes...
=> Found "sockjs@0.3.19"
info Reasons this module exists
- "nwb#webpack-dev-server" depends on it
- Hoisted from "nwb#webpack-dev-server#sockjs"
info Disk size without dependencies: "248KB"
info Disk size with unique dependencies: "456KB"
info Disk size with transitive dependencies: "708KB"
info Number of shared dependencies: 3
โจ Done in 1.34s.
Thomass-MacBook-Pro:openVectorEditorTgen tnrich$ yarn why sockjs-client
yarn why v1.10.1
[1/4] ๐ค Why do we have the module "sockjs-client"...?
[2/4] ๐ Initialising dependency graph...
[3/4] ๐ Finding dependency...
[4/4] ๐ก Calculating file sizes...
=> Found "sockjs-client@1.1.5"
info Reasons this module exists
- "nwb#webpack-dev-server" depends on it
- Hoisted from "nwb#webpack-dev-server#sockjs-client"
info Disk size without dependencies: "1.11MB"
info Disk size with unique dependencies: "1.56MB"
info Disk size with transitive dependencies: "1.88MB"
info Number of shared dependencies: 9
โจ Done in 0.84s.
Thomass-MacBook-Pro:openVectorEditorTgen tnrich$ yarn why sockjs-node
yarn why v1.10.1
[1/4] ๐ค Why do we have the module "sockjs-node"...?
[2/4] ๐ Initialising dependency graph...
[3/4] ๐ Finding dependency...
error We couldn't find a match!
โจ Done in 1.04s.
brycekahle commented
@tnrich Is it possible your test runner is isolating sockjs somehow, such that it can't see those functions? I'm not familiar with Cypress.