maziac / DeZog

Visual Studio Code Debugger for Z80/ZX Spectrum.
MIT License
212 stars 35 forks source link

Unverified breakpoints in version 1.5.3. Windows 10 #34

Closed howprice closed 3 years ago

howprice commented 3 years ago

Since upgrading from Version 1.4.8 to 1.5.3 breakpoints no longer work. Repro project attached hello-specnext.zip Using sjasmplus v1.17.0 with CSpect 2.12.36 (binaries in attached repro case)

I have edited launch.json and removed:

        "listFiles": [
            {
                "path": "bin/${workspaceFolderBasename}.lst",
                "useFiles": true,
                "asm": "sjasmplus",
                "mainFile": "src/main.asm"
            }
        ],

and added

        // This is for DeZog 1.5, but I can't set breakpoints using this...
        "sjasmplus": [{
            "path": "bin/${workspaceFolderBasename}.lst" // relative to root folder
        }],

Steps to reproduce the behavior:

  1. Unzip attached file hello-specnext.zip
  2. Open folder hello-specnext/games/invaders in Visual Studio Code
  3. Ctrl+Shift+B to build
  4. Ctrl+P task CSpect
  5. Open src/main.asm and set a breakpoint on line 70
  6. Press F5 to launch
  7. The PC does not stop at the breakpoint and the DEBUG CONSOLE displays: 'DeZogPlugin v1.5.0.23723' initialized. Unverified breakpoint:{"verified":false,"line":70,"column":0,"source":{"name":"main.asm","path":"c:/temp/hello-specnext/hello-specnext/hello-specnext/games/invaders/src/main.asm","sourceReference":0},"message":"00-1h"} Continue

Prior to upgrading to this version and making the change to launch.json breakpoints worked perfectly. I have had to downgrade to 1.4.8 and revert launch.json to work around this issue.

Version etc. (please complete the following information):

Many thanks for any advice.

maziac commented 3 years ago

Sorry that you encounter this problem.

I tried to assemble your project but get an sjasmplus error:

[SAVENEX] non-zero data are in stackAddress area, may get overwritten by NEXLOAD

with sjsamplus 1.17.0.

Could you have a look.

Could you also attach your list file. Will make it easier for me, because I don't have to assemble the sources.

The path in the error looks strange: Unverified breakpoint:{"verified":false,"line":70,"column":0,"source":{"name":"main.asm","path":"c:/temp/hello-specnext/hello-specnext/hello-specnext/games/invaders/src/main.asm","sourceReference":0},"message":"00-1h"}

maziac commented 3 years ago

(Sorry, issue was closed automatically).

I think I found the root cause. There was a comparison of file paths and a mix of upper and lower case drive letters, so the paths were evaluated as different. Please try the release v1.5.4 here: https://github.com/maziac/DeZog/releases/tag/v1.5.4 and let me know if it works for you.

Thanks for reporting this issue.

howprice commented 3 years ago

Hi. Release v1.5.4 fixes the issue. Breakpoints are now working again. Many thanks!

In answer to your previous questions:

Great software thanks!