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 - "value add"
-
Yesterday, in a meeting with project stakeholders and a dev was demoing his software when an un-handled exception occurred, causing the app to crash.
Dev: “Oh..that’s weird. Doesn’t do that on my machine. Better look at the log”
- Dev looks at the log and sees the exception was a divide by zero error.
Dev: “Ohhh…yea…the average price calculation, it’s a bug in the database.”
<I burst out laughing>
Me: “That’s funny.”
<Dev manager was not laughing>
DevMgr: “What’s funny about bugs in the database?”
Me: “Divide by zero exceptions are not an indication of a data error, it’s a bug in the code.”
Dev: “Uhh…how so? The price factor is zero, which comes from a table, so that’s a bug in the database”
Me: “Jim, will you have sales with a price factor of zero?”
StakeholderJim: “Yea, for add-on items that we’re not putting on sale. Hats, gloves, things like that.”
Dev: “Steve, did anyone tell you the factor could be zero?”
DBA-Steve: “Uh...no…just that the value couldn’t be null. You guys can put whatever you want.”
DevMgr: “So, how will you fix this bug?”
DBA-Steve: “Bug? …oh…um…I guess I could default the value to 1.”
Dev: “What if the user types in a zero? Can you switch it to a 1?”
Me: “Or you check the factor value before you try to divide. That will fix the exception and Steve won’t have to do anything.”
<awkward couple of seconds of silence>
DevMgr: “Lets wrap this up. Steve, go ahead and make the necessary database changes to make sure the factor is never zero.”
StakeholderJim: “That doesn’t sound right. Add-on items should never have a factor. A value of 1 could screw up the average.”
Dev: “Don’t worry, we’ll know the difference.”
<everyone seems happy and leaves the meeting>
I completely lost any sort of brain power to say anything after Dev said that. All the little voices kept saying were ‘WTF? WTF just happened? No really…W T F just happened!?’ over and over. I still have no idea on how to articulate to anyone with any sort of sense about what happened. Thanks DevRant for letting me rant.15 -
Introducing avatar pets & a new way to unlock avatar items! Pets include cats, dogs, birds and tigers. We know getting all those ++'s can take some time, so while all avatar items are just as reachable for free by earning ++'s from rants and comments, we now allow items to be purchased in-app based on the difference in ++'s you have to the ++ unlock value of the item. (To purchase, you'll need the latest app version)
Paying for avatar items helps us keep the devRant servers up and running and also is extra motivation to add more fun avatar items. If you have any questions or find a bug, please let me or @dfox know. Happy ranting!38 -
Holy crap, just consulted with a company who wanted to fire the entire 6 person backend team because:
"They don't produce any tangible work or add value to the company."
Initially I didn't catch on, went to chat with the devs and realised the dilemma. Took 3 hours of (almost heated) debate before the higher ups understood the the value and purpose of backend devs.
This is a kitchen appliance company who recently moved into IoT 🙃12 -
Meeting with smooth suit guy:
"So, our company has pivoted"
I hate everything about this guy, not having slept well at all, I fucking snapped:
"Pivoted? Oh wow, what a wonderfully refined word to describe that your asinine business model smacked flat into the mud, that your obtuse bubble of vague ideas popped and your childish dreams of piles of undeserved gold got caught up by the hard reality that your product does not add any tangible value -- yet you tricked your sheepish retarded investors once again to fall for a new hype-filled pitch deck? Congratulations. At least you probably snort enough coke to keep believing in yourself..."
The guy nervously wiped his nose, stuttered, and walked off looking angry and a little confused.
So it turns out, my boss is apparently the major "sheepish retarded investor" in this company.
Today I got a mail from him. I expected fire and fury, nuclear ICBMs crashing into my desk.
"Thanks for your feedback, this is why I invite you to meetings. Could you take a look at their new pitch slides and preliminary API docs for me?"15 -
Wan't your own personal devBanner?
Now you can have one!
We're building a powerful banner generator over here: https://devrant.com/collabs/...
The first version is up and running, still basic tho.
You can generate your own by calling this URL:
https://devrant.nuernberger.kim/api...
You'll have to replace "Kimmax" with your devrant name and the value after subtext with the extra text.
A cool domain is already on it's way!
We'll be working on a frontend and a ton of extra features to make this banner even more awesome.
If you got any nice ideas add them to the issue tracker here: https://github.com/cozyplanes/...
Have fun!95 -
Did this on my first programming exam.
int index = 0
int value = 0
try {
while true {
value += array[index]
index++
}
} catch NullPointerException {
System.out.print("Sum: " + value)
}
The task was to add together all numbers in an array.
I somehow aced the exam, but got called in to teachers office this is not the way to use exceptions.7 -
The GET /users endpoint will return a page of the first 13 users by default.
To request other pages, add |-separated querystring with the limit and offset, as roman numerals enclosed in double quotation marks. Response status is always equal to 200, plus the total count of the resource, or zero when there's an error.
You can include an array of friends of the user in the result by setting the request header "friends" to the base64-encoded value of the single white pixel png.
Other metadata is not included by default in responses, but can be requested by appending ?meta.json to any endpoint, which will return an xml response.
If you want to update the user's profile picture, you can request an OAuth token per fax machine, followed by a pigeon POST capsule containing a filename and a rolled up Polaroid picture. The status code attached to the return postal dove will be the decimal ASCII code for a happy smiley on success, and a sad smiley if any field fails form validation.
-- Every single external REST API I've ever worked with.7 -
You know who sucks at developing APIs?
Facebook.
I mean, how are so high paid guys with so great ideas manage to come up with apis THAT shitty?
Let's have a look. They took MVC and invented flux. It was so complicated that there were so many overhyped articles that stated "Flux is just X", "Flux is just Y", and exactly when Redux comes to the stage, flux is forgotten. Nobody uses it anymore.
They took declarative cursors and created Relay, but again, Apollo GraphQL comes and relay just goes away. When i tried just to get started with relay, it seemed so complicated that i just closed the tab. I mean, i get the idea, it's simple yet brilliant, but the api...
Immutable.js. Shitload of fuck. Explain WHY should i mess with shit like getIn(path: Iterable<string | number>): any and class List<T> { push(value: T): this }? Clojurescript offers Om, the React wrapper that works about three times faster! How is it even possible? Clojure's immutable data structures! They're even opensourced as standalone library, Mori js, and api is great! Just use it! Why reinvent the wheel?
It seems like when i just need to develop a simple react app, i should configure webpack (huge fuckload of work by itself) to get hot reload, modern es and jsx to work, then add redux, redux-saga, redux-thunk, react-redux and immutable.js, and if i just want my simple component to communicate with state, i need to define a component, a container, fucking mapStateToProps and mapDispatchToProps, and that's all just for "hello world" to pop out. And make sure you didn't forget to type that this.handler = this.handler.bind(this) for every handler function. Or use ev closure fucked up hack that requires just a bit more webpack tweaks. We haven't even started to communicate to the server! Fuck!
I bet there is savage ass overengineer sitting there at facebook, and he of course knows everything about how good api should look, and he also has huge ass ego and he just allowed to ban everything that he doesn't like. And he just bans everything with good simple api because it "isn't flexible enough".
"React is heavier than preact because we offer isomorphic multiple rendering targets", oh, how hard want i to slap your face, you fuckface. You know what i offered your mom and she agreed?
They even created create-react-app, but state management is still up to you. And react-boierplate is just too complicated.
When i need web app, i type "lein new re-frame", then "lein dev", and boom, live reload server started. No config. Every action is just (dispatch) away, works from any component. State subscription? (subscribe). Isolated side-effects? (reg-fx). Organize files as you want. File size? Around 30k, maybe 60 if you use some clojure libs.
If you don't care about massive market support, just use hyperapp. It's way simpler.
Dear developers, PLEASE, don't forget about api. Take it serious, it's very important. You may even design api first, and only then implement the actual logic. That's even better.
And facebook, sincerelly,
Fuck you.17 -
"Why did you bring Wagyu beef to the meeting?"
"Because the calendar description said: Engineers should proactively add value for our steak holders"
(True story -- They told me to do what management instructs, without correcting anyone and without asking questions. And I love playing that game!)6 -
I have to let it out. It's been brewing for years now.
Why does MySQL still exist?
Really, WHY?!
It was lousy as hell 8 years ago, and since then it hasn't changed one bit. Why do people use it?
First off, it doesn't conform to standards, allowing you to aggregate without explicitly grouping, in which case you get god knows what type of shit in there, and then everybody asks why the numbers are so weird.
Second... it's $(CURRENT_YEAR) for fucks sake! This is the time of large data sets and complex requirements from those data sets. Just an hour through SO will show you dozens of poor people trying to do with MySQL what MySQL just can't do because it's stupid.
Recursion? 4 lines in any other large RDBMS, and tough luck in MySQL. So what next? Are you supposed to use Lemograph alongside MySQL just because you don't know that PostgreSQL is free and super fast?
Window functions to mix rows and do neat stuff? Naaah, who the hell needs that, right? Who needs to find the products ordered by the customer with the biggest order anyway? Oh you need that actually? Well you should write 3-4 queries, nest them in an incredibly fucked up way, summon a demon and feed it the first menstrual blood of your virgin daughter.
There used to be some excuses in the past "but but but, shared hosting only has MySQL". Which was wrong by the way. This was true only for big hosting names, and for people who didn't bother searching for alternatives. And now it's even better, since VPS and PaaS solutions are now available at prices lower than shared hosting, which give you better speed, performance and stability than shared hosting ever did.
"But but but Wordpress uses MySQL" - well then kill it! There are other platforms out there, that aren't just outrageously horrible on the inside and outside. Wordpress is crap, and work on it pays crap. Learn Laravel, Symfony, Zend, or even Drupal. You'll be able to create much more value than those shitty Wordpress sites that nobody ever visits or pay money on.
"But but but my client wants some static pages presented beside their online shop" - so why use Wordpress then? Static pages are static pages. Whip up a basic MVC set-up in literally any framework out there, avoid MySQL, include a basic ACL package for that framework, create a controller where you add a CKEditor to edit page content, and stick a nice template from themeforest for that page and be done with that shit! Save the mock-up for later use if you do that stuff often. Or if you're lazy to even do that, then take up Drupal.
But sure, this is going a bit over the scope. I actually don't care where you insert content for your few pages. It can be a JSON file for all I care. But if I catch you doing an e-commerce solution, or anything else than just text storage, on MySQL, I'll literally start re-assessing your ability to think rationally.11 -
Job Ad: You will report to leadership stakeholders on key progress initiatives and collaborate on business value add action objectives.
Translation: Have boss. Do task.3 -
Me: Hi Guys, theres no docs on our custom push notification / deeplinking implementation. I've tried to work backwards from a QA testing doc to add new links. Can someone tell me if this is all ok? It seems to behave a little weird.
Dev: Looks ok, but we've moved to the braze platform for sending notifications. You'll need to trigger braze notifications now. Test that it works ok with that <confluence-link>
*hour later*
Me: I've tried the debugging tool, both with my payload and one of the samples from the link. It displays on the phone, but tapping it doesn't trigger the deeplinking.
Dev: No it works, try one of these <screenshot of samples I used>
*hour later*
Me: Tried it again on the real device to make sure, as well as on develop and master. Not working with those samples or mine.
Dev: No it does. It comes in here in this library <github link to line of code>
Me: ... Nope, debugged it, it doesn't get passed the next 'if' check on the next line as its missing a key/value. The whole function does nothing.
Dev: Oh do you want to send a braze notification?
Me: ..... you told me I had too .... yes I guess.
Dev: ok for a braze notification it works different, send this <entirely different sample no where on the link>
Me: ...... but ..... this is only for braze notifications ..... why .... all the samples have deeplink url's .... but they don't ....... are you ..... FFS!!!!! !@#?!
(╯°□°)╯︵ ┻━┻
┻━┻ ︵ヽ(`Д´)ノ︵ ┻━┻
(ノಠ益ಠ)ノ彡┻━┻
┌П┐(ಠ_ಠ)1 -
Google sucks!
No, not as e-mail or for privacy reasons. Sure, that too, but it comes with "free" stuff.
It sucks because it's breaking every possible record in the worst, shittiest, most insanely stupid APIs and integrations out there on the entire fucking planet!
It is comically stupid!
Aside from their LOVE of hard-deprecating APIs every few months, requiring constant, time consuming maintenance of every tool that integrates deeply with Google services, some of their APIs, for expensive stuff, look like they've been written by Bobby McFartface from 7th grade.
Take a look at DoubleClick Search (their ad performance reporting tool, that sure does sound like one). To upload custom, additional data, you must pass in a ton of parameter, and they REQUIRE some of them to have a specific, hardcoded value. What's the point in passing that parameter then you dickheads?!
But fine, so you uploaded some stuff using the API. Now you want to delete everything and try again after you fixed a bug - well you fucking CAN'T! You can't delete stuff, you can only mark them as "deleted" using an update call.
Bulk operations? Fuck no!
Can I just add on top? Well of course not! That will raise a ton of exceptions. Same message should be transmitted using the PUT, not POST request, in order to edit.
Can I send everything to PUT? Of course not! You can't edit something that's not there, dummy!
Can I see what's there so that I can update it, and add what's missing?
Well of course not! Why on Earth would you need to see what information is in there after you uploaded it? Who needs that anyway?
Simply send, pray, and hope that everything will be fine (it will not).
Like holy fucking crap, it can't get any more stupid!
Google is a huge pile of idiots who feed on only a single cow - the search engine.
It's times like these when I think that Google right now is the worst thing that exists for everyone in tech. It's dragging everyone down with their monopolies everywhere and complete idiocy in managing them.5 -
I wrote a database migration to add a column to a table and populated that column upon record creation.
But the code is so freaking convoluted that it took me four days of clawing my eyes out to manage this.
BUT IT'S FINALLY DONE.
FREAKING YAY.
Why so long, you ask? Just how convoluted could this possibly be? Follow my lead ~
There's an API to create a gift. (Possibly more; I have no bloody clue.)
I needed the mobile dev contractor to tell me which APIs he uses because there are lots of unused ones, and no reasoning to their naming, nor comments telling me what they do.
This API takes the supplied gift params, cherry-picks a few bits of useful data out (by passing both hashes by reference to several methods), replaces a couple of them with lookups / class instances (more pass-by-reference nonsense). After all of this, it logs the resulting (and very different) mess, and happily declares it the original supplied params. Utterly useless for basically everything, and so very wrong.
It then uses this data to call GiftSale#create, which returns an instance of GiftSale (that's actually a Gift; more on that soon).
GiftSale inherits from Gift, and redefines three of its methods.
GiftSale#create performs a lot of validations / data massaging, some by reference, some not. It uses `super` to call Gift#create which actually maps to the constructor Gift#initialize.
Gift#initialize calls Gift#pre_init (passing the data by reference again), which does nothing and returns null. But remember: GiftSale inherits from Gift, meaning GiftSale#pre_init supersedes Gift#pre_init, so that one is called instead. GiftSale#pre_init returns a Stripe charge object upon success, or a Gift (and a log entry containing '500 Internal') upon failure. But this is irrelevant because the return value is never actually used. Pass by reference, remember? I didn't.
We're now back at Gift#initialize, Rails finally creates a Gift object using the args modified [mostly] in-place by all of the above.
Another step back and we're at GiftSale#create again. This method returns either the shiny new Gift object or an error string (???), and the API logic branches on its type. For further confusion: not all of the method's returns are explicit, and those implicit return values are nested three levels deep. (In Ruby, a method will return the last executed line's return value automatically, allowing e.g. `def add(a,b); a+b; end`)
So, to summarize: GiftSale#create jumps back and forth between Gift five times before finally creating a Gift instance, and each jump further modifies the supplied params in-place.
Also. There are no rescue/catch blocks, meaning any issue with any of the above results in a 500. (A real 500, not a fake 500 like last time. A real 500, with tragic consequences.)
If you're having trouble following the above... yep! That's why it took FOUR FREAKING DAYS! I had no tests, no documentation, no already-built way of testing the API, and no idea what data to send it. especially considering it requires data from Stripe. It also requires an active session token + user data, and I likewise had no login API tests, documentation, logging, no idea how to create a user ... fucking hell, it's a mess.)
Also, and quite confusingly:
There's a class for GiftSale, but there's no table for it.
Gift and GiftSale are completely interchangeable except for their #create methods.
So, why does GiftSale exist?
I have no bloody idea.
All it seems to do is make everything far more complicated than it needs to be.
Anyway. My total commit?
Six lines.
IN FOUR FUCKING DAYS!
AHSKJGHALSKHGLKAHDSGJKASGH.7 -
Trust me, I've been doing this for years.
Best way to deal with numbers in JavaScript:
let x = "1"
x += "1" // add one
x.length // get value of number, 24 -
I would kill all these +1 guys, srsly. I subscribe these threads to know if it will be implemented.
You do not add any value to issue:
* devs are pissed off as this does not help solving problem
* others are pissed off
No one really cares about your likes, really.28 -
Going through Master Card API docs to see how to integrate it, saw that they have sample code, checked Java sample code and found this:
String data = MessageFormat.format(
"'{'\"apiOperation\":{0},"
+ "\"sourceOfFunds\":'{'\"type\":{1},\"provided\":'{'\"card\":'{'\"numbe\":{2},"
+ "\"expiry\":'{'\"month\":{3}, \"year\":{4}'}',\"securityCode\":{5}'}}}',"
+ "\"order\":'{'\"reference\":{6}'}',"
+ "\"transaction\":'{'\"amount\":{7},\"currency\":{8},\"reference\":{9},\"targetTransactionId\":{10}'}'," + "\"customer\":'{'\"ipAddress\":{11}'}}'",
apiOperation,
sourceOfFundsType,
cardNumber,
cardExpiryMonth,
cardExpiryYear,
cardSecurityCode,
orderReference,
transactionAmount,
transactionCurrency,
transactionReference,
targetTransactionId,
customerIpAddress );
FOR FUCK SAKE what happened to JSONObject (for Android) class, I'm sure it is a waaaay better solution than that mess ...
And from Oracle:
JsonObject value = Json.createObjectBuilder()
.add("firstName", "John")
.add("lastName", "Smith")
.add("age", 25)
.build();
I guess that is a cleaner understandable solution than what master card has.8 -
"Hey mate, how are you doing?"
*deep sigh* "It's tough, but I'm managing"
I don't think it's a coincidence that the word managing is often used as a synonym for "Technically alive, but not in a state where I can progress personally, or add any value to my environment".
Now imagine packaging that desolate self-perpetuating feeling of apathy into a farce, propped up with practiced smiles and meet-speak, and calling that daily routine a "career".11 -
!Rant But after seeing this I laughed like hell I need to share this to all my dev folks.
Client: “Our next requirement, we need an elephant”
IT Team: But why don’t you adjust with a buffalo, even it is big…. and black?”
Client: No, we need an elephant only.
IT Team: Fine, I understand your requirement. But our system supports only a buffalo…
Client:We need only an elephant!
IT Team: Ok, let me see if I can customize it for you”
At the Offshore Development Centre :
BA – Client wants a big black four legged animal, long tail, less hair. Having trunk is mandatory. The same was documented, signed off and sent to offshore for development! Based on requirement all features are supported in base product (as buffalo), for trunk alone a separate customization is done.
Finally the customization is shown to client, and the client faints
Addon to this, testers completed their test case as above1 -
Best part about the covid19 manufactured crisis?
Liquor stores deliver. Worst part about liquor stores delivering? Needing to use their shoddy websites.
I've been using a particular store (Total Wines) since they're cheaper than the rest and have better selection; it's quite literally a large warehouse made to look like a store.
Their website tries really hard to look professional, too, but it's just not. It took me two days to order, and not just from lack of time -- though from working 14 hour days, that's a factor.
Signing up was difficult. Your username is an email address, but you can't use comments because the server 500s, making the ajax call produce a wonderfully ambiguous error message. It also fades the page out like it's waiting on something, but that fade is on top of the error modal too. Similar error with the password field, though I don't remember how I triggered it.
Signing up also requires agreeing to subscribe to their newsletter. it's technically an opt-in, but not opting-in doesn't allow you to proceed. Same with opting-in to receiving a text notification when your order is ready for pickup -- you also opt-in to reciving SMS spam.
Another issue: After signing up, you start to navigate through the paginated product list. Every page change scrolls you to the exact middle of the next page. Not deliberatly; the UI loads first, and the browser gets as close as it can to your previous position -- which was below that as the pagination is at the bottom -- and then the products populate after. But regardless of why, there is no worse place to start because now you must scroll in both directions to view the products. If it stayed at the very bottom, it would at least mean you only need to scroll upwards to look at everything on the page. Minor, but increasingly irritating.
Also, they have like 198 pages of spirits alone because each size is unique entry. A 50ml, 350ml, 500ml, 750ml, 1000ml, and 1750ml bottle of e.g. Tito's vodka isn't one product, it's six. and they're sorted seemingly randomly. I think it's by available stock, looking back.
If you fancy a product, you can click on it for a detail page. Said detail page lists the various sizes in a dropdown, but they're not sorted correctly either, and changing sizes triggers a page reload, which leads to another problem:
if you navigate to more than a few pages within a 10 or so second window, the site accuses you of using browser automation. No captcha here, just a "click me for five seconds" button. However, it (usually) also triggers the check on every other tab you have open after its next nagivation.
That product page also randomly doesn't work. I haven't narrowed it down, but it will randomly decide to start failing, and won't stop failing for hours. It renders the page just fine, then immediately replaces it with a blank page. When it's failing, the only way to interact with the page is a perfectly-timed [esc], which can (and usually does) break all other page functionality, too. Absolutely great when you need to re-add everything from a stale copy of your signed-out cart living in another tab. More on that later. And don't forget to slow down to bypass the "browser automation" check, too!
Oh, and if you're using container tabs, make sure to open new tabs in the SAME container, as any request from the same IP without the login cookie will usually trigger that "browser automation" response, too.
The site also randomly signs you out, but allows you to continue amassing your cart. You'd think this is a good thing until you choose to sign in again... which empties your cart. It's like they don't want to make a sale at all.
The site also randomly forgets your name, replacing it with "null." My screen currently says "Hello, null". Hello, cruft!
It took me two days to order.
Mostly from lack of time, as i've been pulling 14 hour shifts lately trying to get everything done. but the sheer number of bugs certainly wasted most of what little time i had left. Now I definitely need a drink.
But maybe putting up with all of this is worthwhile because of their loyalty program? Apparently if you spend $500, you can take $5 off your next purchase! Yay! 1%! And your points expire! There are three levels; maybe it gets better. Level zero is for everyone; $0 requirement. There are also levels at $500 and $2500. That last one is seriously 5x more than the first paid level. and what does it earn you? A 'free' magazine subscription, 'free' classes (they're usually like $20-$50 iirc), and a 'free' grab bag (a $2.99 value!) twice per month. All for spending $2500. What a steal. It reminds me of Candy Crush's 3-star system where the first two stars are trivial, and the third is usually a difficult stretch goal. But here it's just thinly-veiled manipulation with no benefit.
I can tell they're employing some "smarketing" people with big ideas (read: stolen mistakes), but it's just such a fail.
The whole thing is a fail.8 -
They've literally left me with nothing to do. I'm doing nothing. I can't be happy doing nothing.
To illustrate the chaos: Everyone on the team was trying to figure out some defect. No one knows what is going on in the code. It's unlike anything I've ever seen.
I found an API call with a misspelled endpoint. It was wrong since the code was written two months before. There's no way it ever worked. Obviously no one tested the code because they would have immediately seen that the call returned a 404 every time.
I fixed it. That was my only PR in about a month. It was literally one character.
The next week that PR got reverted. Apparently the app works better if the API call fails. No one said what goes wrong if the request is made, just that it "causes problems."
That's how bad it is. No one knows why anything does or doesn't work. People write code that doesn't work, never test it, and the application works better in some unspecified way if that code never gets executed.
The last straw for me was when an architect told us that if we want to improve our skills we need to learn how to read and debug stuff like this.
1) Not to be immodest, but I'm good at figuring out bad code.
2) Just because I can doesn't mean I want to do it all day instead of actually developing software
3) He trivialized the really important skill, not making a mess like this in the first place. If his idea of skill is to sling crap without tests at the wall and then debug it, how is he an architect?
I tried really hard but I can't keep a good attitude. I don't want to become toxic, but why would I consider working that way? I try my best to be good at this. Writing decent code means a lot to me. It should mean a lot to them. Their code is costing them hundreds of thousands of dollars. Maybe millions.
I can't write good code and add value if all I do is debug bad code.
So I'm out. I'm going to another project. Have a nice life.4 -
I think I want to quit my first applicantion developer job 6 months in because of just how bad the code and deployment and.. Just everything, is.
I'm a C#/.net developer. Currently I'm working on some asp.net and sql stuff for this company.
We have no code standards. Our project manager is somewhere between useless and determinental. Our clients are unreasonable (its the government, so im a bit stifled on what I can say.) and expect absurd things from us. We have 0 automated tests and before I arrived all our infrastructure wasn't correct to our documentation... And we barely had any documentation to begin with.
The code is another horror story. It's out sourced C# asp.net, js and SQL code.. And to very bad programmers in India, no offense to the good ones, I know you exist. Its all spagheti. And half of it isn't spelled correctly.
We have a single, massive constant class that probably has over 2000 constants, I don't care to count. Our SQL projects are a mess with tons of quick fix scripts to run pre and post publishing. Our folder structure makes no sense (We have root/js and root/js1 to make you cringe.) our javascript is majoritly on the asp.net pages themselves inline, so we don't even have minification most of the time.
It's... God awful. The result of a billion and one quick fixes that nobody documented. The configuration alone has to have the same value put multiple times. And now our senior developer is getting the outsourced department to work on moving every SINGLE NORMAL STRING INTO THE DATABASE. That's right. Rather then putting them into some local resource file or anything sane, our website will now be drawing every single standard string from the database. Our SENIOR DEVELOPER thinks this is a good idea. I don't need to go into detail about how slow this is. Want to do it on boot? Fine. But they do it every time the page loads. It's absurd.
Our sql database design is an absolute atrocity. You have to join several tables together just to get anything done. Half of our SP's are failing all the time because nobody really understands the design. Its gloriously awful its like.. The epitome of failed database designs.
But rather then taking a step back and dealing with all the issues, we keep adding new features and other ones get left in the dust. Hell, we don't even have complete browser support yet. There were things on the website that were still running SILVERLIGHT. In 2019. I don't even know how to feel about it.
I brought up our insane technical debt to our PM who told me that we don't have time to worry about things like technical debt. They also wouldn't spend the time to teach me anything, saying they would rather outsource everything then take the time to teach me. So i did. I learned a huge chunk of it myself.
But calling this a developer job was a sick, twisted joke. All our lives revolve around bugnet. Our work is our BN's. So every issue the client emails about becomes BN's. I haven't developed anything. All I've done is clean up others mess.
Except for the one time they did have me develop something. And I did it right and took my time. And then they told me it took too long, forced me to release before it was ready, even though I had never worked on what I was doing before. And it worked. I did it.
They then told me it likely wouldn't even be used anyway. I wasn't very happy at all.
I then discovered quickly the horrors of wanting to make changes on production. In order to make changes to it, we have to... Get this
Write a huge document explaining why. Not to our management. To the customer. The customer wants us to 'request' to fix our application.
I feel like I am literally against a wall. A huge massive wall. I can't get constent from my PM to fix the shitty code they have as a result of outsourcing. I can't make changes without the customer asking why I would work on something that doesn't add something new for them. And I can't ask for any sort of help, and half of the people I have to ask help from don't even speak english very well so it makes it double hard to understand anything.
But what can I do? If I leave my job it leaves a lasting stain on my record that I am unsure if I can shake off.
... Well, thats my tl;dr rant. Im a junior, so maybe idk what the hell im talking about.rant code application bad project management annoying as hell bad code c++ bad client bad design application development16 -
"I'm almost done, I'll just need to add tests!"
Booom! You did it, that was a nuke going off in my head.
No, you shouldn't just need to add tests. The tests should have been written from the get go! You most likely won't cover all the cases. You won't know if adding the tests will break your feature, as you had none, as you refactor your untested mess in order to make your code testable.
When reading your mess of a test case and the painful mocking process you went through, I silently cry out into the void: "Why oh why!? All of this suffering could have been avoided!"
Since most of the time, your mocking pain boils down to not understanding what your "unit" in your "unit test" should be.
So let it be said:
- If you want to build a parser for an XML file, then just write a function / class whose *only* purpose is: parse the XML file, return a value object. That's it. Nothing more, nothing less.
- If you want to build a parser for an XML file, it MUST NOT: download a zip, extract that zip, merge all those files to one big file, parse that big file, talk to some other random APIs as a side-effect, and then return a value object.
Because then you suddenly have to mock away a http service and deal with zip files in your test cases.
The http util of your programming language will most likely work. Your unzip library will most likely work. So just assume it working. There are valid use cases where you want to make sure you acutally send a request and get a response, yet I am talking unit test here only.
In the scope of a class, keep the public methods to a reasonable minimum. As for each public method you shall at least create one test case. If you ever have the feeling "I want to test that private method" replace that statement in your head with: "I should extract that functionality to a new class where that method public. I then can create a unit test case a for that." That new service then becomes a dependency in your current service. Problem solved.
Also, mocking away dependencies should a simple process. If your mocking process fills half the screen, your test setup is overly complicated and your class is doing too much.
That's why I currently dig functional programming so much. When you build pure functions without side effects, unit tests are easy to write. Yet you can apply pure functions to OOP as well (to a degree). Embrace immutability.
Sidenote:
It's really not helpful that a lot of developers don't understand the difference between unit, functional acceptance, integration testing. Then they wonder why they can't test something easily, write overly complex test cases, until someone points out to them: No, in the scope of unit tests, we don't need to test our persistance layer. We just assume that it works. We should only test our businsess logic. You know: "Assuming that I get that response from the database, I expect that to happen." You don't need a test db, make a real query against that, in order to test that. (That still is a valid thing to do. Yet not in the scope of unit tests.)rant developer unit test test testing fp oop writing tests get your shit together unit testing unit tests8 -
Continuation of https://devrant.com/rants/642962/...
You are the decryption key to my encryption,
No one can access my heart except you.
You are the loop in my life,
I always keep coming back to you.
You are my nodemon,
You are always watching over me.
You are the / to everything I do,
Am nothing without you and I will always preserve you.
You are my increment operator,
You add value to my life.
To be continued 😉3 -
Dogecoin hit USD $0.40 recently, which means it's time for the Crypto Rant.
TL;DR: Dogecoin is shit and is logically guaranteed to eventually fall unless it is fundamentally changed.
===========================
If you know how Crypto works under the hood, you can skip to the next section. If you don't, here's the general xyz-coin formula:
Money is sent via transactions, which are validated by *anybody*.
Since transactions are validated by anybody, the system needs to make sure you're not fucking it up on purpose.
The current idea (that most coins use today) is called proof-of-work. In short, you're given an extremely difficult task, and the general idea is you wouldn't be willing to do that work if you were just going to fuck up the system.
For validating these transactions, you are rewarded twofold:
1) You are given a fixed-size prize of the currency from the system itself. This is how new currency is introduced, or "minted" if you prefer.
2) You are given variable-size and user-determined prize called "transaction fees", but it could be more accurately called a "bribe" since it's sole purpose is to entice miners to add YOUR transaction to their block.
This system of validation and reward is called mining.
===========================
This smaller section compares the design o f BTC to Dogecoin - which will lead to my final argument
In BTC, the time between blocks (chunks of data which record transactions and are added to the chain, hence blockchain) is ten minutes. Every ten minutes, BTC transactions are validated and new Bitcoins are born.
In Dogecoin, the time between blocks is only one minute. In Theory, this means that mining Dogecoin is about ten times easier, because the system expects you to be able to solve the proof of work in an average of one minute.
The huge difference between BTC and Doge is the block reward (Fixed amount; new coins minted). The block reward for BTC is somewhat complicated compared to Doge: It started as 50 BTC per block and every 4 years it is halved ("the great halving"). Right now it's 6.25 BTC per block. Soon, the block reward will be almost nothing until BTC hits it's max of 21 million bitcoins "minted".
Dogecoin reward is 10,000 coins per block. And it will be that way for the end of time - no maximum, no great halving. And remember, for every 1 BTC block mined, 10 Doge blocks are mined.
===========================
Bitcoin and Dogecoin are now the two most popular coins in pop culture. What makes me angry is the widespread misunderstanding of the differences between the two. It is likely that most investors buy Dogecoin thinking they're getting in "early" because it's so cheap. They think it's cheap because it isn't as popular as Bitcoin yet. They're wrong. It's cheap because of what's outlined in section two of this rant.
Dogecoin is actually not very far off Bitcoin. Do the math: there's a bit over 100 billion Dogecoin in circulation (130b). There's about 20 million BTC. Calculate their total CURRENT values:
130b * $0.40 = 52b
20m * $60k = 1.2t
...and Doge is rising much, much faster than BTC because of the aforementioned lack of understanding.
The most common thing I hear about Doge is that "nobody expects it to reach Bitcoin levels" (referring to being worth 60k a fucking coin). They don't realize that if Doge gets to be worth just $10 a coin, it will not just reach Bitcoin levels but overtake Bitcoin in value ($1.3T).
===========================
It's worth highlighting that Dogecoin is literally designed to fail. Since it lacks a cap on new coins being introduced, it's just simple math that no matter how much Doge rises, it will eventually be worthless. And it won't take centuries, remember that 100k new Doge are mined EVERY TEN MINUTES. 1,440 minutes in a day * 10K per minute is 14.4 million new coins per day. That's damn near every Bitcoin to ever exist mined every day in Dogecoin10 -
The codebase I'm working with hss rarely comments on it. But when there are comments written they are shit like:
//Kill Matt
//don't ask me where that hard-coded value came from, it just works
//we have to add the elements to the fucking list
Reeeeally helpful. Yep.2 -
OMFG I don't even know where to start..
Probably should start with last week (as this is the first time I had to deal with this problem directly)..
Also please note that all packages, procedure/function names, tables etc have fictional names, so every similarity between this story and reality is just a coincidence!!
Here it goes..
Lat week we implemented a new feature for the customer on production, everything was working fine.. After a day or two, the customer notices the audit logs are not complete aka missing user_id or have the wrong user_id inserted.
Hm.. ok.. I check logs (disk + database).. WTF, parameters are being sent in as they should, meaning they are there, so no idea what is with the missing ids.
OK, logs look fine, but I notice user_id have some weird values (I already memorized most frequent users and their ids). So I go check what is happening in the code, as the procedures/functions are called ok.
Wow, boy was I surprised.. many many times..
In the code, we actually check for user in this apps db or in case of using SSO (which we were) in the main db schema..
The user gets returned & logged ok, but that is it. Used only for authentication. When sending stuff to the db to log, old user Id is used, meaning that ofc userid was missing or wrong.
Anyhow, I fix that crap, take care of some other audit logs, so that proper user id was sent in. Test locally, cool. Works. Update customer's test servers. Works. Cool..
I still notice something off.. even though I fixed the audit_dbtable_2, audit_dbtable_1 still doesn't show proper user ids.. This was last week. I left it as is, as I had more urgent tasks waiting for me..
Anyhow, now it came the time for this fuckup to be fixed. Ok, I think to myself I can do this with a bit more hacking, but it leaves the original database and all other apps as is, so they won't break.
I crate another pck for api alone copy the calls, add user_id as param and from that on, I call other standard functions like usual, just leave out the user_id I am now explicitly sending with every call.
Ok this might work.
I prepare package, add user_id param to the calls.. great, time to test this code and my knowledge..
I made changes for api to incude the current user id (+ log it in the disk logs + audit_dbtable_1), test it, and check db..
Disk logs fine, debugging fine (user_id has proper value) but audit_dbtable_1 still userid = 0.
WTF?! I go check the code, where I forgot to include user id.. noup, it's all there. OK, I go check the logging, maybe I fucked up some parameters on db level. Nope, user is there in the friggin description ON THE SAME FUCKING TABLE!!
Just not in the column user_id...
WTF..Ok, cig break to let me think..
I come back and check the original auditing procedure on the db.. It is usually used/called with null as the user id. OK, I have replaced those with actual user ids I sent in the procedures/functions. Recheck every call!! TWICE!! Great.. no fuckups. Let's test it again!
OFC nothing changes, value in the db is still 0. WTF?! HOW!?
So I open the auditing pck, to look the insides of that bloody procedure.. WHAT THE ACTUAL FUCK?!
Instead of logging the p_user_sth_sth that is sent to that procedure, it just inserts the variable declared in the main package..
WHAT THE ACTUAL FUCK?! Did the 'new guy' made changes to this because he couldn't figure out what is wrong?! Nope, not him. I asked the CEO if he knows anything.. Noup.. I checked all customers dbs (different customers).. ALL HAD THIS HARDOCED IN!!! FORM THE FREAKING YEAR 2016!!! O.o
Unfuckin believable.. How did this ever work?!
Looks like at the begining, someone tried to implement this, but gave up mid implementation.. Decided it is enough to log current user id into BLABLA variable on some pck..
Which might have been ok 10+ years ago, but not today, not when you use connection pooling.. FFS!!
So yeah, I found easter eggs from years ago.. Almost went crazy when trying to figure out where I fucked this up. It was such a plan, simple, straight-forward solution to auditing..
If only the original procedure was working as it should.. bloddy hell!!8 -
I'M BACK TO MY WEBDEV ADVENTURES GUYS! IT TOOK ME LIKE 4 MONTHS TO STOP BEING SO FUCKING DEPRESSED SO I CAN ACTUALLY STAND TO WORK ON IT AGAIN
I learned that the linear gradient looks cool as FUCK. Honestly not too fond of the colors I have right now, but I just wanted to have something there cause I can change it later. The page has evolved a bunch from my original concept.
My original concept was the bar in the middle just being a URL bar and having links on the sides. If I had kept that, it would have taken me a few hours to get done. But as time went on when I was working on it, my idea kept changing. Added the weather (had a forecast for a while but the code was gross and I never looked at the next days anyways, so I got rid of it and kept the current data). I wanted to attempt an RSS reader, but yesterday I was about to start writing the JavaScript to parse the feeds, then decided "nah", ended up making the space into a todo list.
The URL bar changed into a full command bar (writing the functions for the commands now, also used to config smaller things, such as the user@hostname part, maybe colors, weather data for city and API key, etc)....also it can open URLs and subreddits (that part works flawlessly). The bar uses a regex to detect if it's a legit URL (even added shit so I don't need http:// or https://), and if it's not, just search using duckduckgo (maybe I'll add a config option there too for search engines).
At this very moment it doesn't even take a second to fully load. It fetches weather data from openweathermap, parses it, and displays it, then displays the "user" name grabbing a localstorage value.
I'm considering adding a sidebar with links (configurable obviously, I want everything to be dynamic, so someone else could use my page if they wanted), but I'm not too sure about it.
It's not on git yet because I was waiting until I get some shit finished today before I commit. From the picture, I want to know if anyone has any suggestions for it. Also note that I am NOT a designer. I can't design for shit.12 -
Tldr; my "this is not bug, its a feature" moment actually turned my bug into a feature.
Today we were presenting a project which has imposible deadline. I am developing this small project alone (which is probably good). I implemented core features first but I know project still have bugs and a lot of tech debts. Another friend started to presenting our demo and a wild bug appeared as expected. He was adding rows to a table. To add a new you gotta open new modal by clicking + button and fill the form. One of the fields had a bug. When you add row by clicking Ok button, the value of the field stayed there after you open modal again. So its basically a state problem in React. I forgot to clear previous state of modal. When they see that and my friend said "oh we got a bug there". Then I enabled my mic and said "thats not a bug, thats a feature. I didn't want to enter that field again and again when I adding multiple rows and made it persistent." and you know what? They liked the idea! They requested to add that bug to two more fields. I was just joking and my "this is not bug, its a feature" moment actually turned my bug into a feature. Instead of fixing it, I'm creating more of this bug. LOL!5 -
R is the worst language.
* Indices start at 1, so you have to fix all your calculations by either +1 oder -1. It sucks
* Vectors and Lists are both neither vectors nor lists
* Data frames dont have a proper api. Simple operations like add or remove are a pain.
* The naming „conventions“ suck. Why on earth would add dots in your identifiers? You never know if its an object, a value, a function.
* The namespace is cluttered. If you import two libraries that deal with the same problem domain, it is likely that they define functions with clashing names that will overwrite each other defined on import.5 -
FUCK STATIC-SIZED ARRAY!!!
FUCK YOU!!!!
FOR MORE THAN 3 HOURS I TRY TO ADD A VALUE TO AN ARRAY
Nothing work...
Nothing...
AAAAAAAAHHHHHHHHHHHHHHHHHHHHHHH!!!!!18 -
Becoming a High Reputation Stackoverflow Master
Can work like this:
1. Look for questions like "How do I add a value to a list"
2. Post "Use list.Add(x)" faster than any of the 20 expected answers that will be written for this question
3. Become accepted solution
4. Get 100 up votes as more people unaware of API documentation come across your answer
Sometimes answers and questions are so trivial you wonder how this would be upvoted by anyone ever.2 -
So I wrote an application that loads data from a 3rd party API. It allows the user to enter a record locator number and pull it up. By design, the value can be a partial match and it will pull up the record still.
The first API call I make only took 2-3 seconds, so I didn't see an issue as it's loading most of the data the app needs. I keep the filters/fields as they are and move on.
Fast forward 6 months. The user is complaining that the records are taking 30-45 seconds to load. Sure enough, load times are terrible. I've made lots of changes to what fields I'm loading through the API, and I'm calling several additional APIs, so I start pulling pieces of code out to see if anything improves. They all barely make any difference--still 30+ second load times. I end up removing everything except the first API call I developed that was taking 2-3 seconds before. Still taking 30+ seconds.
The 3rd party API allows you to filter using "starts with" or "contains". I used "contains" initially and had no issue, but I decided to try "starts with" since it should fit most use cases.
Load time is less than one second. I add back everything else. Load time is just over a second.
It seems that the 3rd party updated the API and multiplied load times by 10 when using that particular filter. I spent almost an hour on this since the platform doesn't support performance or debugging tools very well, and it all came down to a one line fix.4 -
As a fresh/recent graduate, how I'm supposed to get a job if the minimum requirement for an internship or entry-level job is 2-3 years of working experience! And why the fuck my open source and personal projects don't add any value to my experience!9
-
While coding in C, I once forgot to add a semicolon at the end of a while loop polling a register value.
The logic required me to make it zero as soon as it read non-zero and continue the rest of the process. Hence the 'while' that missed the semicolon ended up being a single instruction assignment to the same volatile register that I kept polling. This caused synchronisation issue with the FPGA, and my code got stuck in an uncertain infinite loop.
Took me 2 days and a silly, yet valid question from my teammate to figure out the cause of this stupid bug.8 -
Fuck Udemy adverty. "You should learn this online machine learning course, it's taught by an 'expert' instructor, you'll learn algorithms in pythaan and 'arr, make robust models, add value to your business." Fuck off with your buzzword mumbo jumbo and just be straight with people, don't treat them like idiots.11
-
When I was in college OOP was emerging. A lot of the professors were against teaching it as the core. Some younger professors were adamant about it, and also Java fanatics. So after the bell rang, they'd sometimes teach people that wanted to learn it. I stayed after and the professor said that object oriented programming treated things like reality.
My first thought to this was hold up, modeling reality is hard and complicated, why would you want to add that to your programming that's utter madness.
Then he started with a ball example and how some balls in reality are blue, and they can have a bounce action we can express with a method.
My first thought was that this seems a very niche example. It has very little to do with any problems I have yet solved and I felt thinking about it this way would complicate my programs rather than make them simpler.
I looked around the at remnants of my classmates and saw several sitting forward, their eyes lit up and I felt like I was in a cult meeting where the head is trying to make everyone enamored of their personality. Except he wasn't selling himself, he was selling an idea.
I patiently waited it out, wanting there to be something of value in the after the bell lesson. Something I could use to better my own programming ability. It never came.
This same professor would tell us all to read and buy gang of four it would change our lives. It was an expensive hard cover book with a ribbon attached for a bookmark. It was made to look important. I didn't have much money in college but I gave it a shot I bought the book. I remember wrinkling my nose often, reading at it. Feeling like I was still being sold something. But where was the proof. It was all an argument from authority and I didn't think the argument was very good.
I left college thinking the whole thing was silly and would surely go away with time. And then it grew, and grew. It started to be impossible to avoid it. So I'd just use it when I had to and that became more and more often.
I began to doubt myself. Perhaps I was wrong, surely all these people using and loving this paradigm could not be wrong. I took on a 3 year project to dive deep into OOP later in my career. I was already intimately aware of OOP having to have done so much of it. But I caught up on all the latest ideas and practiced them for a the first year. I thought if OOP is so good I should be able to be more productive in years 2 and 3.
It was the most miserable I had ever been as a programmer. Everything took forever to do. There was boilerplate code everywhere. You didn't so much solve problems as stuff abstract ideas that had nothing to do with the problem everywhere and THEN code the actual part of the code that does a task. Even though I was working with an interpreted language they had added a need to compile, for dependency injection. What's next taking the benefit of dynamic typing and forcing typing into it? Oh I see they managed to do that too. At this point why not just use C or C++. It's going to do everything you wanted if you add compiling and typing and do it way faster at run time.
I talked to the client extensively about everything. We both agreed the project was untenable. We moved everything over another 3 years. His business is doing better than ever before now by several metrics. And I can be productive again. My self doubt was over. OOP is a complicated mess that drags down the software industry, little better than snake oil and full of empty promises. Unfortunately it is all some people know.
Now there is a functional movement, a data oriented movement, and things are looking a little brighter. However, no one seems to care for procedural. Functional and procedural are not that different. Functional just tries to put more constraints on the developer. Data oriented is also a lot more sensible, and again pretty close to procedural a lot of the time. It's just odd to me this need to separate from procedural at all. Procedural was very honest. If you're a bad programmer you make bad code. If you're a good programmer you make good code. It seems a lot of this was meant to enforce bad programmers to make good code. I'll tell you what I think though. I think that has never worked. It's just hidden it away in some abstraction and made identifying it harder. Much like the code methodologies themselves do to the code.
Now I'm left with a choice, keep my own business going to work on what I love, shift gears and do what I hate for more money, or pivot careers entirely. I decided after all this to go into data science because what you all are doing to the software industry sickens me. And that's my story. It's one that makes a lot of people defensive or even passive aggressive, to those people I say, try more things. At least then you can be less defensive about your opinion.53 -
Working with atlassian products....
Possibility 1
You can either use exactly this one way and only with these specific instructions ...
Which will certainly not work for the project you have.
Possibility 2
There is an feature request which gets ignored for years, someone made a plugin...
But plugin was removed as inactive. :-)
Possibility 3
Atlassian provided in their endless graciousness a plugin.
After hours of deciphering Kotlin / Java code as the documentation is either useless or lacking details...
You did it. You got the REST shit working.
Well.
You just needed a script which wraps the underlying command, parses the commands well defined format like XML with specification.... To a completely gobbled up JSON, that looks like undecipherable shit.
I really hate Atlassian.
https://bitbucket.org/atlassian/...
I just wanted to add code coverage via the REST API by the way.
A really unnecessary and seldomly used future as it seems.
And yeah... The JSON contains a coverage element which contains a semicolon separated key value store, value being a comma separated list of line numbers....4 -
Like a lot of people, I have created an account on a website to find a job.
The funny part was when I was asked for my city (with a little * to indicate that the information is required) and ... the field was just gray and unusable ...
The solution was simple, edit the html to enable the field and add the selected value manually because it wasn't added automatically on selection.
Today i'm not sure if this was a test, a troll of just a crapy form ...
(actually it wasn't speciallt a dev site so i suppose it's the answer 3...) -
Longest I've worked without rest + why?
Over 24 hours. Why?
In our old system, the database had fields, for example, a customer like Total97, Total98, etc. to store values by year (or some date-specific value).
Every January 1, we had to add fields to accommodate the upcoming year and make the appropriate code changes to handle the new fields.
One year the UPS shipping rates changed and users didn't want to 'lose' the old rates, so they wanted new fields added (Rate98, Rate99, etc) so they could compare old vs. new. That required a complete re-write of most of the underlying applications because users wanted to see the difference on any/all applications that displayed a shipping rate. I'll throw in asking 'why?' was often answered with "because we pay you to do what we say". Luckily, we had already gotten to work on a lot of this before January 1st, so we were, for the most part, ready.
January 1st rolls around (we had to be in the office at 3:00AM), work thru changes, spend some time testing, and be done before noon. That didn't happen. The accounting system was a system that wasn't in (and had never been) in scope, and when we flipped the switch, one of the accountants comes into the office:
E: "Guys? None of our Excel spreadsheets are working. They are critical to integration with the accounting software"
Us: "What? Why would you be using Excel to integrate with the software instead of their portal?"
E: "We could never figure it out, so we had a consultant write VBA scripts to do the work."
Us: "OK, a lot of fields changed, but shouldn't be a big deal. How many spreadsheets are we talking about?"
E: "Hundreds. We have a separate spreadsheet for every integration point. The consulting company said it scalable, whatever that means."
Us: "What?! Why we just know hearing about this!?"
E: "Don't worry, the consultant said making changes would be easy, let me show you, just open the spreadsheet..click here..<click><click><click>...ignore that error, it always happens...click that <click><click><click>.."
Us: "Oh good lord, this is going to take hours"
E: "Ha! Probably. All this computer stuff is your job and I've got a family to get to. Later"
Us: "Hey 'VP of IS', can we go home and fix these spreadsheets as-needed this week?"
VP-IS: "Let me check with 'VP-FS'"
<few minutes later>
VP-IS: "No, he said Excel is critical to running their department. We stay until Excel is fixed."
Us: "No, no...its these spreadsheets. I doubt FS needs all of them tomorrow morning."
VP-IS: "That's what I said. Spreadsheets, Excel, same thing. I'll order the pizza. Who likes pepperoni!?"
At least he didn't cheap out on the pizza (only 4 of us and he ordered 6 large, extra pepperoni from one of the best pizza places in town)
One problem after another and we didn't get done until almost 6:00AM. Then...
VP-IS: "Great job guys. I've scheduled a meeting at 8:00AM to review what we did so we can document the process for next year. You've got a couple of hours. Feel free to get some breakfast and come back, or eat the left over pizza in the breakroom fridge. There is a lot left"
Us: "Um...sorry...we're going home."
VP-IS: "WHAT!!...OK...fine. I'll schedule the meeting for 12"
Us: "No...we're going home. We'll see you tomorrow." -
People who don't ++ OPs, nor comments or add anything of value on social media / thread.
Please.
What is your purpose but self projection?16 -
I started my actual gig as CTO of construction group (Innovation Hub) a year ago. And it was a hell of a ride, implementing kind of a scrum-ban for project management, XP, peer-reviews, a git-flow, git commit message formats, linters, unit testing, integration tests, etc...
And it's the fun part because with the CIO we had to drive the board to do A LOT of changes in their IT/Innovation drive.
But in one year there is a lot of KPI that went up :
* Deployment: When I arrived it took three stressful days to deploy a new version of one application, once a month. Today we do it every week, and it takes three annoying hours.
* We had no test. NOTHING! Today we have 85% code coverage for the unit test, and automatic integration tests run by our CI server every day.
* We had almost no documentation. Today our code is our documentation (it automatically extracted and versioned).
* We had 0 add value in the use of git. With commit messages as "dev", "asked task", inside jokes and a lot of "fix" and "changes". Today we have a useful git, and we even use it to create our deploy changelogs (and it's only mildly annoying!).
* More important, the team is happy! They get their purpose, see betterment in their tech mastery. They started doing conception, applicative architecture, presentations, having fun.
There is still a LOT of bad things we are still working on, and trying to solve (support workflow and betterment). But seeing what they already did, I'm so proud of my TEAM! I'm a fucking asshole, workaholic, "just do it" kind of guy. But they managed to achieve so much. Fucking PROUD!! -
GOD ALMIGHTY I HATE SWIFT & XCODE...
Why the fuck does it take a horrendous amount of time to muck about with layout constraints. Why the heck does xcode choose to add constraint layouts to elements that already have pissing constraints! Why does dealing with something as trivial as tables have to be so god damn fucking involved when HTML and CSS let me create and style tables in fuck all lines.
And what the hell is up with how pissing long xcode takes just to figure out that 1 extra line of code I've just added. You jump to another file and xcode finally decides to be an ide again and bitch at the fact that you've forgotten to add some parameter or that they've decided to rename paramter "x" since version fuck nows what.
Working with abstract classes is fun, lets use protocols (because interfaces are too old school) and then lets tack on something we call extensions and then lets make people piss about with convenience initializers.
And lord almighty, what the fuck is up with casting, what all this ?! BS. What's wrong with just checking if the value is null in the first place, or whats wrong with giving something an initial value, oh because having to unwrap shit is more elegant right??
And good god, I need to own a fucking cinema screen just to have the storyboard open, there's less fucking panels on the Sistine Chapel ceiling
then there is in xcode.1 -
Okay, one after another. They like to piss me off, apparently.
Coleague knows something isn't possible with current state of some api and pushes phone to me so I can maybe figure out what to reply to client. I dry-typed in "Its not possible" gave him phone and said "boom done, you know it aint possible"
Okay, TL;DR she got pissed that I am pissed that this BS is thrown at me and I dont want to participate in promissing something I know is undeliverable.
So she told me to go to PM/PO *kind of guy but not rly* with that problem. He aint technical by any mean. We are small company and for some reason this guy has more bearoucratic approach than I thought is possible to fit in one human.
Anyway. Well, apparently we will have meeting what are our options.
It all beginned that one guy promissed other guy undeliverable feature....
And becouse someone couldn't use his fucking brain it's pushed onto me, or I need to figure out how to do it. You cant without introducing safety flaw, period, it's that fuckin' simple.
But nooo, we will have god-knows-how-long meeting, that will bring exacly 0 value, as fking allways, and all I want now is just fucking focus on my fucking code becouse, ya know, I have timeline to follow, I dont have time to all that BS.
And to give you context, while keeping the stuff I cant share secret, imagine you have an API, that is just 'facade' of backend API, and layer of security. And they want to add authoritative endpoint to the facade API. Kind of endpoint "yes, you got paid".
Bravo, big brain, it will not work without like huge-as-fuck vunrability...
IDIOTS
How to not get pissed? Any protips?1 -
I usually crib about how stupid people are and how I struggle to stay afloat.
Let's switch some gears now. A post about some good people, product, and processes.
You know what the common theme here is?
The goodness here cannot be measured. Your first interaction with them makes you feel so comfortable that you start feeling butterflies.
These people just keep on giving. They are selfless. They are pure. They actually care.
And when you think it's done, then they give you some more.
What blows me away is, they don't expect or accept anything in return. Absolutely nothing. Not even a simple thank you.
And they are like a wizard. They walk into your life when you least expect them but need them the most. And when the task is done, they'll be gone before you even know.
No lingering, no drama, no bullshit. Just pure goodness.
Like my ex-lead in current company, I have a very senior guy in neighbouring team (for which they were gonna hire me initially), who also happened to interview me, is a gem.
He takes care of me like his own younger brother. Supports me and always answers my queries no matter how occupied he is.
And same is with good products and processes. They feel effortless. So smooth and add exceptional value to your existence. They give rise to wonderful companies.
You'd never experience a single negative aspect about them. No matter how much you try, things will just keep getting better until they don't need to.
And then they'll be long gone. Never to be seen again and never to be forgotten.
You cherish them only in your memory and wish they lasted longer. But they didn't because the purpose was served.
Such people and experiences inspire me. They push me to become a better human.
No matter how the world is or how it treats me, I must always live with high values and be a better version of past self.
The other evening, I was conversing with my mother where we spoke about some family friends who are insanely wealthy but humble and kind.
Mom and I mutually agreed that they don't have such good traits because they are wealthy, but they are wealthy because they live with humility, kindness, and pure intentions.
World is surely a beautiful place because of such people and I aspire to be one. May lord guide me well :)3 -
Looking for a second opinion/validation.
*Me: “Perhaps this simple and concise way to ensure the user doesn’t lose their data before they leave the page that requires non-zero yet minimal input from the user. (Read: ya gotta push a save/submit button)”
*Everyone else: Let’s pretend to read the user’s mind and perform relatively complicated functions behind the scenes, of which the user will most likely be unaware, that will add an undetermined amount of complexity to the development because we think it’s “where things are going,” by saving the value of a certain HTML element as it loses focus.
Edit: this is an exclusively-internally used app.4 -
2 hour meeting to brainstorm ideas to improve our system health monitoring (logging, alerting, monitoring, and metrics)
Never got past the alerting part. Piss poor excuses for human being managers kept 'blaming' our logging infrastructure for allowing them to log exceptions as 'Warnings', purposely by-passing the alerting system.
Then the d-head tried to 'educate' everyone the difference between error and exception …frack-wad…the difference isn't philosophical…shut up.
The B manager kept referring to our old logging system (like we stopped using it 5 years ago) and if it were written correctly, the legacy code would be easier to migrate. Fracking lying B….shut the frack up.
The fracking idiots then wanted to add direct-bypass of the alerting system (I purposely made the code to bypass alerting painful to write)
Mgr1: "The only way this will work is if you, by default, allow errors to bypass the alerting system. When all of our code is migrated, we'll change a config or something to enable alerting. That shouldn't be too hard."
Me: "Not going to happen. I made by-passing the alert system painful on purpose. If I make it easy, you'll never go back and change code."
Mgr2: "Oh, yes we will. Just mark that method as obsolete. That way, it will force us to fix the code."
Me: "The by-pass method is already obsolete and the teams are already ignoring the build warnings."
Mgr1: "No, that is not correct. We have a process to fix all build warnings related to obsolete methods."
Mgr2: "Yes. It won't be like the old system. We just never had time to go back and fix that code."
Me: "The method has been obsolete for almost a year. If your teams haven't fixed their code by now, it's not going to be fixed."
Mgr1: "You're expecting everything to be changed in one day. Our code base is way too big and there are too many changes to make. All we are asking for is a simple change that will give us the time we need to make the system better. We all want to make the system better…right?"
Me: "We made the changes to the core system over two years ago, and we had this same conversation, remember? If your team hasn't made any changes by now, they aren't going to. The only way they will change code to the new standard is if we make the old way painful. Sorry, that's the truth."
Mgr2: "Why did we make changes to the logging system? Why weren't any of us involved? If there were going to be all these changes, our team should have been part of the process."
Me: "You were and declined every meeting and every attempt to include your area. Considering the massive amount of infrastructure changes there was zero code changes required by your team. The new system simply worked. You can't take advantage of the new features which is why we're here today. I'm here to offer my help in any way I can with the transition."
Mgr1: "The new logging doesn't support logging of the different web page areas. Until you can make that change, we can't begin changing our code."
Me: "Logging properties is just a name+value pair dictionary. All you need to do is standardize on a name and how you add it to the collection."
Mgr2: "So, it's not a standard field? How difficult would it be to change the core assembly? This has to be standard across all our areas and shouldn't be up to the developers to type in anything they want."
- Frack wads smile and nod to each other like fracking chickens in a feeding frenzy
Me: "It can, but what will you call this property? What controls its value?"
- The look I got from both the d-bags I could tell a blood vessel popped.
Mgr1: "Oh…um….I don't know…Area? Yea … Area."
Mgr2: "Um…that's not specific enough. How about Page?"
Mgr1: "Well, pages can cross different areas, and areas cross different pages…what do you think?"
Me: "Don't know, don't care. It's up to you. I just need a name."
Mgr2: "Modules! Our MVC framework is broken up in Modules."
DevMgr: "We already have a field for Module. It's how we're segmenting the different business processes"
Mgr1: "Doesn't matter, we'll come up with a name later. Until then, we won't make any changes until there is a name."
DevMgr: "So what did we accomplish?"
Me: "That we need to review the web's logging and alerting process and make sure we're capturing errors being hidden as warnings."
Mgr1: "Nooo….we didn't accomplish anything. This meeting had no agenda and no purpose. We should have been included in the logging process changes from day one."
Mgr2: "I agree, I'm not sure why we're here"
Me: "This was a brainstorming meeting as listed in the agenda. We've accomplished 2 of the 4 items. I think we've established your commitment to making the system better. Thank you all for coming."
- Mgr1 and 2 left without looking at me or saying a word.1 -
Dont blame me for making Minecraft plugins, but holy shit i really hate stairs right now.
Im modifying some old code of mine to add extra features, and i just need to be able to rotate stairs 90, 180 and 270 degrees, then im past this bump.
Stairs get their direction based on a byte value that makes no fucking sense to me.
North = 3
West = 1
East = 0
South = 2
Ive been drawingto see if that made me go "oh like that", checking if the bits of each value had a system, and now im here.
Titshit.
I dont know who made it like this, but i really dont want to make some static switch or if/else statement to process this directional trash. I want it flexible.
If you spotted a system to the numbers, please mail me a rock, and then tell me how i fix this.12 -
It's been a while since I've heard a consensus of a moronic idea from the corner offices. I was invited to a department planning meeting (just to listen, not necessarily engage or add value) and discussion went to the development of a mobile app.
Mgr1: "The CEO has the net present value of the mobile project as $20 million. Where did he get that number?"
VP: "No idea."
Mgr2: "How will it be any different than our web site that is already mobile compliant?"
VP: "It is to gain market share"
Mgr3: "Market share from who? A mobile app is not going to increase our customer base. At best, it will only move some of our existing customers to mobile. No way it would scale to those numbers."
VP: "The primary benefit is so customers can browse offline."
Mgr2: "Offline browsing isn't listed in the milestones."
Mgr1: "We're not going to push and keep gigs of data up-to-date on someone's phone just for random times they don't have internet access."
VP: "I guess that's right. We can push our pdf catalog. That's only a few hundred meg."
Mgr2: "Pushing the catalog? That's not on the listed milestones"
VP: "Its all assumed."
Mgr3: "Who owns this project? Web team is already maxed to capacity."
Mgr2: "Marketing team only has 3 developers, we can't take on anything as complex as a mobile app and support the existing processes."
Mgr1: "What about the network infrastructure and PCI compliance? We're talking about a system for the web site and another for mobile, right?"
Mgr2: "Who is going to manage all the versions in the app stores and future changes to the mobile platform?"
Mgr4: "Not us"
Mgr2: "Nope"
Mgr1: "OK, good. Its very likely this project will be dead on arrival at the next company strategic meeting."
VP: "Mobile the only project on the strategic meeting agenda. Sorry guys, it's happening. We're not going to leave $20 million sitting on the table.
<awkward silence>
VP: "Next item of business ..."3 -
HR is a dead role in modern tech recruitment. You can pay programmers to do tech interviews and the rest is already automatable. Nobody needs large swarms of cubicle fucks sitting around all day poring through resumes they don’t understand pretending to add value.
Change my mind.10 -
You may know I love to hate tests. Well not the tests actually, what I hate is the TDD culture.
DBMS schema in my app dictates a key can either have a value, or be omitted - it can't be null, and all queries are written with that in mind (also they're checked compile-time against schema). But tester failed to mock schema validation, inserted a bunch of null keys with mock data, actually wrote assertions to check those keys are null (even though they never should be), and wanted me to add "or null" to my "exists" queries.
No, we don't need more tests, and you're not smart with your "edge cases" argument. DBMS and compiler ensure those null values can never exists in our DB, and they're already well tested by their developers. We need you to stop relying on TDD so much you forget about the practical purpose of the code, and to occasionally break from the whole theoretical independent tests to make sure your testing actually aligns with third-party services some code uses.
And no, we don't need more tests to test your mocks, and tests to test those test, and yo dawg, I heard ...5 -
In the 90s most people had touched grass, but few touched a computer.
In the 2090s most people will have touched a computer, but not grass.
But at least we'll have fully sentient dildos armed with laser guns to mildly stimulate our mandatory attached cyber-clits, or alternatively annihilate thought criminals.
In other news my prime generator has exhaustively been checked against, all primes from 5 to 1 million. I used miller-rabin with k=40 to confirm the results.
The set the generator creates is the join of the quasi-lucas carmichael numbers, the carmichael numbers, and the primes. So after I generated a number I just had to treat those numbers as 'pollutants' and filter them out, which was dead simple.
Whats left after filtering, is strictly the primes.
I also tested it randomly on 50-55 bit primes, and it always returned true, but that range hasn't been fully tested so far because it takes 9-12 seconds per number at that point.
I was expecting maybe a few failures by my generator. So what I did was I wrote a function, genMillerTest(), and all it does is take some number n, returns the next prime after it (using my functions nextPrime() and isPrime()), and then tests it against miller-rabin. If miller returns false, then I add the result to a list. And then I check *those* results by hand (because miller can occasionally return false positives, though I'm not familiar enough with the math to know how often).
Well, imagine my surprise when I had zero false positives.
Which means either my code is generating the same exact set as miller (under some very large value of n), or the chance of miller (at k=40 tests) returning a false positive is vanishingly small.
My next steps should be to parallelize the checking process, and set up my other desktop to run those tests continuously.
Concurrently I should work on figuring out why my slowest primality tests (theres six of them, though I think I can eliminate two) are so slow and if I can better estimate or derive a pattern that allows faster results by better initialization of the variables used by these tests.
I already wrote some cases to output which tests most frequently succeeded (if any of them pass, then the number isn't prime), and therefore could cut short the primality test of a number. I rewrote the function to put those tests in order from most likely to least likely.
I'm also thinking that there may be some clues for faster computation in other bases, or perhaps in binary, or inspecting the patterns of values in the natural logs of non-primes versus primes. Or even looking into the *execution* time of numbers that successfully pass as prime versus ones that don't. Theres a bevy of possible approaches.
The entire process for the first 1_000_000 numbers, ran 1621.28 seconds, or just shy of a tenth of a second per test but I'm sure thats biased toward the head of the list.
If theres any other approach or ideas I may be overlooking, I wouldn't know where to begin.16 -
my fist job... i get to edit a c++ code written by a (mind you) programming company that they teamed with for the past(mind you again) 3 years ...
now just for starters, this code was edited by self taught coders that are really good engineers(they are really good), that didnt really know how the code worked before yet they still changed it, and it worked, how ever they wanted some changes.
i get the project files, and there is not one single comment describing what is happening... only code commented out... and no documentation what so ever were done....
so below are some of my comments that i wrote after i finished adding what i had to add, and fixing what i had to fix:
/*first rule of C anything coding, no actual functions in the header, well let me introduce you to a fully functioning thread running program all in the header, enjoy*/
//used to control the thread
// i honestly dont know why, but it worked soooooo yea...
// TG uncommented // for absolutely no reason what so ever...
//used to communicate with the port
//the message to be sent to the inverter, which has a code that will handle it
//hmmmmmm...
//again not usefull since we are using radioButtons
// same ...
// same ...
// same ...
// they said they dont even use this mode, but none the less, same ...
// calculate the checksum for the message
// ....
// one of the things that work, and god forbids i touch
// used for the status displayed on screen
// used for the (censored :P) status in the message
// used for the (censored :P) status in the message
// not used at all, but the message structure contains it and i refuse to edit that abomination
// used for the (censored :P) status in the message
// used for the (censored :P) status in the message
// just dont ask and roll with it, i didnt want to touch this
// saaaaame ...
// if before true this saaaaaame ...
// value of the (censored :P)
// it pains me to say it again, but this is no use
// (censored :P) input
// (censored :P) input
// only place seen , like for real it was just defined,sooooo yea :D
// well you know how it is
// message string
// check sum string
/****below from feed back****/
// (censored :P) coming in
// (censored :P) coming in
// (censored :P) coming in
// (censored :P)
/****below is the output to the receiver ****/
//(censored :P)
// (censored :P)
// (censored :P)
// (censored :P)
//you thought we were done.... nope, no idea. it comes in the feedback
// not used, literally commented out the one time it was used
// same ...
// XD, man this is a blast, same ...
// nope ...
// used to store the port chosen for the communication
// is a static for the number of data we have recorded so far, and as a row indicator for the recording method
// used to indicate the page we are on in the excel file, as well as the point in physical point in the test
// same ... oh look at this a positive same :D
// same ...
// same ...6 -
!rant
We were finishing another sprint of our grocery shop site at school and it was time for a demo.
There we are, showing our work before the other students. Our teams have a healthy habit of always checking each other not to leave some stoopid mistakes in the final versions, so everybody always regExes and validates THE SHIT out of every input field, both in the view and on the server side. But this one team found out that sometimes it's not enough.
Like every team, they're asked to buy a negative value from their shop. The guy clicks through the process, buys exactly -1 of a banana. He clicks the button to purchase and the site returned "Added banana to the cart!" and we're like "haha n00bz". But someone asked them to show the cart and everyone stopped immediately.
There were 9999 bananas in the cart.
Turns out the member responsible for purchase validation made it add 10000 if the quantity of a bought product was negative.
To this day I can't understand why he did that. xD4 -
Fucking fuck sonarcloud and everything about it. Part of the build pipeline for us to deploy code is to ensure that 90% of the code is covered by a unit test. Great in theory, horrible in practice. You think you've written enough tests that actually add value and test a valid piece of functionality but NO, sonarcloud throws a fucking fit because you're at 89.888 then your branch is going nowhere. Because everyone else gets to this stage and writes just enough tests to get the coverage to 90.01% then it becomes a stand off of who will break first; the code coverage threshold or your mental state.4
-
Major rant incoming. Before I start ranting I’ll say that I totally respect my professor’s past. He worked on some really impressive major developments for the military and other companies a long time ago. Was made an engineering fellow at Raytheon for some GPS software he developed (or lead a team on I should say) and ended up dropping fellowship because of his health. But I’m FUCKING sick of it. So fucking fed up with my professor. This class is “Data Structures in C++” and keep in mind that I’ve been programming in C++ for almost 10 years with it being my primary and first language in OOP.
Throughout this entire class, the teacher has been making huge mistakes by saying things that aren’t right or just simply not knowing how to teach such as telling the students that “int& varOne = varTwo” was an address getting put into a variable until I corrected him about it being a reference and he proceeded to skip all reference slides or steps through sorting algorithms that are wrong or he doesn’t remember how to do it and saying, “So then it gets to this part and....it uh....does that and gets this value and so that’s how you do it *doesnt do rest of it and skips slide*”.
First presentation I did on doubly linked lists. I decided to go above and beyond and write my own code that had a menu to add, insert at position n, delete, print, etc for a doubly linked list. When I go to pull out my code he tells me that I didn’t say anything about a doubly linked list’s tail and head nodes each have a pointer pointing to null and so I was getting docked points. I told him I did actually say it and another classmate spoke up and said “Ya” and he cuts off saying, “No you didn’t”. To which I started to say I’ll show you my slides but he cut me off mid sentence and just yelled, “Nope!”. He docked me 20% and gave me a B- because of that. I had 1 slide where I had a bullet point mentioning it and 2 slides with visual models showing that the head node’s previousNode* and the tail node’s nextNode* pointed to null.
Another classmate that’s never coded in his life had screenshots of code from online (literally all his slides were a screenshot of the next part of code until it finished implementing a binary search tree) and literally read the code line by line, “class node, node pointer node, ......for int i equals zero, i is less than tree dot length er length of tree that is, um i plus plus.....”
Professor yelled at him like 4 times about reading directly from slide and not saying what the code does and he would reply with, “Yes sir” and then continue to read again because there was nothing else he could do.
Ya, he got the same grade as me.
Today I had my second and final presentation. I did it on “Separate Chaining”, a hashing collision resolution. This time I said fuck writing my own code, he didn’t give two shits last time when everyone else just screenshot online example code but me so I decided I’d focus on the PowerPoint and amp it up with animations on models I made with the shapes in PowerPoint. Get 2 slides in and he goes,
Prof: Stop! Go back one slide.
Me: Uh alright, *click*
(Slide showing the 3 collision resolutions: Open Addressing, Separate Chaining, and Re-Hashing)
Prof: Aren’t you forgetting something?
Me: ....Not that I know of sir
Prof: I see Open addressing, also called Open Hashing, but where’s Closed Hashing?
Me: I believe that’s what Seperate Chaining is sir
Prof: No
Me: I’m pretty sure it is
*Class nods and agrees*
Prof: Oh never mind, I didn’t see it right
Get another 4 slides in before:
Prof: Stop! Go back one slide
Me: .......alright *click*
(Professor loses train of thought? Doesn’t mention anything about this slide)
Prof: I er....um, I don’t understand why you decided not to mention the other, er, other types of Chaining. I thought you were going to back on that slide with all the squares (model of hash table with animations moving things around to visualize inserting a value with a collision that I spent hours on) but you didn’t.
(I haven’t finished the second half of my presentation yet you fuck! What if I had it there?)
Me: I never saw anything on any other types of Chaining professor
Prof: I’m pretty sure there’s one that I think combines Open Addressing and Separate Chaining
Me: That doesn’t make sense sir. *explanation why* I did a lot of research and I never saw any other.
Prof: There are, you should have included them.
(I check after I finish. Google comes up with no other Chaining collision resolution)
He docks me 20% and gives me a B- AGAIN! Both presentation grades have feedback saying, “MrCush, I won’t go into the issues we discussed but overall not bad”.
Thanks for being so specific on a whole 20% deduction prick! Oh wait, is it because you don’t have specifics?
Bye 3.8 GPA
Is it me or does he have something against me?7 -
I actually feel accomplished because I'm starting to turn one of my side projects into a real project, even if it isn't popular.
I have a discord bot (exclusive to one server, so more of a discord server) that I have been working on for a while with a couple minigames, like connect 4, crossword, blackjack, etc.
It started off very small, but now I see the project really exploding in size. I have a bona fide testing environment, website with domain and HTTPS with sitemap and everything submitted to google, unit tests, and the scope keeps expanding.
I am continuing to only add value, but have legitimate plans to try and make some income from it if things go smoothly.
Now I just need more than 10 users.2 -
Managed to derive an inverse to karatsuba's multiplication method, converting it into a factorization technique.
Offers a really elegant reason for why non-trivial semiprimes (square free products) are square free.
For a demonstration of karatsubas method, check out:
https://getpocket.com/explore/item/...
Now for the reverse, like I said something elegant emerges.
So we can start by taking the largest digit in our product. Lets say our product is 697.
We find all the digits that produce 6 when summed, along with their order.
thats (1,5), (5,1), (2,4), (4,2), and (3,3)
That means for one of our factors, its largest digit can ONLY be 1, 5, 2, 4, or 3.
Lets take karatsubas method at step f (in the link) and reverse it. Instead of subtracting, we're adding.
If we assume (3,3)
Then we take our middle digit of our product p, in this case the middle digit of 697. is 9, and we munge it with 3.
Then we add our remaining 3, and our remaining unit digit, to get 3+39+7 = 49.
Now, because karatsuba's method ONLY deals with multiplication in single digits, we only need to consider *at most* two digit products.
And interestingly, the only factors of 49 are 7.
49 is a square!
And the only sums that produce 7, are (2,5), (5,2), (3,4), and (4,3)
These would be the possible digits of the factors of 697 if we initially chose (3,3) as our starting point for calculating karatsubas inverse f step.
But you see, 25 can't be a factor of p=697, because 25 is a square, and ends in a 5, so its clearly not prime. 52 can't be either because it ends in 2, likewise 34 ending in 4.
Only 43 could be our possible factor of p.
And we *only* get one factor because our starting point has two of the same digit. Which would mean p would have to equal 43 (a prime) or 1. And because p DOESNT (it equals 697), we can therefore say (3,3) is the wrong starting point, as are ALL starting points that share only one digit, or end in a square.
Ergo we can say the products of non-squares, are specifically non-prime precisely because if they *were* prime, their only factors would HAVE to be themselves, and 1.
For an even BETTER explanation go try karatsuba's method with any prime as the first factor, and 1 as the second factor (just multiply the tens column by zero). And you can see why the inverse, where you might try a starting point that has two matching digits (like 3,3), would obviously fail, because the values it produces could only have two factors; some prime thats not our product, or the value one, which is also not our product.
It's elegant almost to the level of a tautology. -
This is more of a story than a rant, but it has some rant-ey elements, so whetever...
I work for a pretty big company. Several departments, teams, many different markets...so it's a big orchestration. The programming department (aprox. 5% of all employees) is the core of the whole company, because everybody else uses software we've written...(a bit off topic, the point is there are a lot of people)
So today, I got assigned with a side-project. The project spec arrives, and as I read through it, I start realizing that upper-management whats me to build an app to fire people instead for them. The app is supposed to track salary, connect with Trello (for departments that use it) to track finished tasks, track sick days, work attendence...a lot of stuff, and at the end, if the situation requires, spit out a person that is of least benefit to the company, to be fired...
Now from coding perspective, this will be very interesting and fun to build, but from a moral standpoint, I'm a bit woried...simply because, indirectly, I'm firing those people. Because, the way I tune the the app(specifically the algorithm that weighs the value of an employee to the company) will cause certain people to get fired...
So I'm woried I'm gonna have a small breakdown when the app goes live and I see someone saying goodbye to theie colegues of something similar...heck, the app might even spit out my name some day(I should probably add a tiny if statement somewhere in there :) )
What do you guys think about this, from a moral standpoint? Would you be okay with building something like this?
(Sorry for the long post :/ )8 -
Fucking product owners. Churning out retarded requirements every sprint and then complaining about how the requirements haven’t been met, just to add new retarded requirements the next sprint.
Hot tip, if your product owner is obsessed over apple events, tell the cunt to go buy a new Apple Watch and suck on apples trillion dollar market value. Fucking goofy cunts.2 -
Just changed some registry stuff, I'm connected with Wifi and LAN at the same time now. It's still shit but actually better than before :D
Add a DWORD-Value (32 Bit) into Computer\HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Policies\Microsoft\Windows\WcmSvc\GroupPolicy ... that's it5 -
If I'm writing an app which has the sole purpose of receiving some data from a server, then sending some other data back (so nothing is stored locally) - what sort of stuff do I write tests for?
Client wants lots of testing to occur, but all of the tests I can think of wouldn't add any value -
This started as an update to my cover story for my Linked In profile, but as I got into a groove writing it, it turned into something more, but I’m not really sure what exactly. It maybe gets a little preachy towards the end so I’m not sure if I want to use it on LI but I figure it might be appreciated here:
In my IT career of nearly 20 years, I have worked on a very wide range of projects. I have worked on everything from mobile apps (both Adroid and iOS) to eCommerce to document management to CMS. I have such a broad technical background that if I am unfamiliar with any technology, there is a very good chance I can pick it up and run with it in a very short timespan.
If you think of the value that team members add to the team as a whole in mathematical terms, you have adders and you have subtractors. I am neither. I am a multiplier. I enjoy coaching, leading and architecture, but I don’t ever want to get out of the code entirely.
For the last 9 years, I have functioned as a technical team lead on a variety of highly successful and highly productive teams. As far as team leads go, I tend to be a bit more hands on. Generally, I manage to actively develop code about 25% of the time to keep my skills sharp and have a clear understanding of my team’s codebase.
Beyond that I also like to review as much of the code coming into the codebase as practical. I do this for 3 reasons. I do this because as a team lead, I am ultimately the one responsible for the quality and stability of the codebase. This also allows me to keep a finger on the pulse of the team, so that I have a better idea of who is struggling and who is outperforming. Finally, I recognize that my way may not necessarily be the best way to do something and I am perfectly willing to admit the same. I have learned just as much if not more by reviewing the work of others than having someone else review my own.
It has been said that if you find a job you love, you’ll never work a day in your life. This describes my relationship with software development perfectly. I have known that I would be writing software in some capacity for a living since I wrote my first “hello world” program in BASIC in the third grade.
I don’t like the term programmer because it has a sense of impersonality to it. I tolerate the title Software Developer, because it’s the industry standard. Personally, I prefer Software Craftsman to any other current vernacular for those that sling code for a living.
All too often is our work compiled into binary form, both literally and figuratively. Our users take for granted the fact that an app “just works”, without thinking about the proper use of layers of abstraction and separation of concerns, Gang of Four design patterns or why an abstract class was used instead of an interface. Take a look at any mediocre app’s review distribution in the App Store. You will inevitably see an inverse bell curve. Lot’s of 4’s and 5’s and lots of (but hopefully not as many) 1’s and not much in the middle. This leads one to believe that even given the subjective nature of a 5 star scale, users still look at things in terms of either “this app works for me” or “this one doesn’t”. It’s all still 1’s and 0’s.
Even as a contributor to many open source projects myself, I’ll be the first to admit that have never sat down and cracked open the Spring Framework to truly appreciate the work that has been poured into it. Yet, when I’m in backend mode, I’m working with Spring nearly every single day.
The moniker Software Craftsman helps to convey the fact that I put my heart and soul into every line of code that I or a member of my team write. An API contract isn’t just well designed or not. Some are better designed than others. Some are better documented than others. Despite the fact that the end result of our work is literally just a bunch of 1’s and 0’s, computer science is not an exact science at all. Anyone who has ever taken 200 lines of Java code and reduced it to less than 50 lines of reactive Kotlin, anyone who has ever hit that Utopia of 100% unit test coverage in a class, or anyone who can actually read that 2-line Perl implementation of the RSA algorithm understands this simple truth. Software development is an art form. I am a Software Craftsman.
#wk171 -
CircleCI:
- Ensuring work has meaning: "Let's make yet an other dashboard webapp that going to replace all of our dashboard webapps which we made to replace all of our dashboard webapps"
-Solving interesting problems: "Let's make this with java 15 instead of java 14!!!! Also add graphql to ADD interesting problems nobody had since the nineties!"
- Gain meaningful value from talent: 'Bitbucket and the whole pipeline died fourth time this week, I'm going to drink a coffee or two..."
- Developers in flow: "Joe went to have a lunch around 11:00, you probably should not look for him until 14:30."
- Bring buying decisions closer to the engineering team: "The boss tried to bring up the pros and cons between aws and azure... The police eventually had to break the ensuing fight in the meeting room. The survivors reported things got truly out of hand when someone mentioned line-endings"
- Bring leadership closer to the engineering team: "There was yet an other agile coached hired, when she asked how should we measure velocity one of the lead devs managed to actually wake up and told her that the wifi is still pretty fucking slow" -
This is PART 2/2 of a series of rants over the course of a software engineering course years ago.
We were four team members, two had never failed a class, I’ll refer to them as MT and FT, male and female top students, respectively, and an older student with some real world experience who I’ll refer to as SR.
Rant 6: After the previous drama MT built the groundwork for the project without allowing us to intervene for a week. When he finally disclosed his code he gave us tasks and I was stuck unable to run the new project, due to the friction with MT I asked SR for help which took a couple of days. MT accused us of not wanting to work and claimed he’d just do everything himself. I continued working on the task improving MT’s code and committed the work, which surprised MT and told me I didn’t have to do it. He ended up complimenting my code and complained less about me as a result.
Rant 7: MT kept giving SR flak for not working and took him out of the repo, which I promptly forked just in case he tried anything scummy. SR was indeed working on certain things, but he wasn’t listening to MT’s demands, there was no team coordination. I had to act as a proxy and push some of SR’s changes myself while informing him of the state of things.
Rant 8: When MT finally added SR back and some of the tasks were cleared up, FT didn’t cooperate. She seemed to have zero initiative and always relied on MT to tell her what to do, which didn’t include coordinating with SR to get the front-end templates running. I tried getting them in a group chat but it didn’t work, she just ignored him.
I learned a few things from that.
1. No matter how smart or experienced someone may seem, sometimes people are just petty or take things too personally.
2. Top students are sometimes too focused on their grades and disregard depth of knowledge and work quality.
3. A bad team at college can somehow make something acceptable if everyone works on things that add some kind of value.1 -
Designer: These form elements should not be textboxes; they should be dropdown menu's.
Me: No problem. Done.
Designer: Could you make X the only selectable option in field A and Y the only selectable option in field B?
Me: I sure can.
Me: Implements a dropdown menu with only one option, knowing that asking questions would label me as "difficult" and "technical". Uploads to production, decides to take a smoke break.
My coping mechanism: Maybe you should also add an Animator to the IK targets on your character controller in Unity instead of depending on a slerped IK weight value.4 -
Why are OSS maintainers so fucking incompetent and cocky? A documentation clearly says to use "use_parent_assets: true" when creating a child theme. Yet not a single fucking line of code actually checks that value. The fix is literary a single if(value) assets = deepMerge(parentAssets, assets). But because some contributor somewhere didn't write that line to the maintainer's liking, it's been hanging in the air for months.
Take your head of of your ass, there's thousands of people paying for support & addons for your product, and you can't add one fucking line to fix a rather critical bug.6 -
So we have this administration page in the clients app that has tables of data.
The user can click on a row to edit or click "Add' to create a new one, doing so pops up a modal with a form full of inputs and a save button at the bottom.
The other day our client told me he was concerned that users would not understand how to edit data and that I should add some text below the first input field of each modal that says "Type in a new value and click 'SAVE' to change the [field name]"
As I implimented this crap, I took a few minutes to come up with a nice way of saying that his idea made no sense, added unnecessary clutter to the UI, and proposed some alternatives.
He essentially said, "Thanks for your much better ideas, for now let's just stick with what we've got and we can revisit this later."
Everytime I open that UI, I physically feel pain and get a little sick.5 -
there is no way YouTube isn't dead as a product
last night I had to switch from matrix voice chat to discord voice chat to talk to somebody (because their phone suddenly doesn't do matrix well, keeps cutting out their mic if their screen is turned off or they switch to a different app wtf). they misinterpreted something I said as talking about "shock value". I think that's a demeaning term that doesn't capture why "bad" content is good. now I'm just chilling trying not to workaholic and first recommendation on YouTube I have is about "what happened to shock value websites". oh I'm sure that's a coincidence
this has been happening increasingly and I fucking hate it. it keeps recommending videos that have absolutely nothing to do with what I'm watching or have ever watched or would even be in the interest of in the past, but I mention it somewhere and it creepily suggests the content to me, always with videos claiming to have 2-3 million views. bullshit. I tried some of these and there's no way anybody cares about this content in such numbers. it's so lukewarm and dumb. and how the hell do they have "opinion" vlogs about every topic? since when did that become the #1 type of content on YouTube? cuz it's 50% of my recommendations and I've never given a shit
I have like 500 subscriptions on YouTube. I've had an account a long time. a lot of them are old channels that stopped being active as YouTube evolved, which I think was a shame. a lot of them had to do with ad revenue or YouTube algorithm just not suggesting their content to new people. they were wholesome, honest channels with really good content I think -- really good game analysis, compilations of unique or weird viral content and the guy was just a funny dude in his basement, etc. but fair I guess. shame, but fair
Then there was the quiet era, where your front page just didn't suggest the good channels and just the stupid channels. it didn't suggest your subscriptions but in your interest area or something. what's the point of subscriptions if you're not showing me them? this is also about the time if I left a comment on a video I ceased receiving replies so I assume I was shadow banned. I have not received a single reply in years now, even on small channels. some content creators noticed if they post on their own channels and accidentally logged out and looked for their comment their own comments don't show up. just weird annoying nonsense that's inappropriate for them to be doing. bruh, please
and then the next wave came, it wasn't just YouTube won't recommend your channel, in the COVID era what came was if you mentioned something then channels with previously millions of views, still currently millions of subscribers, suddenly went down to 5k-50k views per video. bitch please, you expect anyone to believe this nonsense?
then they fucked up the search. I KNOW videos exist and I can't find them. I type in half the video's title, you can't find it. thankfully if you type in every single word exactly you can still find them. bruh that's too much. also just search plain doesn't work. if I'm looking for a specific topic I get 5-10 max videos on that topic and the rest are irrelevant recommendations. this is entirely ridiculous. there's videos I KNOW exist on YouTube and nobody gave a shit about them, like 5 view Benny benassi music clips with a scene from a video game. I can't even meme anymore
this morning a friend on discord sent me a... weird clip, of like an anime skit. problem? well discord embeds YouTube videos. I pressed play. I get... an ad. lol what. I browse away and back to the video. try again. ad. yeah I'm not playing this. I have to refresh the page 20-30 times sometimes just until the ads stop fucking up every time my adblocker ceases working (and then I have to go update it again lol -- by going to the developer page for the ad block because it was banned from the app store so you can't auto update it and have to manually update it every time)
my friend links me a discord plugin to... remove ads... from YouTube embeds... bruh
I used to mod discord but it's annoying, because every time discord updates you have to go re-apply the hack to be able to mod your discord
I think we should just plain move away from YouTube. during COVID era a lot of people got banned in subreddits on reddit. I noticed when you get banned, the subreddit still has you listed as a subscriber. the r/Canada subreddit for example has 3 million subscribers but the activity of a subreddit that's maybe 1k people. increasingly subreddits just became ghost towns after that like that. reddit is a dead website, with fake numbers. I think YouTube is now a dead website, with fake numbers. no fucking way stupid lukewarm opinion videos with absolutely nothing to add are getting 2-3 million views and people are just clamouring for these takes they didn't ask for
also stop listening in on my private conversations. fucking disgusting. idc if an AI is transcribing. ew.11 -
I work at company that uses Drupal for everything. And i mean EVERYTHING. Our dumb CTO once even wanted us to join tender for flight data collection system... of course it would run on fucking drupal...
Yeah i can see its advantages but it has learning curve the shape of the snail shell and if you want it to do something new you either find module for it or drupal will start crying, shits itself and tell you to go fuck yourself.. also it is full of surprises to make your day as miserable as possible, like you send variable as $content['varname'] to user template and it returns as $user_profile['varname']['value']... and yes user template has $content array for content but why use it for storing content that i want to render.. it is used for other content to render... because in drupal content != content...
I started using laravel for my freelance projects and it took my less than 2 week to get up to speed and start working and is incredible fast to work in... You know.. its fun when you want to just add feature you just code that feature into your app.. and not spend 2 fucking years crawling through retarded preprocess functions...
Whenever i try to suggest we use other frameworks.. "Muh drupal has MODULES".. yeah because drupal is the only thing in universe that has modules.. When client has only need for simple site with simple template why use wordpress and have it done in 2 days when you can use drupal have 10 000 unnecessary DB queries that drupal does on every page load to load page title and make that site in a week.. or why use laravel for e-shop with specific functionality requested by client that would take 2 weeks to add in laravel when you can spend 2 months modifing uber-cart or drupal commerce modules only to hit some Drupal core surprise that wont allow for that feature to be implemented...3 -
People have to realize that people are unique no matter the skill set. You can replace the skill set but not the person.1
-
Once again lost source of retoorscript. Wasn't that mad about it, there was some stuff that could've been better anyway.
I wrote a whole new interpreter in 48 hours or so.
It supports user defined functions and native functions that you can add to the VM yourself.
I did spend extra effort to make it faster than python. Who says python is slow never wrote a language.
It has garbage collection and it doesn't contain leaks.
Sad thing is that I have to write the string manipulation functions again. That's a lot of effort.
In the screenshot, obj is not existing, this is how you declare vars, just using it. Works directly as an object. It does keep all his properties if I would assign a value later to obj. Numbers can be property names for some reason.
It would be possible to write a webapplication with it. This requires a decent stdlib. A lot of work.
Other stuff that I'll still have to add:
- loops
- arrays
- if / else
The goal is to make the most easy understandable and easy to extend interpreter ever.
You can just do VM_register(vm, "name", ptr_to_your_function) to add any methods.
Ideas are very welcome17 -
Please don't speak if you don't have anything of value to add. Professional world is not classroom where you get marks for class participation. There's this guy in my team who is supposed to be developer but acts like analyst/PM, talks shit, mostly repeats what other have already said. There's no single meeting where he hasn't spoken or added anything valuable. Hate him.7
-
Any Symfony expert here? I've got quite a tricky question, that I'd love to disqus with another dev.
It's about twig within symfony. I'd like to add a custom node parser, but not for an own tag, but to set some value on each template if it's not set (which can't be done with globals in this case!). I've thought about using a visitor, but from my understanding it gets executed to late, as it requires (probably) to modify the twig AST at compile/parse time.4 -
>Working on code
>Shit works as intended first try, nice
>Goes to play strange bootleg Gameboy Color ROM sent by a friend
>ROM immediately fucking dies
wtf.svg
>Pop emulator's debugger
we're executing from VRAM, stack's firmly embedded in ROM
>why
>Add execution breakpoint to entrypoint of game, restart emulated system (because i'm actually using the legit bios i hacked so it allows null/corrupted games to run)
>Step through everything, everything goes well until all of a sudden we call a function and shit hits the goddamn fan
well we have the culprit
>step through subroutine
if <unused_byte_in_HRAM> != 0 then stackPointer+=32;tryAgain();else return
>***y***
>Realize this is using a bootleg Memory Bank Controller with hard-backed encryption so none of the bytes executed or read as data are the right byte
>Find emulator that'll handle the jank MBC
>read code to try and figure out how it works
if checksumExtendedLogoBlob == some_number then set MBC_Bootleg1 else if checksumExtendedLogoBlob == some_other_number then set MBC_Bootleg2 else if...
>of course
>Spend 10 minutes finding the right bootleg MBC
>code shows 8 possible tables for real bit order based on some value in the cart header
>look for code that gets this value
>not in the header
>not in ANY header in this 1000+ file emulator
>not in any related cpp files???
>get desperate
>email author
>"Delivery failed: email doesn't exist"
fuck me i guess2 -
I recently went through a very detailed and well-explained Python-based project/lesson by Karpathy which is called micrograd. This is a tiny scalar-valued autograd engine and a neural net on top of it.
The project above is, as expected, built on Python. For learning purposes, I wanted to see how such a network may be implemented in TypeScript and came up with a 🤖 micrograd-ts - https://github.com/trekhleb/... repository (and also with a demo - https://trekhleb.dev/micrograd-ts/ of how the network may be trained).
Trying to build anything on your own very often gives you a much better understanding of a topic. So, this was a good exercise, especially taking into account that the whole code is just ~200 lines of TS code with no external dependencies.
The micrograd-ts repository might be useful for those who want to get a basic understanding of how neural networks work, using a TypeScript environment for experimentation.
With that being said, let me give you some more information about the project.
## Project structure
- [micrograd/](https://github.com/trekhleb/...) — this folder is the core/purpose of the repo
- [engine.ts](https://github.com/trekhleb/...) — the scalar `Value` class that supports basic math operations like `add`, `sub`, `div`, `mul`, `pow`, `exp`, `tanh` and has a `backward()` method that calculates a derivative of the expression, which is required for back-propagation flow.
- [nn.ts](https://github.com/trekhleb/...) — the `Neuron`, `Layer`, and `MLP` (multi-layer perceptron) classes that implement a neural network on top of the differentiable scalar `Values`.
- [demo/](https://github.com/trekhleb/...) - demo React application to experiment with the micrograd code
- [src/demos/](https://github.com/trekhleb/...) - several playgrounds where you can experiment with the `Neuron`, `Layer`, and `MLP` classes.
Demo (online)
---------------------
To see the online demo/playground, check the following link:
🔗 https://trekhleb.dev/micrograd-ts3 -
Our owner's other company sells products online (or has the ability to anyways). Their current site is 7+ years old WordPress/Woocommerce and is seriously outdated because the site breaks if you update anything so we've been told to make a new site (finally). They also said they were going to release a whole new line up of products. So the first thing I tried to do was get them to nail down their product line and how shipping was going to be configured. I was told to just use the shipping from the previous site.
Turns out those shipping rates don't use any sort of math or automation at all, there is literally a manually set shipping value for every single product for every single shipping location (30*60) and even values for different quantities. And there's no way to export these rates into a readable table because the plugins they use shove all the data into the postmeta table, I'm forced to go through and put the data into a spreadsheet so that I can attempt to organize it and hopefully find someone way to automate it. Owner claims at one point that he has a similar spreadsheet that's more up to date but for some reason refuses to send it over or put me in touch with the right people in the shipping department.
I've gone through the shipping rates with the old products and the new products and organized them as best I can and each time I've gotten done and shown them the spreadsheet with their products and shipping, they add or change something which requires me to basically wipe the slate clean and start over eating another 50 or so hours of my time, which with everything else really means another month+ to find time to work on it between other projects.
After about a year they finished their products and I finally finished the planning and got approval to build it out for the site. Small victory!!
After about 60 hours plugging these values into the database (only about 1/3 done) I get an email from their head of shipping who tells me the values in my spreadsheet are "terribly inaccurate, in some areas by $100+" and that the data should not be used anywhere.
So after something like a year and a half and 200+ hours of work, the data I've been using to plan all this isn't even accurate. I'm trying not to go crazy here but this kind of shit is unacceptable. When we're done with this I'm going to send the owner an invoice to show him how much money he wasted on this because nothing was planned and he just wanted it built. There's a fucking process for a reason, when you don't follow the process you fuck everything up. If a client had pulled this shit and turned their simple site into this much work they would have been dropped. I get constant emails asking when the new site will be done and every time my answer is "I'm still waiting for x items that I asked for last time you asked where we were." He gets a couple things on the list and sends them back and then goes unresponsive for weeks at a time.
Management has been telling me that I seem more stressed lately but only one of them understands what's going on here when I explain it. The rest say stupid shit like "why don't you automate it" or "make an intern do it." You won't let me hire an intern and even if I did, I'm not sure I could explain how the shipping works now to even trust someone else to do it. I'm hoping when the shipping guy gives me the new sheet that maybe there's some easier solution here because I'm ready to start shooting people.2 -
Product owner said don’t allow decimals in markup and we disabled decimals. At the 11th hour she said well what I wanted was for them to add decimals and we round up and save the rounded version. They initially type in 20.6 round up to 21 then calculate the percentage. And you refresh the page markup now says 21% not your original value. How is that even smart.4
-
I'm a Ruby on Rails developer. I love Rails because you can get so much done so quickly. I've built huge websites on Rails at the consultant shop where I work.
A couple of years ago we added a frontend guy to the team. We switched from doing full stack Rails to using Rails for API only with Vue with Typescript as the frontend. Since this transition took place, I am unable to get anything done on frontend. It takes a huge amount of effort to just add a new input box to a page. Our whole team is on the edge of getting laid off because we can't get things done in a timely fashion for clients and our products consistently run over time and over budget.
Here I'm trying to add an "Are you sure you want to delete this?" message to a form, and I'm on third hour trying to make Typescript happy. I want to assign a variable a value and I have to decipher errors like this "Type 'Ref<string>' is missing the following properties from type 'Vue<string, Record<string, any>, never, never, (event: string, ...args: any[]) => Vue<Record<string, any>, Record<string, any>, never, never, ...>>': $data, $props, $parent, $root, and 30 more." WTF?!?!
Am I just not smart enough for this? Why did programming suddenly become so hard for me? If I had to start off this way I wouldn't be a programmer because I wouldn't have been able to figure this out alone and it wouldn't have been any fun. Anyone else have the HATE for Typescript that I do?12 -
Tldr:
Can't fucking figure out why I'm the only one who can't solve a DP problem in code, when me and friends use the same idea and no one knows why only mine doesn't work...
We are given a task to solve a problem using DP. My friends write their code with the same idea as a solution. Copying the code is not allowed. I follow the same idea but my code won't work. Others look into it, in case they find errors. They can't find any.
The problem (for reference):
Given a fixed list of int's a = (a_1,a_2,...,a_n) and b = (b_1,b_2,...,b_n), a_i and b_i >= 0, a.length == b.length
We want to maximize the sum of a_i's chosen. Every a_i is connected with the b_i at the same index. b_i tells us how many indexes of a we have to skip if choosing the corresponding a_i, so list index of b_i + b_i's value + 1 would be the position of the next a_i available.
The idea:
Create a new list c with same length as a (or b).
Begin at the end of c and save a_n at the same position in c. Iterate backwards through c and at each position add the max value of all previously saved values of c (with regards to the b_i-restriction) with the current a_i, else a_i + 0 if the b_i-resctriction goes beyond the list.
Return the max value of c.
How does that not work for me but for the others?? Funny enough, a few given samples work with my code. I'm questioning my coding ability...7 -
Can anyone help me with this theory about microprocessor, cpu and computers in general?
( I used to love programming when during school days when it was just basic searching/sorting and oop. Even in college , when it advanced to language details , compilers and data structures, i was fine. But subjects like coa and microprocessors, which kind of explains the working of hardware behind the brain that is a computer is so difficult to understand for me 😭😭😭)
How a computer works? All i knew was that when a bulb gets connected to a battery via wires, some metal inside it starts glowing and we see light. No magics involved till now.
Then came the von Neumann architecture which says a computer consists of 4 things : i/o devices, system bus ,memory and cpu. I/0 and memory interact with system bus, which is controlled by cpu . Thus cpu controls everything and that's how computer works.
Wait, what?
Let's take an easy example of calc. i pressed 1+2= on keyboard, it showed me '1+2=' and then '3'. How the hell that hapenned ?
Then some video told me this : every key in your keyboard is connected to a multiplexer which gives a special "code" to the processer regarding the key press.
The "control unit" of cpu commands the ram to store every character until '=' is pressed (which is a kind of interrupt telling the cpu to start processing) . RAM is simply a bunch of storage circuits (which can store some 1s) along with another bunch of circuits which can retrieve these data.
Up till now, the control unit knows that memory has (for eg):
Value 1 stored as 0001 at some address 34A
Value + stored as 11001101 at some address 34B
Value 2 stored as 0010 at some Address 23B
On recieving code for '=' press, the "control unit" commands the "alu" unit of cpu to fectch data from memory , understand it and calculate the result(i e the "fetch, decode and execute" cycle)
Alu fetches the "codes" from the memory, which translates to ADD 34A,23B i.e add the data stored at addresses 34a , 23b. The alu retrieves values present at given addresses, passes them through its adder circuit and puts the result at some new address 21H.
The control unit then fetches this result from new address and via, system busses, sends this new value to display's memory loaded at some memory port 4044.
The display picks it up and instantly shows it.
My problems:
1. Is this all correct? Does this only happens?
2. Please expand this more.
How is this system bus, alu, cpu , working?
What are the registers, accumulators , flip flops in the memory?
What are the machine cycles?
What are instructions cycles , opcodes, instruction codes ?
Where does assembly language comes in?
How does cpu manipulates memory?
This data bus , control bus, what are they?
I have come across so many weird words i dont understand dma, interrupts , memory mapped i/o devices, etc. Somebody please explain.
Ps : am learning about the fucking 8085 microprocessor in class and i can't even relate to basic computer architecture. I had flunked the coa paper which i now realise why, coz its so confusing. :'''(14 -
For our product there is a common type of bug we get reported. It is not really a bug, also it is not a feature - instead it is a missing or incomplete feature.
For example to help users we add a search feature on one screen, but there is no search on some other screen. Now the absence of search on that screen is apparently a bug.
To make things worse to report the bug users try to trick us. They say something like:
"Hey can you help me? How can I find things in the abc screen?"
So I explain how to browse for the item or whatever.
Then they say:
"Ok now how do you do that on the xyz screen?"
Slightly suspiciously I now tell them how you can browse for the item like before or we have this new feature eg. search you can use if that is quicker.
Now they say:
"Don't you think it would be better to have that search on the first screen?"
OK now I realize this is just a trick and the person doesn't actually need help using the software. So I tell him how we only added the feature on one screen and if he thinks there is value adding it on other screens he can put enhancement request in and if wants he can talk to my boss about making it a priority.
Then they go on asking other rhetorical questions like:
"why was it designed like this?"
"Are you guys deliberately trying to make life harder for people by making them learn different ways to do things?"
I now want to delete the new search feature but luckily it is close to lunch time so I have a good excuse to escape the conversation.3 -
My biggest flaw when working in IT: I will refuse to prioritize time- consuming work with minimal added value (cf premature optimization, 0.001% edge cases) when I have a backlog of work that will add much more, obvious value and I will not budge to manager or architect power-plays and tendencies to micromanage my responsibilities, even if it may eventually end up getting me in trouble.2
-
If there is something I hate, it's when peoples emails end with "Sent from my iPhone".
It literally doesn't add anything of value to the conversation, on the contrary it only shows that the person is either too indifferent or lazy to turn it off, or *shivers* actually thinks it's cool.1 -
CSS (and all of frontend) is hard. The last few braincells left in me are slowly dying.
I just wanted a progress bar. HTML 5 supports <progress> out of the box. But all browsers want to act differently. Add more boilerplate for each browser type. Somehow got a transparent background on progress bar but it still won't let me change progress color.(Surprisingly, only IE let me change the color) At last, settled with a transparent div with a colored span inside, + js to handle value. Was this really the best way? Nope. But this was the only thing that worked,(other than importing a JS library, which would render a SVG to replicate a progressbar)
Why is front end so convoluted? Half of the things do not even make sense to me. Is this really the direction we want to go in the future?9 -
So I made a couple slight modifications to the formula in the previous post and got some pretty cool results.
The original post is here:
https://devrant.com/rants/5632235/...
The default transformation from p, to the new product (call it p2) leads to *very* large products (even for products of the first 100 primes).
Take for example
a = 6229, b = 10477, p = a*b = 65261233
While the new product the formula generates, has a factor tree that contains our factor (a), the product is huge.
How huge?
6489397687944607231601420206388875594346703505936926682969449167115933666916914363806993605...
and
So huge I put the whole number in a pastebin here:
https://pastebin.com/1bC5kqGH
Now, that number DOES contain our example factor 6229. I demonstrated that in the prior post.
But first, it's huge, 2972 digits long, and second, many of its factors are huge too.
Right from the get go I had hunch, and did (p2 mod p) and the result was surprisingly small, much closer to the original product. Then just to see what happens I subtracted this result from the original product.
The modification looks like this:
(p-(((abs(((((p)-(9**i)-9)+1))-((((9**i)-(p)-9)-2)))-p+1)-p)%p))
The result is '49856916'
Thats within the ballpark of our original product.
And then I factored it.
1, 2, 3, 4, 6, 12, 23, 29, 46, 58, 69, 87, 92, 116, 138, 174, 276, 348, 667, 1334, 2001, 2668, 4002, 6229, 8004, 12458, 18687, 24916, 37374, 74748, 143267, 180641, 286534, 361282, 429801, 541923, 573068, 722564, 859602, 1083846, 1719204, 2167692, 4154743, 8309486, 12464229, 16618972, 24928458, 49856916
Well damn. It's not a-smooth or b-smooth (where 'smoothness' is defined as 'all factors are beneath some number n')
but this is far more approachable than just factoring the original product.
It still requires a value of i equal to
i = floor(a/2)
But the results are actually factorable now if this works for other products.
I rewrote the script and tested on a couple million products and added decimal support, and I'm happy to report it works.
Script is posted here if you want to test it yourself:
https://pastebin.com/RNu1iiQ8
What I'll do next is probably add some basic factorization of trivial primes
(say the first 100), and then figure out the average number of factors in each derived product.
I'm also still working on getting to values of i < a/2, but only having sporadic success.
It also means *very* large numbers (either a subset of them or universally) with *lots* of factors may be reducible to unique products with just two non-trivial factors, but thats a big question mark for now.
@scor if you want to take a look.5 -
Ops teams that are "assuring" stability of production by being the only ones who can click to deploy to Prod add no value.1
-
Does Professional Scrum Master certification add any value to a devs profile? I am asking because I failed in the first attempt. 😟4
-
Trying to add money to a prepaid SIM card today. Their website is a mess. Plus and minus buttons were not functioning, so my only option was to add 15 euro. Checked the console, no errors. Tried triggering the buttons jQuery, no luck. Found a data value attached to the submit button set to 15. Changed to 10, clicked submit, and BOOM, it worked! You just got engineered!
After I paid, I was curious, went back and set it to -15, and tried it again. Unfortunately, they know about backend validation. -
It's time for war!
I have two examples doing the same thing. They're bot generated by chatGPT.
React:
import React, { useState } from 'react';
function IncrementalButton() {
// Create state to hold the count value
const [count, setCount] = useState(0);
// Function to handle incrementing the count
const increment = () => {
setCount(count + 1);
};
return (
<div>
<h2>Count: {count}</h2>
<button onClick={increment}>Increment</button>
</div>
);
}
export default IncrementalButton;
VUE:
<template>
<div>
<h2>Count: {{ count }}</h2>
<button @click="increment">Increment</button>
</div>
</template>
<script>
export default {
data() {
return {
count: 0,
};
},
methods: {
increment() {
this.count++;
},
},
};
</script>
<style>
/* Add your CSS styles here if needed */
</style>
Whats better in your opinion?17 -
Apprenticeship instead of higher education might be a better mode of 1) learning practical skills rather than academic theory, 2) keeping those learned skills modern rather than stale and outdated, 3) skipping all the hippy-dippy college requirements that don’t actually add value to your career.4
-
I'm an iOS developer and I cringe when I read job specs that require TDD or excessive unit testing. By excessive I mean demanding that unit tests need to written almost everywhere and using line coverage as a measure of success. I have many years of experience developing iOS apps in agencies and startups where I needed to be extremely time efficient while also keeping the code maintainable. And what I've learned is the importance of DRY, YAGNI and KISS over excessive unit testing. Sadly our industry has become obsessed with unit tests. I'm of the opinion that unit tests have their place, but integration and e2e tests have more value and should be prioritised, reserving unit tests for algorithmic code. Pushing for unit tests everywhere in my view is a ginormous waste of time that can't ever be repaid in quality, bug free code. Why? Because leads to making code testable through dependency injection and 'humble object' indirection layers, which increases the LoC and fragments code that would be easier to read over different classes. Add mocks, and together with the tests your LoC and complexity have tripled. 200% code size takes 200% the time to maintain. This time needs to be repaid - all this unit testing needs to save us 200% time in debugging or manual testing, which it doesn't unless you are an absolute rookie who writes the most terrible and buggy code imaginable, but if you're this terrible writing your production code, why should your tests be any better? It seems that especially big corporate shops love unit tests. Maybe they have enough money and resources to pay for all these hours wasted on unit tests. Maybe the developers can point their 10,000 unit tests when something goes wrong and say 'at least we tried'? Or maybe most developers don't know how to think and reason about their code before they type, and unit tests force them to do that?12
-
Top 12 C# Programming Tips & Tricks
Programming can be described as the process which leads a computing problem from its original formulation, to an executable computer program. This process involves activities such as developing understanding, analysis, generating algorithms, verification of essentials of algorithms - including their accuracy and resources utilization - and coding of algorithms in the proposed programming language. The source code can be written in one or more programming languages. The purpose of programming is to find a series of instructions that can automate solving of specific problems, or performing a particular task. Programming needs competence in various subjects including formal logic, understanding the application, and specialized algorithms.
1. Write Unit Test for Non-Public Methods
Many developers do not write unit test methods for non-public assemblies. This is because they are invisible to the test project. C# enables one to enhance visibility between the assembly internals and other assemblies. The trick is to include //Make the internals visible to the test assembly [assembly: InternalsVisibleTo("MyTestAssembly")] in the AssemblyInfo.cs file.
2. Tuples
Many developers build a POCO class in order to return multiple values from a method. Tuples are initiated in .NET Framework 4.0.
3. Do not bother with Temporary Collections, Use Yield instead
A temporary list that holds salvaged and returned items may be created when developers want to pick items from a collection.
In order to prevent the temporary collection from being used, developers can use yield. Yield gives out results according to the result set enumeration.
Developers also have the option of using LINQ.
4. Making a retirement announcement
Developers who own re-distributable components and probably want to detract a method in the near future, can embellish it with the outdated feature to connect it with the clients
[Obsolete("This method will be deprecated soon. You could use XYZ alternatively.")]
Upon compilation, a client gets a warning upon with the message. To fail a client build that is using the detracted method, pass the additional Boolean parameter as True.
[Obsolete("This method is deprecated. You could use XYZ alternatively.", true)]
5. Deferred Execution While Writing LINQ Queries
When a LINQ query is written in .NET, it can only perform the query when the LINQ result is approached. The occurrence of LINQ is known as deferred execution. Developers should understand that in every result set approach, the query gets executed over and over. In order to prevent a repetition of the execution, change the LINQ result to List after execution. Below is an example
public void MyComponentLegacyMethod(List<int> masterCollection)
6. Explicit keyword conversions for business entities
Utilize the explicit keyword to describe the alteration of one business entity to another. The alteration method is conjured once the alteration is applied in code
7. Absorbing the Exact Stack Trace
In the catch block of a C# program, if an exception is thrown as shown below and probably a fault has occurred in the method ConnectDatabase, the thrown exception stack trace only indicates the fault has happened in the method RunDataOperation
8. Enum Flags Attribute
Using flags attribute to decorate the enum in C# enables it as bit fields. This enables developers to collect the enum values. One can use the following C# code.
he output for this code will be “BlackMamba, CottonMouth, Wiper”. When the flags attribute is removed, the output will remain 14.
9. Implementing the Base Type for a Generic Type
When developers want to enforce the generic type provided in a generic class such that it will be able to inherit from a particular interface
10. Using Property as IEnumerable doesn’t make it Read-only
When an IEnumerable property gets exposed in a created class
This code modifies the list and gives it a new name. In order to avoid this, add AsReadOnly as opposed to AsEnumerable.
11. Data Type Conversion
More often than not, developers have to alter data types for different reasons. For example, converting a set value decimal variable to an int or Integer
Source: https://freelancer.com/community/...2 -
I'm so fed up why stupid fucks who yell to everyone "You must do TDD, because... Reasons!!!!". The fuckers even dare to call themselves " agilists" or "craftsman"...
The only reason to do TDD is to create Good Unit Tests. But by not stating the main purpose, you add a stupid process without add value.... The solution just became the problem!
So what if something goes wrong? Well, you didn't really followed TDD, because TDD never fails!!
So fuck ignorant stupid fuckers!!!!!
Having Good Unit Testing is the aim. TDD is one way to do it. Not THE WAY!!!
Also, stop using the word " coverage". It doesn't mean fuck!! If you know what kind of coverage you are completing, there could be some value...6 -
Wanted to add alerting for systemd services in Prometheus today, which spontaneously turned out to be a huge pain in the lower human backend.
For some reason, on Ubuntu 16.04 systemd adds services without unit files for software, that isn't even installed on the damn server (in this case for mysql-server / mysql-common and mysql-client are installed) and lists them as "not-found" and "inactive". The prometheus node exporter that we use, has a little bug in the systemd collector that makes sure that the states of *all* services are collected - even those without a unit file.
so those metrics are pulled by prometheus and now I have to take with those faulty metrics in the condition logic of the alert, because I'm trying to trigger that one on a service which is listed with state "active" = 0 or "failed" = 1.
now guess. right! If the unit file doesn't exist, the regarded systemd service is marked as "inactive", which is another possible state of the metrics in the node exporter. the problem is that the value 1 for state "inactive" means, that "active" has the value 0 (not even wrong) and the alert is triggered.
so systemd fucks up somehow, the node exporter collector fucks up because systemd fucked up and I have to unfuck this with some crazy horse shit logic. w.t.f. to that.
the only good news is, that it works like a charm on Ubuntu 18.04, as far, as I can tell.
while writing this little rant, I thought of a solution.
I could try to change the alert condition to state "active" = 0 AND "failed" = 1.. but that will wait till tomorrow.
one does not simply patch monitoring conditions at midnight..3 -
Hey there! Anyone got some advice on how to find projects to contribute to pro bono? I'm not looking to enhance my profile, but rather just want to add value to not for profit causes. I tried browsing donatecode.com, but I'm not quite happy with what I found.1
-
So, I just (few hours ago)made a new variable that's either brilliant or innately flawed... not sure yet. It's an oddly unique var...
__bs__
So far I only made it in python and windows env (i script like the methodology of css).
I bet you're wondering how I've defined __bs__ and the practicality of it.
__bs__ is derived from a calculated level of bullshit that annoys me to tolerate, maintain, etc. as well as things that tend to throw nonsensical errors, py crap like changing my strings to ints at seemingly random times/events/cosmic alignments/etc or other things that have a history of pulling some bs, for known or unknown reasons.
How/why did this come about now?
Well I was updating some symlinks and scripts(ps1 and bat) cuz my hdd is so close to death I'm wondering if hdd ghosts exist as it's somehow still working (even ostream could tell it should be dead, by the sound alone).
A nonsense bug with powershell allowing itself to start/run custom ps1scripts with the originating command coming from a specific batch script, which worked fine before and nothing directly connected to it has changed.
I got annoyed so took an ironic break from it to work on python crap. Python has an innately high level of bs so i did need to add some extra calculations when defining if a py script or function is actually __bs__ or just py.
The current flavour of py bs was the datetime* module... making all of my scripts using datetime have matching import statements to avoid more bs.
I've kept a log of general bs per project/use case. It's more like a warning list... like when ive spent hours debugging something by it's traceback, meticulous... to eventually find out it had absolutely nothing to do with the exception listed. Also logged aliases i created, things that break or go boom if used in certain ways, packages that ive edited, etc.
The issue with my previous logging is that it's a log... id need to read it before doing anything, no matter how quick/simple it should be, or im bound to get annoyed with... bs.
So far i have it set to alert if __bs__ is above a certain int when i open something to edit. I can also check __bs__ fot what's causing the bs. I plan to turn it into a warning and recording system for how much bs i deal with and have historical data of personal performance vs bs tolerance. There's a few other applications i think ill want to use it for, assume it's not bs itself.
*in case you prefer sanity and haven't dealt with py and datetime enough, here's the jist:
If you were to search any major forum like StackOverflow for datetime use in py, youd find things like datetime.datetime.now() and datetime.now() both used, to get the same returned value. You'll also find tons of posts for help and trying to report 'bugs', way more than average. This is because the datetime package has a name conflict... with itself. It may have been a bug several years ago, but it beeb explicitly defined as intentional since.2 -
Okay, I hope a few people can help me with this; what are the benefits/reasons to use MS technologies? I'm talking about .NET, ASP, Windows Server, Powershell...
I've never understood it. I love Nodejs because you don't have any packages unless you ask for them. Alpine Linux is amazing! It runs on 8MB of RAM from fresh and doesn't need much more space to install.
You want .NET core? 140MB download. You're configuring database connection strings? Feel free to type in whatever you like, it'll parse and replace with some magic variables that have come from some other random file.
I was using Powershell recently, needed to set an env variable. Bash is happy with "export name=value". You want to do that in Powershell? I just googled it and found an entire 40-minute read discussing how to set env vars. Why?! It should be one command, and I don't know who thought that "Get-ChildItem" was _obviously_ referring to env variables.
It seems to me that everywhere MS has got their hands on development-wise, it inherits the typical sales bullshit. No no, you can't call them "websockets", they have to be branded "SignalR" and add tons of overhead. You can't say "disable notifications" it has to be "focus assist". I'm really surprised something as simple as a keyboard hasn't become a "varied user input device" or something of the like.
Am I alone in thinking this?4 -
Chromium has royally fucked their own devtools.
You wanna add a style property? No. You're only allowed to update styles already that are there unless you click on some arbitrary space between brackets and properties.
You wanna click on a property's value to edit it? No. You get a dropdown to edit the unit value OR you can slide the mouse to update the value, nothing else.
You want to update CSS in the inspector, or switch them on or off? No. You get CSS that breaks as soon as you apply it and turns into garbage.
You want to copy CSS from the inspector after changing it? No. You get a line break in between each word for NO FUCKING REASON.
I hate web development sometimes. -
Exceptions... Are they good for anything? I haven't seen them add value to code once in my career...
-
I want to manipulate CSV files with Python and I was using NumPy, what I want to do is 3 columns, with an undetermined number of rows, and I want to be able to remove, add and edit every value, this is my questions:
Should I use NumPy? (if yes, please tell me how, I've been searching on google and I couldn't find anything of help! If not, please tell me what I should use,)3 -
Ok that's ALSO two more brand new phones totalling over 1000 in value they owe John boy here
And many months of lodging and other fun things and some hard drive cases and several hard drives full of earlier photos and videos of him
And let's just add on some extra money for making people act crazy.
Not trying to be patterned into you peoples shit by reinforcing my own self destructive behavior like some kind of goddamn drug addict
Obviously the end result sucks
Look at all these miserable fucks ! -
I have learnt html,css, and some basic javascript for web development,and made a few projects including a calculator with prompts.This is the code :
<script type="text/javascript">
function prote(){
let firstNum=prompt("Enter first number")
let secondNum=prompt("Enter second number")
let num1=parseInt(firstNum);
let num2=parseInt(secondNum);
let result=num1 + num2;
alert(result);
}
function prote2(){
let firstNum=prompt("Enter first number")
let secondNum=prompt("Enter second number")
let num1=parseInt(firstNum);
let num2=parseInt(secondNum);
let result=num1 - num2;
alert(result);
}
function prote3(){
let firstNum=prompt("Enter first number")
let secondNum=prompt("Enter second number")
let num1=parseInt(firstNum);
let num2=parseInt(secondNum);
let result=num1* num2;
alert(result);
}
function prote4(){
let firstNum=prompt("Enter first number")
let secondNum=prompt("Enter second number")
let num1=parseInt(firstNum);
let num2=parseInt(secondNum);
let result=num1/num2;
alert(result);
}
</script>
</body>
<form>
<br>
<input type= "button" value="Add" onclick="prote()" />
<input type= "button" value="Subtract" onclick="prote2()" /><br><br>
<input type= "button" value="Multiply" onclick="prote3()" />
<input type= "button" value="Divide" onclick="prote4()" />
</form>
However I want to do game dev and I feel it may have been a mistake to start learning web development,I originally started learning code in roblox studio,however some do not consider making games in roblox studio "REAL" game development and I didn't exactly feel it was either.I messed around with unity and found the layout quite similar to roblox studio. However
I heard phaser uses javascript and Unity uses C#.In which case using phaser would not require using a new language.However I am aware that If I want to make 3d games(Which I do) I will have to move to unity eventually.Basically, as a beginner should I switch to unity and C# first or Phaser and javascript first.6 -
I have the following scenario with a proposed solution, can anyone please confirm it is a secure choice:
- We have critical API keys that we do not want to ship with the app because de-compiling will give access to those keys, and the request is done before the user logs in, we are dealing with guests
Solution:
- Add a Lambda function which accepts requests from the app and returns the API keys
- Lambda will accept the following:
1. Android app signing key sha1
2. iOS signing certificate sha1
- If lambda was able to validate them API keys are sent back.
My concerns:
- Can an attacker read the request from the original (non-tampered) apk and see what the actual sha1 value is on his local network?
- If the answer to the question above is yes, what is the recommended way to validate that the request received is actually from the app that we shipped and not from curl/postman/script/modified version of the app11 -
We get our degree from a high-end higher education institution and with it we have proven that we studied Computer Science and a number of important programming languages in-depth.
Now why is it that when we get a job as a Software Developer, that people only seem to value you if you get industry certificates in those programming languages?
I understand a degree forms the basis with which to tackle modern-day software problems, but for your entire education to be practically invisible to stakeholders? That's what seems strange to me. We are valued by the number of certificates we have? Something doesn't add up. The only reason for this I can see is that the Business department hasn't had the thorough STEM education we had and thus thinks we are still novices who need to get 'trained'.2 -
I need some help with parking a domain in ovh.com webhosting. It's a real pain in the ass so any input is strongly appreciated. I kinda figured out what todo already, but still need some clarification.
Normally after buying a webhosting all I would need to do is login to my domain registrar's website and in the control panel just change nameservers to webhosting nameservers and that's all. Webhosting provider would take care of the rest (subdomain creation, e-mail creation and etc.) But because OVH are assholes, they support this type of domain parking only for domains registered at OVH.
For external domains, procedure is as follows:
For the configuration to function, you will need to make the following adjustments with the current provider:
Insert a TXT record for the domain ovhcontrol.mydomain.com with the value jwyPolzgrZyIShzaQItqw
Point the A record of your domain mydomain.com to 51.244.97.19
Point the A record of your domain www.mydomain.com to 51.244.97.19
So basically I had to login to registrars cPanel and first of all I had to park my domain back to my registrar (I had to switch to default nameservers which are provided by domain registrar)
Only then I got advanced access to dns zone in order to add the required records above.
When I open my domain registrars dns zone cpanel this is what I see:
http://prntscr.com/nekx40
So basically, as I understand, I just need to add these required records like this?
http://prntscr.com/nekxjc
Am I correct?
So basically my OVH webhosting doesn't deal with dns zone at all, I will have to use my own registrar for adding subdomains?
What about e-mail addresses? OVH doesnt allow me to create emailboxes for "externally" parked domain addresses. Will I have to search for some e-mail provider, and add some additional records?
Any input/help would be appreciated.1 -
So im about to finish a mean stack bootcamp in 2 weeks. Im working on my final project and its nothing too fancy im just doing a simple inventory app (i have future plans for it to bundle it into an entire suite for a specific subset of retail). So i take my live coding exam and fork it (simple app with crud finished) and im trying to add an edit feature that populates tge fields with the prior data. Spent the whole of yesterday working on it from 12a-midnight. Just this one feature to bring previous values into an edit page. Seems simple enough. But it wasnt working right. So im looking all over posted on SO even got a friend of mine thats been programming for 20 years to help me and we cant figure out why it thinks a variable is undefined when it clearly has a value dorectly before the save method fires. (Console.logged that shit)
At about midnight i realize its because i needed to write a router.put in the api because i was just using the regular save originally :/ -
Not so awful I suppose as long as it's produces quality output
Still only interested in davinci
Question
When chatgpt recognizes stateful requests "modify the part of the procedure Jojon where it updates storeitem to add a column verifiedbyhuman and set it's value to true" is chatgpt feeding everything at once to do davinci ?1