How to debug Serverless from within VS Code
HTML-код
- Опубликовано: 28 ноя 2020
- If you want to use the in-built debugging within VS Code with your Serverless Projects then this is the video for you.
Link to the launch.json gist.github.com/SamWSoftware/... - Наука
it worked to me, thanks!
You're welcome!
What changes would you make in the python fire if you are debugging a python file? Great vid btw!
Great Video!
Glad you enjoyed it
This still doesn't work for me. I always end up with unbounded breakpoints. Copied the launch.json config word for word, except I change the outfiles to point to the typescript output folder. The server starts, but I get unbounded breakpoints every time. Very frustrating
Me too. I have unbounded breakpoints.
Sam, great video! Were you able to get the webpack issue figured out?
Not yet but I've not had the time to really look into it.
I wonder what theme are you using, it looks fantastic
Monokai Pro. Its $10 for a full license but it's so clear and I've used it for years so well worth the investment
Sir thanks for your Serverless content really learned lot from this channel. I have one doubts how to remove Serverless deployment profile (default, custom).
Do you mean how to set up a specific profile?
serverless config credentials --provider aws --key YOUR_AWS_KEY --secret YOUR_AWS_SECRET --profile YOUR_PROFILE_NAME
If you add webpack and typescript then vscode debugger doesn't work. Can you add how to use debugging in serverless when webpack is used.
Can you upload a video about using webrtc with serverless?
I can have a look into it. It's not something I've done before
This is great...if you're working with Vanilla JS. I've been trying for hours, and hours, to get a Lambda written in TypeScript to debug the same way. Any advice there? I thought Serverless Framework would save me, when it came to Typescript, after also spending many frustrating hours there with zero results. I just want to debug a TS Lambda locally, with local API Gateway, so I can actually start building something. Serverless is generally a *miserable* developer experience for me, thus far.
I got it working through a little trickery. Full end -to-end with Nextjs inside VSC. I’ll post an article about it this week.
@@VincentJenks where is it?
@@VincentJenks do you still remember how to debug tyscript locally?
do you have the github url link please ?
Would this approach will work with typescript template?
Yes, there are some things that you need to do around the tsconfig and webpack (if you're using it) but it can work
Great, in python is also de same? which is the config for that?
I've never tried running serverless offline with python lambdas but if that works then the rest should be the same.
@@CompleteCoding Please test a simple severless project with python with this approach, I tried your config for python, it is not working.
Gret video how to set it up, with nvm or node version manager linux or mac?
Mac - tecadmin.net/install-nvm-macos-with-homebrew/
not sure on Linux but sure there're good tutorials out there
@@CompleteCoding thanks a lot, I have had installed nvm on mac, but my question was related to set it up, on visual vode to debugging, because following the your video the degugger is taking the global nodejs installation at /user/local/ but nvm is installed at home directory, which is causing no taking the nvm path
@@andresm9051 Ah that's somethign I'd not considered. I haven't tested this but maybe adding an .nvmrc file to the repo would enforce that version of node
@@CompleteCoding still not working adding the file .nvmrc and the nodejs version in it, the serverless offline start and the VS code debugger appears at the top of the windows, however when making a request the breakpoints are passed by, without stooping, the breakpoints says unbound breakpoints, maybe can be the webpack.config setup?
starts at
ruclips.net/video/xaBAZm2jfXQ/видео.html