Lars Fosdal 1791 Posted December 15, 2022 I have the weirdest issue. I just installed a fresh Delphi 11.1 + patches on a new, fully patched Windows 10 Enterprise laptop. For some weird reason - I can't debug. Breakpoints don't break. Exceptions break shows assembly code, says it is mixed mode, but no source lines show, and I can't trace to next sourceline. Yes, I am in 32-bit debug mode. Yes, the project has the debug settings and debug info included. Yes, the output folders have full access for the current user. Yes, there is only one set of DCUs in the path. Yes, there is only one .EXE file. Edit: Yes, they are debug DCUs Yes, line endings are CRLF Yes, current user has local admin rights As soon as my app starts, the breakpoints are grayed out. Edit 2: It does not happen to all apps. The problem app is about 600k lines. Tiny apps and a larger 1100k line app - no problems. What am I missing? Update - Possible causes? A developer on a non-corporate laptop does not have this problem. Another developer on corporate laptops have the same problem as me on both new and old laptops. That seems to indicate a Windows policy may be a factor here. Anyways - workaround: Project | Options | Linking | Include remote debug symbols: A tick here gave working breakpoints for us. Share this post Link to post
Attila Kovacs 629 Posted December 15, 2022 (edited) 4 minutes ago, Lars Fosdal said: Yes, there is only one set of DCUs in the path. and they are debug dcu's? (Use debug .dcus) Edited December 15, 2022 by Attila Kovacs Share this post Link to post
Lajos Juhász 293 Posted December 15, 2022 I don't know please tell us. I have had a situation when I was unable to debug a package with one exe. Changed the application that is used for debugging (host application) then the break point worked every time. Next week I was able to debug with both applications. Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 1 minute ago, Attila Kovacs said: and they are debug dcu's? (Use debug dcu) Share this post Link to post
Attila Kovacs 629 Posted December 15, 2022 ok, well, I'd try clean/build or remove the .dproj and reconfigure the project.. is this the only one IDE installed on that machine? Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 Yes - clean machine - clean install - no previous Delphis - and the .dproj files came from a repository also maintained with Delphi 11.1. Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 3 minutes ago, Fr0sT.Brutal said: Test project - the same? Yes - started a new project. Same problem. No! I closed all projects, then tried again with a brand new project. That worked. 1 Share this post Link to post
Attila Kovacs 629 Posted December 15, 2022 (edited) Edited December 15, 2022 by Attila Kovacs 4 Share this post Link to post
Attila Kovacs 629 Posted December 15, 2022 Last one, did you restart your PC after installing the IDE? 🙂 1 Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 Deleting the .dproj did solve the problem. I compared the newly created to the old one, and there was a huge amount of crap in the old one. But, why does it work on the old installation? 1 Share this post Link to post
PeaShooter_OMO 11 Posted December 15, 2022 The old one had the Crap-O-Reader installed Sorry, I could not help myself 1 Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 The plot thickens: I deleted the .dproj for a specific app. Debugging worked. I opened a project group- containing the same app. Debugging stopped working. Guess I need to rebuild that too. Strike that. I ran the wrong project >< Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 The downside of deleting the .dproj file. Output path, search path, dcu output path, and EurekaLog needs to be reconfigured. Oh, such joy. 1 Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 Another app, same problem - except this time, deleting the .dproj did not solve the problem. WTF is going on? Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 2 hours ago, Lars Fosdal said: and there was a huge amount of crap in the old one. Any changes to validate file contents? If you found garbage in the ".DPROJ", then other files could be contaminated as well.... Was there any strange situation when copying the files? Just lingering on about possible issues with the source files... Remembering the old D.O.S./Windows 3.1, don't laugh, it was very easy to get a corrupt disk block and have our files buggy, and sometimes unreadable forever... Share this post Link to post
PeaShooter_OMO 11 Posted December 15, 2022 2 minutes ago, programmerdelphi2k said: it was very easy to get a corrupt disk block and have our files buggy, and sometimes unreadable forever... I would definitely start to look at the hardware Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 Fresh checkout from Git. Compiler does not complain. Program executes fine. It just that it doesn't appear to be in debug mode. Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 I once had a problem with a ".pas" not compiling, and, after much thought, the problem was that the file had been changed, for some reason, to a "UNICODE" where control characters (ghosts) had been found (however, they were not visible to the human eye, naturally)... Solution: I had to redo the file, because even copying it to a non-unicode editor didn't work at all! Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 ok, then it's just DEBUG ... search PATH to (LIBRARY = dcus / BROWSER =pas / DEBUG = dcu) it's ok on project? Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 See previous posts. Files are in UTF-8 format with BOM. Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 ok! try "check" RELEASE to DEBUG and else and re-save projects... sometimes IDE can be confused! Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 try show all "hide chars" on editor: Tools-User Interface-Editor-Language... options "show" Share this post Link to post
Lars Fosdal 1791 Posted December 15, 2022 Switched to Release, builded, exited Delphi. Restarted Delphi, switched to Debug, builded, ran - no change. No weird characters. Opens fine in TextPad, Notepad, VS Code and IDE. Share this post Link to post
programmerdelphi2k 237 Posted December 15, 2022 sometimes the Breakpoint dont works if "final-line char" it's not those expected! Share this post Link to post