Join devRant
Do all the things like
++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatar
Sign Up
Pipeless API
From the creators of devRant, Pipeless lets you power real-time personalized recommendations and activity feeds using a simple API
Learn More
Search - "public debug"
-
DO NOT USE JAVASCRIPT FOR PUBLIC WEBSITES IF YOU DON'T KNOW HOW TO USE IT!!!
Almost every fucking day, I click a fucking button and NOTHING HAPPENS. I open the console and find tens of JavaScript errors, that *I* have to debug and fix in order to proceed.
FUR FUCK SAKE, JavaScript is not strictly needed, those fucking React and Vue are also not needed. Just now I wanted to download a form: IT'S A FUCKING PDF FILE, why the fuck are you putting your broken JavaScript function to let me download it!? PUT A FUCKING DOWNLOAD LINK YOU FUCKING MORON!
Nobody is forcing anybody to use JavaScript or those fucking fancy frameworks, SO WHY THE FUCK PEOPLE OVERCOMPLICATE THINGS THAT USED TO WORK SO WELL!14 -
Public service announcement: Do not get married to your language, tools, or way of doing things. If there's an easier solution to something, try it before dismissing it. No language is perfect, and dumping everything on the responsibility of an API or framework can cause more headache then solve it.
Case in point: I love Java for backend programming, but node.js is a better solution to frontend programming then depending on JSP's and HTML within the same Java project. Less things go wrong and it's easier to debug issues.
There is no best programming language. Only best practices and using the right tool for the right job.
#exceptC++fuckthatlanguage
:^)15 -
HO. LY. SHIT.
So this gig I got myself into, they have a whitelist of IP addresses that are allowed to access their web server. It's work-at-home. We just got a new internet provider, and it looks like I get a different public IP address everytime I disconnect and connect to the WIFI. And since it looks like the way they work on their codebase is that you either edit the files right on the server or you download the files that you need to work on, make the changes, and then re-upload the file back to the server and refresh the website to see the changes, now I can't access the server because I get different IP addresses. And it's highly inconvenient to keep emailing them to add IP addresses to the whitelist.
No source control, just straight-up download/upload from/to the server. Like, srsly. So that also means debugging is extremely hard for me because one, they use ColdFusion and I've never used that shit before and two, how the hell do you debug with this style of work?
I just started this last Tuesday, and I already want to call it quits. This is just a pain in the ass and not worth my time. I'll be glad to just go back to driving Lyft/Uber to make money while I look for a full-time, PROPER job.
By the way, can I do that to a contracting job? Just call it quits when you haven't even finished your first task? How does this work?17 -
The website for our biggest client went down and the server went haywire. Though for this client we don’t provide any infrastructure, so we called their it partner to start figuring this out.
They started blaming us, asking is if we had upgraded the website or changed any PHP settings, which all were a firm no from us. So they told us they had competent people working on the matter.
TL;DR their people isn’t competent and I ended up fixing the issue.
Hours go by, nothing happens, client calls us and we call the it partner, nothing, they don’t understand anything. Told us they can’t find any logs etc.
So we setup a conference call with our CXO, me, another dev and a few people from the it partner.
At this point I’m just asking them if they’ve looked at this and this, no good answer, I fetch a long ethernet cable from my desk, pull it to the CXO’s office and hook up my laptop to start looking into things myself.
IT partner still can’t find anything wrong. I tail the httpd error log and see thousands upon thousands of warning messages about mysql being loaded twice, but that’s not the issue here.
Check top and see there’s 257 instances of httpd, whereas 256 is spawned by httpd, mysql is using 600% cpu and whenever I try to connect to mysql through cli it throws me a too many connections error.
I heard the IT partner talking about a ddos attack, so I asked them to pull it off the public network and only give us access through our vpn. They do that, reboot server, same problems.
Finally we get the it partner to rollback the vm to earlier last night. Everything works great, 30 min later, it crashes again. At this point I’m getting tired and frustrated, this isn’t my job, I thought they had competent people working on this.
I noticed that the db had a few corrupted tables, and ask the it partner to get a dba to look at it. No prevail.
5’o’clock is here, we decide to give the vm rollback another try, but first we go home, get some dinner and resume at 6pm. I had told them I wanted to be in on this call, and said let me try this time.
They spend ages doing the rollback, and then for some reason they have to reconfigure the network and shit. Once it booted, I told their tech to stop mysqld and httpd immediately and prevent it from start at boot.
I can now look at the logs that is leading to this issue. I noticed our debug flag was on and had generated a 30gb log file. Tail it and see it’s what I’d expect, warmings and warnings, And all other logs for mysql and apache is huge, so the drive is full. Just gotta delete it.
I quietly start apache and mysql, see the website is working fine, shut it down and just take a copy of the var/lib/mysql directory and etc directory just go have backups.
Starting to connect a few dots, but I wasn’t exactly sure if it was right. Had the full drive caused mysql to corrupt itself? Only one way to find out. Start apache and mysql back up, and just wait and see. Meanwhile I fixed that mysql being loaded twice. Some genius had put load mysql.so at the top and bottom of php ini.
While waiting on the server to crash again, I’m talking to the it support guy, who told me they haven’t updated anything on the server except security patches now and then, and they didn’t have anyone familiar with this setup. No shit, it’s running php 5.3 -.-
Website up and running 1.5 later, mission accomplished.6 -
So… I released v2.0.0 of devRant UWP a few weeks ago.
Then I got a lot of reports of problems on Windows 10 Mobile and older (than 1809) versions of Windows 10 on Desktop.
I decided to resubmit v2.0.0-beta16 to the store, and try to find the issue in the update… I didn't find it.
The code seems the same as the working version (at least the part I try to test is 100% equal).
So it seems I fucked up the vs project.
This means that to find the issue I can spend weeks to search it over and over inside the latest project (using shitty emulators of older Windows 10 builds to debug it), or I could just restore it to the old v2.0.0-beta16 (released in august) and implement again every single new feature and fix (something like 5 new features, dozens of improvements, changes and bug fixes).
In any case, this will require a lot of time (which I don't have at this moment).
I'm really sorry for this inconvenience, I know some of you use my client daily (~3.000 users I guess), I'm really glad someone likes it, and thanks a lot for the awesome reviews and feedback, but stable v2 (v2.1.0 at this point) will be available not earlier than in February.
Probably some of you have already download v2.0.0 while it was available in the store, and maybe it works on your device (please let me know in the comments below if you did, how is it going, and also if you like the new features and improvements).
After this epic fail, and more than 1 year (way too much) of v2 public beta, I want to throw the current project in the trash, and start it from scratch.
Which means I will start to work on v3 as soon as you will see v2.1.0 in the store, making it faster, lighter and with better support for the latest Windows 10 (Fluent Design and not) features, dropping the support for the very old UWP API.
Thanks for your attention.
Have a good day (or night)!5 -
I really can't focus on anything else when there's an unfinished assignment or a deadline approaching.. I debug in my sleep and daydream in public transport thinking about all the things I'll have to code later.
I hate it because I'm ignoring all my loved ones during days like these and it always backfires on me somehow. However, I can't help myself - I am always stressing out..3 -
Hiii devRanters, I have a TypeScript question for you...
How do I dynamically import classes?
I have a class like this:
export default class Foo implements Bar {
...
....public getName(): string {
........return this.name;
....}
}
and then I have another file with this:
import(`./class-cmd/${file}`).then((command) => {
....winston.debug(command);
....winston.debug(command.getName());
});
the first command spits out something like this:
debug: default=class Foo {
....constructor() {
........this.name = "foo";
....}
....getName() {
........return this.name;
....}
}
and I would expect that the second command will work, however it throws this:
UnhandledPromiseRejectionWarning: TypeError: command.getName is not a function
Any idea what I might be doing wrong?18 -
Guys, what the fuck.
Today i was doing some consistancy checks accross the board after update made for one of our core systems that manages money. Yeah, real, live money.
I have hidden from public payment processor with simple API etc. So one of my checks, gate has same balances as gate's internal account on core blinked red. Okay well, fuck, thats really really shitty situation to be in. I guess my gate is fucked up some way.
Okay, debug mode on, maintainence mode on, quick look at DB, oh shit, client payed 4 times 15k eur without any txn on core system... SHIT! postman... Fuck, postman ofc wont start, quick google, fixing postman, tention in me grows, becouse its really rough and tough fuckup on my side, and got call. That moment when you know someone already knows is for me apogeum of stress that just skyrocketed from calm morning to mad morning.. Okay, i pick up phone, and I hear that one client payed (using core system app) and got strange message, YES I KNOW, im working on it.. Wait, you say that core system gave them odd message??? I will check it out. Finally fixed postman, 3 requests and I know its bug on core system.
Why, why in the motherfucking blody world anyone would push critically bugged update to system that just sends api callbacks "yes, he payed" when someone didnt pay...
Fuck im stressed and pissed, but at same time reliefed its not my personal fuckup (yeah, I solo wrote that gate, but externally audited code and all they had to say that some cosmetic linting should be done)3 -
I don't mind helping people when they come across an issue as chances are I already know the answer, but it's got to the point at the company I work for where some devs automatically come to me for help without even trying to debug or find the answer themselves. Even when an error is written out in black and white - "this protected function must be public"... Anyone can code, but what makes programmer good is the ability to debug.1