Skip to content

Commit 951d76a

Browse files
authored
Update debugging.md
Hi, we were trying to debug cloud functions locally, using functions-framework. It seems that the doc is out of date, it doesn't work if you point to .bin folder
1 parent 82e96ab commit 951d76a

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

docs/debugging.md

+1-3
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ npm install @google-cloud/functions-framework
1919
3. Run `node`, enable the inspector and run the Functions Framework:
2020

2121
```sh
22-
node --inspect node_modules/.bin/functions-framework --target=helloWorld
22+
node --inspect node_modules/@google-cloud/functions-framework/build/src/main.js --target=helloWorld
2323
...
2424
Debugger listening on ws://127.0.0.1:9229/5f57f5e9-ea4b-43ce-be1d-6e9b838ade4a
2525
For help see https://nodejs.org/en/docs/inspector
@@ -28,6 +28,4 @@ Function: helloWorld
2828
URL: http://localhost:8080/
2929
```
3030

31-
> Note that the [symlinked executable](https://docs.npmjs.com/cli/v8/configuring-npm/folders#executables) of the function framework in node_modules/**.bin**/functions-framework is used to direct the debugger to the necessary entrypoint.
32-
3331
You can now use an IDE or other tooling to add breakpoints, step through your code and debug your function.

0 commit comments

Comments
 (0)