5 ms·
I've had the exact opposite experience. It's unusual for an upgrade to not break something. There are dozens of breaking changes in this release alone: https:/
by john-shaffer 6y ago
I've had the exact opposite experience. It's unusual for an upgrade to not break something.
There are dozens of breaking changes in this release alone: https://github.com/php/php-src/blob/96c7d42a3ca9d822a08b3dd48060abca8240413a/UPGRADING#L20 https://github.com/php/php-src/blob/96c7d42a3ca9d822a08b3dd4...
Some of the changes are sadistic. "The precedence of the concatenation operator has changed relative to bitshifts and addition as well as subtraction." Have fun debugging code that worked perfectly well for years and now produces unpredictable results.
- alganet 6y agoPHP7 will still be supported for a while. Debian will probably support it even further. You'll have a long ass time to fix these. Even if you wanted to push the 8.0.0 to production as soon as it came out, you'd still have until November to run your tests on the RC branch and report any mishaps to the development team. The backwards compatibility is mostly targeted to major platforms (Wordpress, Drupal, Magento, Symfony, etc). > Have fun debugging code that worked perfectly well for years and now produces unpredictable results. This describes my everyday experience with any language or codebase. The cause for the unpredictable results are often human-related though, not version-related. > Some of the changes are sadistic. "The precedence of the concatenation operator has changed relative to bitshifts and addition as well as subtraction." I would gladly remove any code that does concatenation and math/bitwise on the same expression relying on the operator precedence. Sadistic is the person who writes these. More than 2000 packages were analyzed and only 5 instances of that particular use were found[1], all bugs. This is a good change. [1]: https://news-web.php.net/php.internals/105442 https://news-web.php.net/php.internals/105442
- john-shaffer 6y ago> > Have fun debugging code that worked perfectly well for years and now produces unpredictable results. > This describes my everyday experience with any language or codebase. That is horrifying. That should absolutely not be normal. I don't know what you work with normally, but it's clear that we are working in completely different worlds.
- alganet 6y agoI don't know any programming context immune to human errors. Stuff just breaks. Sometimes I get lucky and the guy before me wrote a cool test that prevents me from having to start a debugger, but the contrary is often the reality. OSS stuff is usually better, but not much better (OS upgrades always break, for example).
- wvenable 6y agoYou're not likely to have something like the concatenation operator mixed with bitshifts. Most of the changes are more likely to be bugs in your code that remain undiscovered rather than things that worked perfectly fine before but are now broken. These changes reflect how people use the language or what they already believe it to do.
- john-shaffer 6y agoYou're talking about hypothetical code, but I am talking about actual code that worked fine but no longer works after an upgrade. Perhaps it was poorly written, but it was not buggy. I can't think of a single time that I've seen a bug exposed by language changes. I have seen dozens of bugs created by language changes, however. (Mostly crashes).
- wvenable 6y agoIf you're depending on very weird edge cases in PHP I'd consider that buggy even if it works.
- john-shaffer 6y agoThis is a completely useless discussion if you're going to assume that code depends on "very weird edge cases" with no idea of what the code actually does.
- wvenable 6y agoYou're welcome to post an example.