Site broken

All suggestions about TPFC should be posted here. Discussions about changes to TPFC will also be carried out here.
Post Reply
Message
Author
User avatar
SYSTEM
Posts: 2041
Joined: Sat Jul 31, 2010 1:19 am
Location: Helsinki, Finland

Site broken

#1 Post by SYSTEM »

See the screenshot below. It's the entire main page. It shows only two programs. Other pages are similarly broken as well - they abruptly end after showing a couple of entries.
2020-02-08 09.39.18 www.portablefreeware.com 0f9f7a3e866d.png
My YouTube channel | Release date of my 13th playlist: August 24, 2020

User avatar
Andrew Lee
Posts: 3048
Joined: Sat Feb 04, 2006 9:19 am
Contact:

Re: Site broken

#2 Post by Andrew Lee »

Working on it..

Update: Fixed.

Wow, I certainly wasn't ready to chase down this rabbit hole..

After putting up cli.portablefreeware.com, I had a little time on my hand. So I decided to work on something I have been putting off for a long time: upgrading PHP to the latest version.

Now since this is a minor version upgrade i.e 7.x to 7.y, I wasn't expecting much of a problem. phpBB worked. A few direct listings worked. I was ready to call it a night when I saw what had happened.

Trouble was, nothing was logged to the error logs! Normally when you have a PHP error, it is plainly visible in the error log and you just have to do a bit of fixing up..

But in this case, there was nothing. So I was going around in circles trying out various things, it was pretty stressful.

To cut a long story short, I finally managed to narrow it down to a third party library that we are using that converts bbcode in the database entries to HTML. Further sleuthing led me to nail down the issue and fixed the one single line that was causing the problem.

There are a few dimensions to this. I think (but have not confirmed) that the new version of PHP imposes stricter rules on a syntactical format that was permitted in the past. So it should have thrown out an error. But the library author for whatever reason used an obscure operator (the '@' symbol, go look it up) that disables error reporting for that particular line! It was as if he foresaw this line would become a problem, so he just turned off error reporting for just that line. So despite me turning on all the error reporting to trace the error, nothing was logged. Like I said, it was a deep deep rabbit hole!

I really need my sleep now after all this. I hope there are no other issues with this upgrade (which we needed to have anyway because the old PHP version is no longer supported). If there are, I will tackle them after a good night's sleep! :D

User avatar
vevy
Posts: 795
Joined: Tue Sep 10, 2019 11:17 am

Re: Site broken

#3 Post by vevy »

Andrew Lee wrote: Sat Feb 08, 2020 3:36 am...But the library author for whatever reason used an obscure operator (the '@' symbol, go look it up) that disables error reporting for that particular line! It was as if he foresaw this line would become a problem, so he just turned off error reporting for just that line.
LOL! Probably just to spite you! I hope you will have an uninterrupted sleep with non-php dreams!

User avatar
SYSTEM
Posts: 2041
Joined: Sat Jul 31, 2010 1:19 am
Location: Helsinki, Finland

Re: Site broken

#4 Post by SYSTEM »

Andrew Lee wrote: Sat Feb 08, 2020 3:36 am So it should have thrown out an error. But the library author for whatever reason used an obscure operator (the '@' symbol, go look it up) that disables error reporting for that particular line!
Ouch. Ability to disable error reporting is dangerous for exactly this reason. :( Thanks for fixing the issue!
My YouTube channel | Release date of my 13th playlist: August 24, 2020

User avatar
__philippe
Posts: 687
Joined: Wed Jun 26, 2013 2:09 am

Re: Site broken

#5 Post by __philippe »

Motion moved before the honourable TPFC's members general assembly :

To put out a contract on those F*** third party library's programmers and teach them about sloppy coding tricks ! :twisted:

(BTW, I had to clear TPFC's browser cookies in order to log in, anyone else ?)

User avatar
dtoxic
Posts: 19
Joined: Thu Aug 25, 2016 5:56 pm

Re: Site broken

#6 Post by dtoxic »

__philippe wrote: Sat Feb 08, 2020 7:44 am (BTW, I had to clear TPFC's browser cookies in order to log in, anyone else ?)
yeap me also

User avatar
vevy
Posts: 795
Joined: Tue Sep 10, 2019 11:17 am

Re: Site broken

#7 Post by vevy »

See here: viewtopic.php?t=24767 by Andrew

User avatar
Midas
Posts: 6705
Joined: Mon Dec 07, 2009 7:09 am
Location: Sol3

Re: Site broken

#8 Post by Midas »

I was unable to login with either Seamonkey Portable v2.49.5 or my installed instance of Firefox v72.0.2.

Then I managed to get in with Firefox -- which hasn't liked the toolbar options of the posting form since before this.

Still out in the cold with Seamonkey, my TPFC browser of choice. Let me see if the cookie cleaning trick works...

EDIT: yep, that did it. Yhew!

Had a really long minute there, wondering if somehow I had got myself banned. :dizzy_face:

bitcoin
Posts: 285
Joined: Sun Dec 31, 2017 6:32 pm

Re: Site broken

#9 Post by bitcoin »

Midas wrote: Sat Feb 08, 2020 2:28 pm I was unable to login with either Seamonkey Portable v2.49.5 or my installed instance of Firefox v72.0.2.

Then I managed to get in with Firefox -- which hasn't liked the toolbar options of the posting form since before this.

Still out in the cold with Seamonkey, my TPFC browser of choice. Let me see if the cookie cleaning trick works...

EDIT: yep, that did it. Yhew!

Had a really long minute there, wondering if somehow I had got myself banned. :dizzy_face:
me too

i thought a hacker had got my username + password and posted something obnoxious and got me banned, lol

User avatar
__philippe
Posts: 687
Joined: Wed Jun 26, 2013 2:09 am

Re: Site broken

#10 Post by __philippe »

This litany of login aggravation is no doubt an unfortunate side-effect of the initial problem Andrew had to fight long and hard needlessly,
because some third party sloppy coding habits suppressed the creation of an error log... :roll:

More reason to ferret out and terminate the bastards with extreme prejudice! :mrgreen:

User avatar
SYSTEM
Posts: 2041
Joined: Sat Jul 31, 2010 1:19 am
Location: Helsinki, Finland

Re: Site broken

#11 Post by SYSTEM »

__philippe wrote: Sun Feb 09, 2020 9:52 am This litany of login aggravation is no doubt an unfortunate side-effect of the initial problem Andrew had to fight long and hard needlessly,
because some third party sloppy coding habits suppressed the creation of an error log... :roll:
Nah, judging from his thread it's far more likely a known side effect caused by creation of the CLI database.
My YouTube channel | Release date of my 13th playlist: August 24, 2020

User avatar
__philippe
Posts: 687
Joined: Wed Jun 26, 2013 2:09 am

Re: Site broken

#12 Post by __philippe »

Could be...yet wondering what's Andrew's take about it ? :?

User avatar
Andrew Lee
Posts: 3048
Joined: Sat Feb 04, 2006 9:19 am
Contact:

Re: Site broken

#13 Post by Andrew Lee »

Nah, judging from his thread it's far more likely a known side effect caused by creation of the CLI database.
Astute observation. I had to integrate the new subdomain with the forum which runs on the main domain, so I had to modify the phpBB cookie domain slightly in order to accommodate for this. Good news is, if we ever need to create another subdomain again, we don't have to change anything.
More reason to ferret out and terminate the bastards with extreme prejudice!
Come, come. Who amongst us who code have not made stupid decisions and came up with embarrassingly bad code? Programmers like to bitch about other programmers, but fact is, we are all bad coders! :D

User avatar
__philippe
Posts: 687
Joined: Wed Jun 26, 2013 2:09 am

Re: Site broken

#14 Post by __philippe »

Thanks for chiming in, Andrew.

One must admire your tolerance towards the rascals who kept you up till the wee hours chasing a white rabbit... :roll:
Too indulgent by half, I'd say... :wink:

Anyway, hats off for your dedication in keeping TPFC running smoothly !

User avatar
Midas
Posts: 6705
Joined: Mon Dec 07, 2009 7:09 am
Location: Sol3

Re: Site broken

#15 Post by Midas »

Andrew Lee wrote: We are all bad coders! :D

I, for one, will raise my glass to chase that piece of the proverbial humble pie... :wine_glass: :man_shrugging:

Post Reply