I've been reading posts on here and trying various things on my set up all day and drawing a blank. I have a MacBook Pro, running Monterey 12.5.1 with NetBeans 14, MAMP PRO 6 and Xdebug 3 all installed.
When I try to debug my code I just get a message saying 'waiting for connection to netbeans-x-debug' and then after a while I stop it manually and I get a message saying no connection to Xdebug was detected.
In phpinfo() I can see that Xdebug extension is loaded, so I know it's there, NetBeans and Xdebug just don't appear to be talking to each other.
The native Mac OS firewall is off, and I've set my project port to 9000, NetBeans to 9000 and php.ini to 9000.
php.ini for Xdebug is as follows:
[xdebug]
MAMP_Xdebug_MAMPzend_extension="/Applications/MAMP/bin/php/php8.0.0/lib/php/extensions/no-debug-non-zts-20200930/xdebug.so"
xdebug.mode=debug
xdebug.start_with_request=yes
xdebug.idekey="netbeans-xdebug"
xdebug.remote_enable=On
; Unlike Xdebug 2, where there was an enabling setting for each feature, with
; Xdebug 3 you put Xdebug into a specific mode, which can be configured with the
; xdebug.mode setting.
;
; This setting, in combination with xdebug.start_with_request is the new way to
; enable functionality, and to configure when Xdebug's feature activates.
; Please also note: Xdebug's default debugging port has changed from 9000 to 9003.
; For compatability reason within the MAMP environment the port is still set to 9000.
xdebug.client_port=9000
; Use a Unix domain socket (only a select few debugging clients) instead of
; hostname or IP address of IDE or debugging client is listening for incoming
; debugging connections.
;xdebug.client_host=unix:///path/to/sock
;xdebug.client_host=127.0.0.1
xdebug.client_host=localhost
; Enable Profiling, with which you can analyse performance bottlenecks.
; Replaces xdebug.profiler_enable
xdebug.mode=profile
; The directory where Xdebug will write tracing, profiling, and garbage collection
; statistics to. This directory needs to be writable for the system user with which
; PHP is running. Replaces xdebug.profiler_output_dir
xdebug.output_dir="/Applications/MAMP/tmp"
In the NetBeans project run configuration, in "Advanced" I have left debugger proxy as localhost and the port is 9000.
And in NetBeans prefs, under "PHP > Debugging", the port is set to 9000.
My project runs perfectly on the Mac at https://wip.rich.local:8890
Perhaps I am not passing the right client_host address but I have tried wip.rich.local and still the same problem.
There are a lot of posts on StackOverflow about this but they are all quite old, and the fixes suggested have not helped... Does anyone have an up to date install running?