我安装了PHPUnit和xdebug,在CLI的php.ini文件中我得到了:
display_errors = On
xdebug.default_enable = 1
Run Code Online (Sandbox Code Playgroud)
我已经验证了当我使用交互式控制台创建错误时会打印xdebug回溯,但是当运行phpunit时发生错误时,没有回溯?
回溯发生了什么?phpunit是否将它隐藏起来?有什么设置我不见了?
谢谢!
每当我打开调试器下的断点列时,它都会给出错误
Model proxy installed notification job
Child Count Update
Run Code Online (Sandbox Code Playgroud)
细节给出
An internal error occurred during: "Model Proxy installed notification job".
java.lang.NullPointerException
An internal error occurred during: "child count update".
java.lang.NullPointerException
Run Code Online (Sandbox Code Playgroud)
我在Mac OSX 10.8.2上使用Eclipse Juno上的Xdebug.
我尝试用phpstorm远程调试php应用程序.我在vmware虚拟机上使用centos 6.4,php5.3和apache 2.2,在真正的ubuntu上使用firefox的phpstorm.xdebug真正安装:
Installed Packages
Name : php-pecl-xdebug
Arch : i686
Version : 2.1.4
Release : 1.el6
Size : 580 k
Repo : installed
From repo : epel
Summary : PECL package for debugging PHP scripts
URL : http://pecl.php.net/package/xdebug
License : PHP
Run Code Online (Sandbox Code Playgroud)
phpinfo也证实了这一点:
This program makes use of the Zend Scripting Language Engine:
Zend Engine v2.3.0, Copyright (c) 1998-2010 Zend Technologies
with Xdebug v2.1.4, Copyright (c) 2002-2012, by Derick Rethans
Run Code Online (Sandbox Code Playgroud)
当我通过ssh从控制台运行脚本(简单的hello world)时,我的脚本停止了,我从xdebug和xdebug连接到mu ide并在自己的日志中写入信息.但是当我从browsen运行脚本时 - 即使在xdebug日志中也没有效果.我尝试使用firefox扩展来启动调试会话,我尝试使用xdebug.remote_autostart = 1选项,tru关闭了centos中的iptables,但也没有效果.我做错了什么?xdebug配置:
; Enable xdebug …Run Code Online (Sandbox Code Playgroud) 我搜索了很多关于IntelliJ IDEA 12和xdebug.file_link_format配置值的时间.
我找不到任何有效的东西......
是否可以使用与IntelliJ IDEA或PhpStorm的xdebug文件链接?
我正在使用PHPstorm作为我的主要PHP开发环境和XDebug来调试我的应用程序.
我唯一的问题是消息"无法接受外部Xdebug连接:无法计算表达式'isset($ _ SERVER ['PHP_IDE_CONFIG'])'"不时出现.
我已经在这里和JetBrains支持(这里和这里)看到了一些问题的解决方案,但我的问题有点不同,因为我可以正常调试,但消息继续出现.
请参阅下面的事件日志的打印.显然,该消息每30分钟出现一次.
仅供参考,我正在对一个web服务进行调试,因此,我将Xdebug配置为侦听所有HTTP请求,单击"开始侦听PHP调试连接按钮"(图中的绿色),然后通过Advannced Rest Client(Chrome)启动请求.
正如我所说,我可以毫无问题地进行调试,所以我只想了解这条消息.它会引起任何问题吗?难道我做错了什么?我可以禁用此消息吗?怎么样?
我在链接的问题中尝试了解决方案,但消息仍然存在.
这是我的Xdebug配置:
[Zend]
zend_extension="/usr/lib/php5/20131226/xdebug.so"
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_mode=req
xdebug.remote_host=127.0.0.1
xdebug.remote_port=9000
xdebug.remote_autostart=1
xdebug.remote_connect_back=0
Run Code Online (Sandbox Code Playgroud) 我创建了一个Elastic Beanstalk环境
ID_LIKE="rhel fedora"
VERSION_ID="2016.03"
PRETTY_NAME="Amazon Linux AMI 2016.03"
ANSI_COLOR="0;33"
CPE_NAME="cpe:/o:amazon:linux:2016.03:ga"
HOME_URL="http://aws.amazon.com/amazon-linux-ami/"
Run Code Online (Sandbox Code Playgroud)
我正在尝试使用安装xdebug
sudo yum install php-pecl-xdebug
Run Code Online (Sandbox Code Playgroud)
但我一直得到以下错误
Loaded plugins: priorities, update-motd, upgrade-helper
Resolving Dependencies
--> Running transaction check
---> Package php-pecl-xdebug.x86_64 0:2.2.3-1.5.amzn1 will be installed
--> Processing Dependency: php(api) = 20090626-x86-64 for package: php-pecl-xdebug-2.2.3-1.5.amzn1.x86_64
--> Processing Dependency: php(zend-abi) = 20090626-x86-64 for package: php-pecl-xdebug-2.2.3-1.5.amzn1.x86_64
--> Running transaction check
---> Package php-common.x86_64 0:5.3.29-1.8.amzn1 will be installed
--> Processing Conflict: php56-common-5.6.21-1.124.amzn1.x86_64 conflicts php-common < 5.5.22-1.98
--> Finished Dependency Resolution
Error: php56-common conflicts …Run Code Online (Sandbox Code Playgroud) 在PHP中进行调试并使用左侧的变量窗格时,在悬停时可以看到该变量/对象的字符数量有限制.
反正有没有看到该变量的完整有效负载或除了file_put_contents每次我想看到一个大的变量值时必须使用的任何工作?将变量打印到调试控制台也有相同的限制,但添加了一个额外的字符(幸运的是).
I ran this command:
"C:\xampp\php\.\php.exe" "C:\xampp\php\phpunit" -d xdebug.profiler_enable=on -d xdebug.idekey=VSCODE
C:\xampp\php\php.ini has the following:
[XDebug]
zend_extension = "C:\xampp\php\ext\php_xdebug-2.5.0-7.1-vc14.dll"
xdebug.idekey=VSCODE
xdebug.profiler_enable=1
xdebug.default_enable=1
xdebug.remote_enable=1
xdebug.remote_handler=dbgp
xdebug.remote_host=localhost
xdebug.remote_port=9000
xdebug.remote_autostart=1
Run Code Online (Sandbox Code Playgroud)
If I run the command without Listen for XDebug, I will see the following in the command line window:
Installing...
Running as single site... To run multisite, use -c tests/phpunit/multisite.xml
Not running ajax tests. To execute these, use --group ajax.
Not running ms-files tests. To execute these, use --group ms-files.
Not running external-http tests. …Run Code Online (Sandbox Code Playgroud) 我正在尝试调试CLI脚本,而Xdebug无法连接到PhpStorm。
我Operation now in progress (29).在Xdebug远程日志中看到错误。
我确定Xdebug配置正确,但是我不知道如何调试PhpStorm。
由https://xdebug.org/wizard.php生成的phpinfo()的摘要
Tailored Installation Instructions
Summary
Xdebug installed: 2.6.1
Server API: Command Line Interface
Windows: no
Zend Server: no
PHP Version: 7.1.24
Zend API nr: 320160303
PHP API nr: 20160303
Debug Build: no
Thread Safe Build: no
OPcache Loaded: no
Configuration File Path: /usr/local/etc/php
Configuration File: /usr/local/etc/php/php.ini
Extensions directory: /usr/local/lib/php/extensions/no-debug-non-zts-20160303
You're already running the latest Xdebug version
Run Code Online (Sandbox Code Playgroud)
Xdebug日志
Log opened at 2019-02-19 11:59:37
I: Connecting to configured address/port: 46.201.50.194:9000.
W: …Run Code Online (Sandbox Code Playgroud)