xdebug

php eclipse debugging

二次信任 提交于 2019-12-06 04:35:29
问题 I am runing a php script using eclipse. when a set breakpoint and run the script it throws me this error. form the error it is apparent that i have change something the php.ini file. but i dont know what i have to change to make either zend or xdebug. even i dont know what the differnce b/w them. following the error The session could not be started. In order to generate debug information, please make sure that the debugger is properly configured as a php.ini directive 回答1: I ran into this

failed to open stream: operation failed

淺唱寂寞╮ 提交于 2019-12-06 04:26:37
# composer require oygza/aliyun-php-sdk-afs You are running composer with xdebug enabled. This has a major impact on runtime performance. See https://getcomposer.org/xdebug The "https://packagist.laravel-china.org/packages.json" file could not be downloaded: SSL operation failed with code 1. OpenSSL Error messages: error:14090086:SSL routines:ssl3_get_server_certificate:certificate verify failed Failed to enable crypto failed to open stream: operation failed https://packagist.laravel-china.org could not be fully loaded, package information was loaded from the local cache and may be out of date

PHP Storm Debugging Creates Empty Server Definitions

跟風遠走 提交于 2019-12-06 04:03:01
问题 Something seems to have broken in my PHP Storm IDE. When I try and debug using the listener, Storm loads the "Incoming connection from Xdebug" dialog but, the server name text field is empty. I can specify the file to debug but, nothing happens in the IDE. I can see that Storm is debugging the file in the stack trace but, it isn't mapping to the file in my IDE. When I check the server configuration in Storm, it has created a nameless server definition. If I complete this definition, select it

Enabling Xdebug on Mac OS X Lion

风格不统一 提交于 2019-12-06 03:17:59
问题 i've been trying to enable Xdebug for Mac OS X Lion, but can't make it work. This should be pretty straight forward but it just isn't working for me. These are the steps i took: 1 - Uncommented this line of the php.ini file: zend_extension="/usr/lib/php/extensions/no-debug-non-zts-20090626/xdebug.so" 2 - Restarted my Apache Server with sudo apachectl restart 3 - Checked that it is enabled via the phpinfo() function. It is in fact enabled both as Zend module and as a separate module. But it

code coverage of xDebug and PHPUnit says 100%, in fact it is not

断了今生、忘了曾经 提交于 2019-12-06 02:35:25
I have the following function: function foo($p) { if ($p == null) throw new Exception('bla'); if ($p == null) { throw new Exception('bla'); } [...] } My Test for this function is not covering the lines throwing the exception. But PHPUnit tells me the first 'throw'-statement is coverd, the second not. Maybe the first is interpreted, but it is not executed. So I don't want to get the message '100%' if I have not reached 100%. Is this a bug in xDebug or do I have the possibility to configure xDebug/PHPUnit? xDebug's code coverage metrics are statement-based rather than line-based. What this means

XDebug not working with xampp

我是研究僧i 提交于 2019-12-06 01:26:43
I'm using (or trying to anyway) use the bundled XDebug with XAMPP 1.7.2. It comes bundled with Apache 2.2.12, PHP 5.3.0, XDebug 2.0.5 and Zend (not sure on version) This is a totally fresh install of XAMPP, the only thing I've added to php.ini (at xampp/php/php.ini) is: zend_extension_ts = "C:\xampp\php\extensions\php_xdebug.dll" [xdebug] xdebug.auto_trace = 1 xdebug.collect_includes = 1 xdebug.collect_params = 1 xdebug.collect_return = 1 xdebug.default_enable = 1 xdebug.extended_info = 1 xdebug.show_local_vars = 0 xdebug.show_mem_delta = 1 xdebug.trace_format = 1 xdebug.trace_options = 0

Xdebug not working with PHPStorm

拈花ヽ惹草 提交于 2019-12-05 23:13:49
I use PHPStorm along with Xdebug to step through my code. PHPStorm is running on a Windows 7 machine, and my local webserver is running on a separate CentOS 6.4 machine. I've done a phpinfo(); to verify that Xdebug is being loaded by PHP, and it is. The following are the settings for my Xdebug in the PHP.ini: [xdebug] zend_extension="/usr/lib/php/modules/xdebug.so" xdebug.remote_enable = 1 xdebug.remote_port = 9000 xdebug.remote_host = "192.168.1.130" xdebug.remote_log = "/var/log/httpd/xdebug_log" I similarly setup PHPStorm to use my CentOS server as the debugging server, and I listen for

Eclipse Xdebug Freezes at 57%

断了今生、忘了曾经 提交于 2019-12-05 21:42:55
My problem: When launching a debug configuration from Eclipse for one of my php pages, the page opens successfully in Chrome but the Eclipse debugger freezes at 57% (in the bottom right hand corner of Eclipse) and never progresses further. The set breakpoints are never reached. My setup: MAMP 2.2 PHP 5.3.3 Eclipse Kepler Eclipse PDT Xdebug 2 virtual hosts with roots at /Applications/MAMP/htdocs Apache Port: 80 MySql Server Port: 3306 My virtual hosts setup within MAMP is working fine. Below are screenshots concerning the Xdebug setup: I suspect the problem is being caused by my virtual hosts.

XDebug with Symfony and PhpStorm doesn't work (Ubuntu installation)

ⅰ亾dé卋堺 提交于 2019-12-05 21:29:27
Facts about my system Ubuntu 15.10 Php 5.6.11 Symfony 2.7 PhpStorm 10 xDebug 2.4 I really struggle getting xdebug to work under my Symfony project in PhpStorm. I installed xdebug configured the php.ini file in my /etc/php5/apache2/php.ini and in the cli folder [xdebug] zend_extension=/usr/lib/php5/20131226/xdebug.so xdebug.remote_enable = 1 xdebug.remote_port = 9000 xdebug.idekey = PHPSTORM xdebug.remote_host=127.0.0.1 But when I "Start listening for PHP Debug Connections" and set breakpoints in my application and run tests with breakpoints in it, Xdebug just doesn't break the programm. php -v

怎样在重构PHP项目时快速梳理代码执行流程

别来无恙 提交于 2019-12-05 20:55:16
最近在用Go重构一个PHP项目,代码写的有点乱,也没文档,没注释,总之就是功能基本靠猜, 然后我找了个小工具快速理清代码执行流程,帮助自己理解代码逻辑。 首先打开xdebug的分析器 xdebug.profiler_enable = 1 xdebug.profiler_output_dir = /tmp 分析器有什么用,有兴趣可以去 xdebug官网 自己去看。 但是xdebug分析器输出的内容对人是不友好的,使用工具才能方便的看到自己想要的,这里我们使用 webgrind 帮助我们查看这个内容。 webgrind依赖python和graphviz,安装完成之后修改webgrind的config.php文件 /** * Path to python executable */ static $pythonExecutable = '/usr/bin/python'; /** * Path to graphviz dot executable */ static $dotExecutable = '/usr/local/bin/dot'; 然后在webgrind目录下执行 php -S 127.0.0.1:19000 //使用php内置http服务器,php version >= 5.4 webgrind可以生成流程图和分析每个方法函数的执行时间