-
-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] \Phalcon\Debug code output #1329
Comments
Could you please attach a test case? Thanks. BTW, what version of Phalcon do you use? |
And do you have Zend Optimizer and/or ionCube Loader installed? |
Using v1.3.0, I don't have Zend Optimizer or ionCube Loader installed. As far as a test, this simple setup replicates the problem $Debug = new \Phalcon\Debug();
$Debug->listen();
class MyTest{
public static function go(){
throw new Exception('Test');
}
}
MyTest::go(); |
This is what I see: https://www.diigo.com/item/image/3zdqq/m40e Looks good to me. |
Fair enough - obviously this bug doesn't affect everyone or it would have been reported a lot sooner. There's not a lot of room for error in the test code, so I don't know how this could be a user error. |
BTW, what lines endings do you use? \r, \n or \r\n? |
If you run ini_set('auto_detect_line_endings', true);
$Debug = new \Phalcon\Debug();
$Debug->listen();
class MyTest{
public static function go(){
throw new Exception('Test');
}
}
MyTest::go(); does the error go away? |
I'm running Debian, so I believe \n are line endings. Your code snippet doesn't fix the problem. |
OK, I'll try to order a VPS with Debian to see if I can reproduce the issue. Could you please:
Thank you. |
|
Still unable to reproduce :-( If you can give me your SSH public key, I will set up access to the server for you so that you can look if I am missing something. |
I'm afraid I wouldn't know what to look for. Is there a way to put Phalcon into a debug mode? |
I'm a jerk. I thought I had 1.3 running, but I was running 1.2.something. Still a problem in the 1.2 branch, but if I'd answered properly when you first asked it could have saved you a lot of trouble. My sincere apologies for being an idiot. |
Just in case — works for me in 1.2.4/1.2.5, could you please check? |
Yes, 1.2.4 works as expected. FYI - all the CSS & javascript loaded from static.phalconphp.com should be requested not from "http://", but from "//" - viewing an error page like this via https really breaks the page. |
//static.phalconphp.com will not work either — because there is no HTTPS version of static.phalconphp.com. See #987 |
Nice, I will apply the patch to 1.2.5 then |
When using \Phalcon\Debug the code output to show you where in the code the exception was thrown consists of nothing but opening PHP tags, ie:
It looks like the tags are from the correct file, as sometimes they're
<?php
and sometimes<?PHP
.Using v1.3.0.
The line numbers are all there and correct, and the correct number is highlighted, it's just that the code on that line is always an opening PHP tag.
The text was updated successfully, but these errors were encountered: