Mine vscode version is 1.83.1 which runs on Linux and breakpoint of devsense plugin doesn't work as well. But luckily, the xdebug_break() works perfectly fine. Still, I would appreaciate if I could use breakpoint feature from the plugin.

Here is my spec:

# code --version
1.83.1
f1b07bd25dfad64b0167beb15359ae573aecd2cc
x64
# vscode plugin
php  v1.40.14103
# php --version
PHP 8.1.2-1ubuntu2.14 (cli) (built: Aug 18 2023 11:41:11) (NTS)
Copyright (c) The PHP Group
Zend Engine v4.1.2, Copyright (c) Zend Technologies

    ngdangtu-vn Thank you,

    It seems you don't have xdebug extension installed properly. php --version should look like this:

    PHP 8.1.16 (cli) (built: Feb 14 2023 18:15:27) (NTS Visual C++ 2019 x64)
    Copyright (c) The PHP Group
    Zend Engine v4.1.16, Copyright (c) Zend Technologies
        with Xdebug v3.2.0, Copyright (c) 2002-2022, by Derick Rethans

      Thanks for support,

      The reason is because I didn't enable it for CLI profile. Here is the mine after enable it:

      # php --version
      PHP 8.1.2-1ubuntu2.14 (cli) (built: Aug 18 2023 11:41:11) (NTS)
      Copyright (c) The PHP Group
      Zend Engine v4.1.2, Copyright (c) Zend Technologies
          with Xdebug v3.1.2, Copyright (c) 2002-2021, by Derick Rethans

      But even after I enable it for CLI profile, the breakpoint is still not work. Btw, here is the latest 20-xdebug.ini:

      zend_extension=xdebug.so
      xdebug.mode=develop,trace,debug
      xdebug.client_host = 127.0.0.1
      xdebug.client_port = 9003
      xdebug.start_with_request=trigger
      
      xdebug.remote_autostart=1  
      xdebug.remote_enable=1

      I tried with xdebug.start_with_request=yes and it didn't work as well.

      Why did my comments constantly put on hold for approval? I thought this process only happens one or two times.

      ngdangtu-vn Thank you. It seems all correct.

      I'm thinking - maybe the path to your workspace may contain unexpected characters?

        ngdangtu-vn we used to have some issues with spam - so we're rather reviewing posts before publishing them now.

        Hi,

        As Jakub mentioned it appears this might be due to some weird path or maybe path mapping?

        What would help is to configure xdebug log:

        xdebug.log="path_to_log/xdebug.log

        (https://docs.devsense.com/en/vs/debugging/troubleshooting#collecting-xdebug-logs)

          Write a Reply...