10 ms·
assert() is still broken if it's disabled in php.ini.
by lazka 4y ago
assert() is still broken if it's disabled in php.ini.
- nolok 4y agoI mean yes php.ini allows you to disable any function you want, and if you do that then this function doesn't work like expected, I can hardly blame php for that.
- hakre 4y agoYes, that's fully true, but does specifically assert() falls into that category?
- hakre 4y ago> assert() is still broken if it's disabled in php.ini. Care to explain what you mean it's broken if disabled? That it is disabled (noop in runtime) so you're missing it? AFAIK that's the production setting. You should be able to enable it in build/test/ci/development, just how you want it.
- lazka 4y agoSure. (1) it is a global setting so I can't decide if I want it on a per application basis, with Docker that is less of an issue though (2) it is disabled by default, so hardly anyone uses it from what I see (3) I'd like to have it always enabled, also in production, so my code doesn't end up in states that I didn't expect and I get notified. But that might just be me and/or my particular use case.