question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Ability to use debug AVA tests with a launch configuration

See original GitHub issue

What is the Problem Being Solved?

When running tests with a launch configuration (as here) I get this error,

SyntaxError: The requested module '[file:///opt/agoric/agoric-sdk/node_modules/@babel/types/lib/index.js]()' does not provide an export named 'default'

That’s caused by import '@agoric/babel-standalone' in @endo/init/pre-bundle-source.js`. (That particular error goes away when I comment out that line.)

Description of the Design

This might be solved by https://github.com/Agoric/agoric-sdk/pull/4718 . I’ll check after that is merged.

Security Considerations

Test Plan

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9 (9 by maintainers)

github_iconTop GitHub Comments

1reaction
michaelfigcommented, Mar 10, 2022

Per #4758, we no longer depend on […] @babel/types.

We still need @babel/types. Maybe you were thinking ast-types?

1reaction
kriskowalcommented, Mar 9, 2022

Per https://github.com/Agoric/agoric-sdk/pull/4758, we no longer depend on @agoric/babel-standalone or for that matter recast, therefore neither @babel/types. So that just leaves esm in agoric-cli, which is becoming rapidly less necessary as we’ve migrated most if not all dapp deploy scripts to Node.js ESM (NESM).

Read more comments on GitHub >

github_iconTop Results From Across the Web

ava/debugging-with-vscode.md at main · avajs/ava - GitHub
You can debug your tests using Visual Studio Code. ... Now, with a test file open, from the Debug menu run the Debug...
Read more >
Debugging AVA with VS Code is not that simple - Łukasz Nojek
Debugging in VS Code requires creating a Launch Configuration stored in the .vscode/launch.json file. VS Code documentation. A very long manual ...
Read more >
Faster way to run, debug and view results of Ava tests
Use Wallaby to boost your productivity by running and debugging Ava tests in VS Code as you are writing your tests/code. Use Ava...
Read more >
JavaScript: How to use WebStorm debugger with ava
Create run/debug configuration, type Node.js · Select your node interpreter · As node parameter insert your ava bin and parameter --verbose. For ...
Read more >
How you can test your Node.js applications with Ava.js - Medium
The handy thing about Ava is that it allows you to run async tests, via async await ... For the sake of simplicity,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found