Tuesday, 12 August 2014

Why is it every new WordPress update causes me nightmares!

Why is it every new WordPress update causes me nightmares!

By Strictly-Software

Why is every time I upgrade to the latest version of either WordPress or Jetpack (a tool built by WP) I end up with a big bag of shit lumped all over me?

I never upgrade on the first new main version but when it's 3.9.2 you would think it would be safe to upgrade however the problem is that even though WordPress may have updated a load of their code plugin authors would have no idea of the changes until too late to make the changes.

Unless they have the urge to run round like headless chickens re-writing code and trying to work out what has gone on they might be left with their own plugins not working or causing issues.

The number of times I have updated WordPress or Jetpack to find
-Statistics not showing - another plugins dashboard shows instead
-Omnisearch breaking the site.
-Share buttons causing JS errors due to cross protocol scripting and other issues.
-Cloudlflares "SmartErrors" interfering with the automatic plugin update functions and causing /404 urls instead of nice "update plugin" options.

I could go on.

This weekend was one of those weekends as I stupidly decidided to upgrade on Saturday morning. Ever since I have had:
-Emails not being sent out and posted on the site through the Postie plugin.
-My own tagging plugin not tagging for some unknown reason, I think it is a memory issue where if you have over 5,000 tags the number of regular expressions done could be a problem. I always now keep the number of tags under that limit with a clean out now and then.
-Incorrectly formatted content in posts.

It has been a nightmare and in future I am thinking of just keeping to the versions of the plugins and WordPress codebase that I know works instead of constantly upgrading - unless due to security issues which should be easily sorted with some decent .htaccess rules, firewall, CloudFlare and some tools on your server like DenyHosts and Fail2Ban etc.

Plus the odd plugin like Limit Login Attempts helps prevents those bad boys knocking on your admin door all the time!

As a WordPress developer actually said to me once whilst chatting over a discussion on the WP forums - "they are not going to re-write the code from the ground up as there are not enough developers to do it" Instead they spend their time making funky widgets and little wizbang "ooh look at that" type of tools.

Even though a big team like Automatic with such a widely used program, yet full of crap code, and if you have looked at the WordPress codebase you will know how crap it is. And this comes from the mouth of a WordPress developer as well as myself after a long discussion on the forums.

Apparently they won't create a new version to the side of the old one whilst carrying on with the current one due to not having enough developers who know the code well enough to build it from scratch.

It seems to have started off as a small CMS project like a lot of systems then grew like a monster out of all control and now it is uncontrollable so to speak.

So I am fed up with debugging other peoples plugins, hacking WordPress and trying to work out what is going on with serious analysis of mail / error / access logs. So I might just stick to what is working and safe - plus keeps me sane!

It seems WordPress themselves have been hacked recently with a mobile porn vector recently: BaDoink Website RedirectMalicious Redirections to Porn Websites on Mobile Devices and I cannot even get to the plugin site at the moment to complain about the 4 things I have on my current list so maybe their site is down as well.

Who knows. If it wasn't free and such a commonly used tool people wouldn't use it if they knew what code lay beneath the surface!

4 comments:

John Spekle said...

I agree Wordpress is a big bag of badly written code. Some of their function calls that just call other functions and then other functions to just add an "/" on the end of a string or remove one whilst being self contained cause a lot of overhead when used out of context and a lot of plugin authors do just that. I think 90% of WP sites that run slowly are due to the amount of plugins being run on them. Plugins that use too much memory and are badly (very badly) written. Code that could be done with one simple SQL statement with a join or two is instead done inside multiple loops calling the same WP function every time when instead it could have been called once outside the loop and the value used again and again.
Plus they still use globals to get their main objects such as wp-db it really isn't well thought out code and I don't understand with the number of developers and money Automatic must now have why they don't write a proper version for the new ages.
Your right, the code under the hat sucks - sucks big time!

Byenia said...

Word. Since this latest upgrade my jetpack stats no longer show on my dashboard and I've been tinkering around all afternoon trying to get my background image to work again (no success thus far).

As someone who doesn't have a mind for comprehending code and a lot of the back-end stuff related to site/blog design, this is very frustrating to be put through nearly every damn upgrade. And this is a site I pay for, so it was really uncool that Wordpress kept bugging me incessantly to upgrade to their latest version, especially if there's this many kinks in it.

Grrr....

Dave Beard said...

Yes I wouldn't be upgrading to WP 4.0 right now despite their constant hassle of plugin authors and users to do so. I think no-one should upgrade their main site if it runs on WP to a beta version and should wait until at least 4.1 or even 4.2 before making the move. Even then I would be cautious. Just because you have upgraded WP it doesn't mean every plugin author has the time OR wish to spend their free time ensuring WP haven't done something stupid to their codebase that will effect the plugins workings. So just because WP is up to date unless every plugin is 100% sound as well who knows what will happen

Rob Reid said...

No I haven't upgraded either any of my sites to WP 4.0 or wasted any time to check if my plugins work on it either.

Every-time I upgrade WP I have issues. I am not going to spent a weekend trying to sort out all my plugins just because I have upgraded WP.

Once they move to WP 4.1 I might think about upgrading but even then I am unsure as it seems all they have done is cosmetic changes. Nothing to do with security holes, cleaning their crap code base up or making it more memory efficient etc.

Personally I think a total rewrite is needed. I already have plugin users on my case about WP 4 upgrades. I told them - don't upgrade to WP 4!

I cannot test my plugins out until I am on WP 4.1 so the plugins either work or don't and if they don't then it's something WP have changed AND if that is the case you would have thought they would have contacted every plugin author to tell them what they needed to do to sort their plugins out and make them compatible wouldn't you? Nope!

My advice never move until you see a .2 after the main version number and don't risk some obscure bit of code in WP or another plugin break your site.