Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

after starting debugger, breakpoint is set in the build directory rather than the cartridge #373

Open
balikian opened this issue Nov 9, 2023 · 2 comments

Comments

@balikian
Copy link

balikian commented Nov 9, 2023

Describe the bug
Very sorry if this might be a configuration thing with my setup, but this has been happening to me for ages. When I start debugger, sometimes, many times, the break changes to my build directory rather than my cartridge.

To Reproduce
Steps to reproduce the behavior:

  1. in a cartridgle, set a breakpoint
  2. start the debugger
  3. under breakpoints, the path has changed to the build directory rather than the cartridge the break point was originally set in.

Expected behavior
Breakpoint remains set on the line and file you set it at.

Screenshots
originally set breakpoint:
Screenshot 2023-11-09 143051_cdi

changed breakpoint after starting debugger:
Screenshot 2023-11-09 143414_build

Desktop (please complete the following information):
Version: 1.84.0 (user setup)
Commit: d037ac076cee195194f93ce6fe2bdfe2969cc82d
Date: 2023-11-01T11:29:04.398Z
Electron: 25.9.2
ElectronBuildId: 24603566
Chromium: 114.0.5735.289
Node.js: 18.15.0
V8: 11.4.183.29-electron.0
OS: Windows_NT x64 10.0.19045

Additional context
To remedy, I stop the debugger and start it again. Normally, I would hit restart, but I've been having problems with that where it doesn't fully stop the instance. So now I stop it. wait a few seconds, start it again and if it happens again which it usually will, repeat until it stops happening.

@SqrTT
Copy link
Owner

SqrTT commented Dec 21, 2023

Hi @balikian
Is there chance that your build directory contains file .project and it's considered by extension as original cartridge?

Also having two files original file and compiled file (in build directory). Is expected that original file should be opened (having in mind that Prophet doesn't support source maps)?

As workaround you may try to use option files.exclude of VS Code

@balikian
Copy link
Author

I do not have a .project file in my build directory. I also do not have anything in the output directory within build. Not sure where the debugger gets these build files then. Here's a screenshot of the issue:

These breakpoints are set on Home.js in a cartridge called SFCC/cdi/cartridges/app_storefront_cdi

Now I do have another folder at the same level as SFCC called "stage" that we use to deploy to stage and it has stage/SFCC/build/output/cascade/code/app_storefront_cdi/ and that has a .project file in it, but that path doesn't look like the same one in my screenshot.
HnxJshA802B4Sgvn

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

No branches or pull requests

2 participants