A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/swoole/yasd below:

swoole/yasd: Yet Another Swoole Debugger

English | 中文

Swoole 5.0.1 + PHP 8.1 already support xdebug, so there is no need to use the yasd debugger!

Yet Another Swoole Debugger. document

Notice: if you use Swoole\Server, set the worker_num to 1, otherwise the breakpoint may fail.

You'll need to install the Boost library first.

macOS:

Ubuntu:

apt-get install libboost-all-dev

CentOS:

yum install boost boost-devel
phpize --clean && \
phpize && \
./configure && \
make clean && \
make && \
make install

set the ini file:

see the extension info:

zend_extension=yasd
yasd.debug_mode=remote
yasd.remote_host=127.0.0.1
yasd.remote_port=9000

All command supports fuzzy matching of priorities.

set the ini file:

zend_extension=yasd
yasd.debug_mode=cmd

list source code

b absolute-file-path lineno

This will also save the breakpoint information in the cache file -- .breakpoints_file.log

You can change this file name by the ini file, e.g.

yasd.breakpoints_file="yasd.log"

If the cache file exists, the breakpoints in the file are automatically loaded when debug is started.

If a breakpoint is set or deleted without specifying absolute-file-path, It will set breakpoint in the current file.

We can monitor the variable changes or expression, for example:

show all breakpoints:

show all watchpoints:

p $a
p $this
p $this->prop
Debugging with phpstorm (remote mode)

When using yasd, if the framework starts slowly (most of the time it's because the framework is scanning a lot of files), you can execute the following command.

composer dump-autoload -o

Then modify the following configuration config/config.php:

'scan_cacheable' => env('SCAN_CACHEABLE', true)

We did not find a slow start problem.

We did not find a slow start problem.

We did not find a slow start problem.

We did not find a slow start problem.

We did not find a slow start problem.

The breakpoint is not triggered
  1. No absolute path to the file is used
  2. The breakpoint is not a valid line, such as a function declaration, blank line, etc
  3. The code is generated with proxy classes, such as Hyperf. So you need to set breakpoints in the proxy class.

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4