Bug of the Year

0 Shares
0
0
0

So I’m coding away, in my local machine, own branch…things were mucky but nothing I can’t handle. Making it work was one thing. Making sure there are no holes after that was another, but I managed that. Good.

The boat has no holes and ready to set sail.

Merging time. I was expecting this to be a 2-second glance-then-it’s-all-good sort of thing. merged….BOOOOOOMM THINGS ARE NOT SHOWING UP DAFUUUUUUUUQQQQQQQQQQQ. No console log errors / var/log errors / network errors / nothing breaking/missing in view source…basically no lead.
Code set in local and remote are completely identical. So what could it be? Debugging a buggy code is easy. Just find the buggy code then trace it from there….but there’s no buggy code here.

So I reverted remote and worked on my local to trace it….well daffuuuuqqqqq, how can I debug this when it’s perfectly fine in local?!

Well, I had to do what I had to do last night and mucked around with remote (don’t do that at home..or remote)

I commented out files…then classes, then functions, then statements, then lines of code…I figured it out.

I had a hunch that it might have been this:
Previously I had a prob with an older and new php versions in dedicated servers.

somefunction( anotherFuncReturningSomething($var) );

In the old php version I had, it cannot parse this properly. In the latest php, it’s totally fine.
For the older, you can still go around with it by doing so:

$r = anotherFuncReturningSomething($var);
somefunction( $r );

Yup, weird right?

Well, going back to my story it wasn’t it.

Fast forward, there was nothing wrong with my code(s). Perfect. Flawless. The problem? mcrypt was not installed in my remote. Well, it was actually. both my local and remote are identical too. for some reason, I had to run some linux commands to “update” it….

0 Shares
Leave a Reply

Your email address will not be published. Required fields are marked *