-
Notifications
You must be signed in to change notification settings - Fork 121
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
Oups... phpDox encountered a problem and has terminated! #103
Comments
This is not a bug or issue with phpDox but with your general PHP installation, as the error message shows:
Simply adjust the php.ini to contain a valid timezone setting. |
While I agree this can be resolved by setting It's a problem, because there is no default value set for I know you closed this, but I believe it's a bug, as this result is avoidable by the phpdox. |
Thank you for your thoughts. phpDox is not a library but a tool that requires a sane configuration of its environment to be successful in its work. While I do understand that not having a default setting in php.ini might pose a problem phpDox is far from being the only application or case affected. Every request to any PHP script is likely to trigger this. I do agree though that phpDox could handle this - as well as some other errors - more nicely. Read: Exit with a more descriptive error message rather than "crash" The situation itself cannot really be avoided as there is no reliable way of getting the current timezone: I could, as many frameworks do, simply add a |
I may have some time in December to work on a patch, if there is a particular approach you'd like me to follow, whether it be noting the necessary configuration in the documentation, implementing a default time zone (which you seem to not want to do), or something a bit more complex. Let me know how you'd like me to proceed, if at all. |
It's not so much about the work as technically it comes down to simply not using the @ on the get and catching the ErrorException. That's not a big deal and I might actually implement it - or you can submit a PR for that. What bothers me is that this approach would merely cover up the real problem and will most certainly cause new bug reports about phpDox being off by whatever hours in its log output. |
Btw: PHP by default, if all other methods fail, will use UTC as the timezone. Which is about the least likely to be correct for anybody ;p |
Okay, implemented a check into the preBootstrap code with commit d21603e to handle this issue explicitly. |
For the record: The behavior changed for 0.8.0+ to explicitly use PHP's fallback to UTC when the configuration is missing. I'm still not happy with that but it's at least consistent with PHPs behavior. |
Hello,
I'm having an issue setting up my Jenkins installation where phpdox keeps failing. Has anyone experienced this issue before?
The text was updated successfully, but these errors were encountered: