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 - "temptation"
-
So I told my wife one week ago: "Yeah, you should totally learn to code as well!"
Yesterday a package arrived, containing a really beautiful hardcover book bound in leather, with a gold foil image of a snake debossed into the cover, with the text "In the face of ambiguity -- Refuse the temptation to guess" on it.
Well, OK, that's weird.
My wife snatches it and says: "I had that custom made by a book binder". I flip through it. It contains the Python 3.9 language reference, and the PEP 8 styleguide.
While I usually dislike paper dev books because they become outdated over time, I'm perplexed by this one, because of how much effort and craftsmanship went in to it. I'm even a little jealous.
So, this morning I was putting dishes into the dishwasher, and she says: "Please let me do that". I ask: "Am I doing anything wrong?"
Wife responds: "Well, it's not necessarily wrong, I mean, it works, doesn't it? But your methods aren't very pythonic. Your conventions aren't elegant at all". I don't think I've heard anyone say the word "pythonic" to me in over a decade.
And just now my wife was looking over my shoulder as I was debugging some lower level Rust code filled with network buffers and hex literals, and she says: "Pffffff unbelievable, I thought you were a senior developer. That code is really bad, there are way too many abbreviated things. Readability counts! I bet if you used Python, your code would actually work!"
I think I might have released something really evil upon the world.29 -
Friend of mine killed his MacBook with some Softdrink.
Just poured it all over his poor a1502.
He let it dry for a few days, it starts to work again.
Except the battery.
Goes on Amazon and buys a new battery.
New battery doesn't work either and so he tells me about it and I as stupid as I am couldn't resist the temptation to finally work on a MacBook like my "hero" Lois Rossmann does.
So turns out the board is good.
Cleaned it up and basically nothing happened to it.
So what's the deal with "los batlerias"?
The first got hit by liquid, the second had a broken connection to a cell.
That could have happened through my friend, installing it without testing it first, or at the seller, so it being a DOA battery.
Now away from the stupidity of my friend and the situation to the actual source for this rant.
Once something happens to a modern Managed battery, the Battery Management System (BMS) disconnects the voltage from the system and goes into an error state, staying there and not powering anything ever again.
For noobs, it's dead. Buy a new one.
But It can be reset, depending you know how to, and which passwords were set at the factory.
Yes, the common Texas instruments BQ20Zxx chips have default passwords, and apple seems to leav them at default.
The Usb to SMBus adaptors arrived a few days ago and I went to prod the BMS.
There is a very nice available for Windows called BE2works, that I used the demo of to go in and figure out stuff. The full version supports password cracking, the demo not.
After some time figuring out how Smart Battery Systems (SBS) "API" works, I got to actually enter the passwords into the battery to try get into manufacturer and full access mode.
Just to realise, they don't unlock the BMS.
So, to conclude, my friend bought a "new" battery that was most likely cut out of a used / dead macbook, which reports 3000mah as fully charged instead of the 6xxx mah that it should have, with 0 cycles and 0hours used.
And non default access.
This screams after those motherfuckers scaming the shit out of people on Amazon, with refurb, reset, and locked fucken batteries.
I could kill those people right now.
Last but not least,
My friend theoretically can't send it back because I opened the battery to fix the broken connection.
Though maybe, it'll get send back anyway, with some suprise in the package.9 -
Hello again, everyone. I've been busy with all the paperwork at my ship (will make a post about it later) but for now, I'll bore you with another story (not navy one, fortunately) to justify my slacking off.
And this story... is the story on how I got into ITSec. And it is pretty damn embarrassing. It all began when I was 16. I was hooked on battleknight.gameforge.com, a browser game. My father had just had ADSL installed at our home, and the new opportunities before me were endless. Well...
After I've had my fill with the porn torrents and them opportunities dwindled to just a few dozens, I began searching for free games, and I stumbled on that game. I played a lot, but as a free-to-play game, it was also pay-to-win. I didn't have a credit card, so I paid for a few gems with SMS messages. Fast forward a couple of years, I got into the Naval Academy. A guy came in to advertise something (I think it was an encyclopaedia or something - yes, wikipedia wasn't a thing back then) and to pay for it, we could apply for a credit card. So I applied. And I resisted the temptation for a year.
Note: prepaid wasn't that known where I live, so using credit cards was the only way for online transactions.
So I made 1 transaction. Just one. After a couple of months my monthly report from the bank came, showing a 2.5$ (I think) transaction on Paypal. I paid no mind, thinking that it was some hidden fee. Oh boy, I shit you not, I was THAT much of an idiot. Six months later, BOOM!
600$ transaction to ebay via paypal. You can imagine all those nice things that came to my mind. In any case, the bank accepted my protest that I filed at their central offices and cancelled the transaction. I promptly cancelled my card, destroyed it right there for good measure, and got to thinking... what the fuck just happened?
As many people here, I am afflicted with a deadly virus, called curiosity. I started researching the matter, trying to figure out how. And, because I didn't like black boxes and "it is just like it is" explanations, I tumbled down the rabbit hole of ITSec. I soon found out that, not only it was possible, but also it was sometimes EXTREMELY easy to steal credit card info. There are sites, to this very day, that store user info (along with credit cards info) IN FUCKING CLEARTEXT. Sometimes your personal, financial and even medical info are just an SQLi away.
So, I got very disillusioned on many things. But I never regretted it. It may cause me to age prematurely and will kill me of stroke or heart attack one day, but as I still tumble down the ITSec rabbit hole, I can say with confidence that
I REGRET NOTHING
Plus, my 600$ were returned, so look on the bright side :)1 -
Playing way too many games when I was younger I realised I could do work with computers as a job if spent that time teaching myself.
Uninstalled Windows to stop temptation, hellooooo Linux6 -
Inappropriate experience at work: One of our project managers got arrested one day for fraud. Apparently an employee had been in the middle of an online purchase and walked away from their desk. He happened to see the unmasked entry of the CC info (this was before websites cared about masking sensitive form inputs). I guess the temptation was too great…and he was too stupid to realize he’d get caught…and he jotted it all down. He made thousands of dollars in purchases which, naturally, eventually led back to him.
The same guy, before he got arrested, had made a joke when someone in an office team email said “Feel free to have some cake in the break room.” He replied “No need to do anything to me for the cake.” His first name was “Free”.5 -
Lessons I've learnt so far on programming
-- Your best written code today can be your worst tomorrow (Focus more on optimisation than style).
-- Having zero knowledge of a language then watching video tutorials is like purchasing an arsenal before knowing what a gun is (Read the docs instead).
-- It's works on my machine! Yes, because you built on Lenovo G-force but never considered the testers running on Intel Pentium 0.001 (Always consider low end devices).
-- "Programming" is you telling a story and without adding "comments" you just wrote a whole novel having no punctuation marks (Always add comments, you will thank yourself later for it I promise).
-- In programming there is nothing like "done"! You only have "in progress" or "abandoned" (Deploy progressively).
-- If at this point you still don't know how to make an asynchronous call in your favourite language, then you are still a rookie! take that from me. (Asynchronous operation is a key feature in programming that every coder should know).
-- If it's more than two conditions use "Switch... case" else stick with "If... else" (Readability should never be under-rated).
-- Code editors can MAKE YOU and BREAK YOU. They have great impact on your coding style and delivery time (Choose editors wisely).
-- Always resist the temptation of writing the whole project from scratch unless needs be (Favor patching to re-creation).
-- Helper methods reduces code redundancy by a large chunk (Always have a class in your project with helper methods).
-- There is something called git (Always make backups).
-- If you don't feel the soothing joy that comes in fixing a bug then "programming" is a no-no (Coding is fun only when it works).
-- Get angry with the bugs not the testers they're only noble messengers (Bugs are your true enemy).
-- You would learn more than a lot reading the codes of others and I mean a lot! (Code review promotes optimisation and let's you know when you are writing macaroni).
-- If you can do it without a framework you have yourself a big fat plus (Frameworks make you entirely dependent).
-- Treat your code like your pet, stop taking care of it and it dies! (Codes are fragile and needs regular updates to stay relevant).
Programming is nothing but fun and I've learnt that a long time ago.6 -
Can "being lost in Hot Network Questions column of StackOverflow" be a valid reason of late delivery of code?1
-
That feeling where you give in to the temptation to answer a StackOverflow question and then wait to see how long it takes to get 20 downvotes.6
-
When you're in the middle of a big-ass project and have to stave off the temptation to jump into a "mini project" you've been fantasising about...2
-
Beautiful is better than ugly.
Explicit is better than implicit.
Simple is better than complex.
Complex is better than complicated.
Flat is better than nested.
Sparse is better than dense.
Readability counts.
Special cases aren't special enough to break the rules.
Although practicality beats purity.
Errors should never pass silently.
Unless explicitly silenced.
In the face of ambiguity, refuse the temptation to guess.
There should be one-- and preferably only one --obvious way to do it.
Although that way may not be obvious at first unless you're Dutch.
Now is better than never.
Although never is often better than *right* now.
If the implementation is hard to explain, it's a bad idea.
If the implementation is easy to explain, it may be a good idea.
Namespaces are one honking great idea -- let's do more of those!1 -
When there is a coinbaise folder on clients laptop, won't even look into it but temptation is there.7
-
I just interviewed the guy who is interested in my Linux SysAdmin position. He's really cool and I think he'll get the job, but he is a Windows admin actually. (No problem, since he'll work with me for three month's as a mentoring program and it's supposed for him to learn the stuff)
My question to all other Linux Witchers and Witches out there, do you know a mighty spell to seal his windows daemon away, such that he's able to resist the sore temptation by my co-workers (windows enthusiasts)?rant magic seal windows daemon linux syswizards linux wizardry linux wizards witches linux sysadmin witchers2 -
My biggest influence on coding style is working with other people's code. I know the temptation to write "clever" code and I've been (and probably still occasionally am) guilty of it myself, but it's not until you have to debug someones oneliner iterator which has !(i-j) as the stop condition that you start to appreciate dumb, boring, obvious code.
If having a series of if checks in a long list makes it readable, keep it that way. If it makes it more readable to rewrite it into a nested switchcase with a couple of ternary bits, go ahead. Just don't spend half a day wrapping it up into two layers of abstraction that will require an onboarding process for the rest of the team.2 -
What are your plans for Christmas?!?!!??
I normally won't engage in societal tropes like pointless, generic, smalltalk or those questions people ask for lack of independent thought/societal trope-isms....
Here's my templated answer this year:
Background = ~2k$ in piles of tech... server upgrades components, apparently the only managed switch left in business/non-custom enterprise networking in the country/indexed for sale
(2k in what I would pay.... my tech sourcing is more base level and +4 years pro exp(yea... since age 8... really))
Foreground.... a shiny ✨️ new, wonderfully discounted for dumb reasons that i appreciate... 10Tb LFF HDD! 🥹🥲🤩
I really like raw data... enough raw data and proper context relevant high-level, custom, precise algorithms and i genuinely believe literally any questions or problems can be quantified and solved for
So... I just keep getting data, life, sourcing, stats on human behaviour... i factor everything
Yes i realise im very odd
//initial context plus curiousities
As parsed out to somewhat tangential commentary below... i cant keep making people go away for societally viewed polite engagement. Therefore, when asked again by factory sales rep who enjoys verbosity and apparent finds me extremely worth his intrigue/personal time
// additional context (and my attempt to be more parse and comment conscious)
With a bunch of initial reveals and launches startjng in a week and technically being the "owner/boss"(cringy to me so Ive officially made my title (anywhere with custom input fields) DragonOverlord...dragons being a tied in theme to all sects and no one can say DragonOverlord isn't a position... as it's clearly a class... unless you find a human more style code ignorant, comment inept, and in need of a very multilingual scribe to create a lexicon 2 steps before my code would be even follow-able without a likely, bad, headache and davinci code like adventure including the improbably well placed wise scholars that just happen to have significant unique and vital information they are willing to freely share with strangers.rant christmas data architecture motivational societal tropes temptation so i can build my database structure loathing python raw data data misanthropy databases49 -
Feeling a strong temptation to go in and just do some random refactoring on my work project. It has massive view controllers and 30% test coverage. I dunno about anyone else but in my book thats not good enough to release to paying customers.
-
Some time ago, when exactly the fuck I don't quite remember and promise I never will unless just the right amount of ass is provided in a timely fashion, I start going about how I want to work on some utils to make writing prompts easier.
What I do remember and will remind you with strongly renewed vigor is the fact that I signed a legally-binding document to grant the general public a full pardon for my own ritualistic assassination should I ever use the term "prompt-engineering" unironically.
This pact still holds, and were I to break my solemn oath, then I will hold you fully accountable every single second I find myself still breathing.
Anyhoo, today was the first test of my resolve, for I have implemented both the stupid preprocessor and the local database prototype that allows it to fetch long ass definitions from disk, and both have been published (main: https://github.com/Liebranca/...).
I must admit to you all that though I have not failed, I felt weakness for a second when filling out tags in the repo description, as only "prompt-engineering" was recognized as a legit tag, and not "prompt-writing". In that moment, I almost gave in to temptation, as the accursed Satan whispered in my ear, appealing to my desire for recognition.
However, I reminded this ill buttrape daemon that their fate lies in the burning fires of hell, and as a result was allowed to resist it's alluring diabolical seduction. And for not giving in to greed, I have kept my life, my honor, and my anal virginity.
Also I wrote *some* documentation, it's shit but it's something.12 -
Every day is tempting to me..tempting to use some solutions i am not sure that i can handle it.
The Company i work for has an external IT Partner that does all the heavy lifting when it comes to our infrastructure, like installing servers, doing the installations and such. I mostly monitor it and do basic maintenance. Its all windows.
Recently i thought about adding a fifth Hyper V instance for an intranet webserver...based on some linux distro (probably ubuntu cause that is what i am familiar with). But i am not THAT familiar with ubuntu or any linux distro..buts its just the intranet and i already installed nginx and apache with success, what could go wrong?
today i sketched some intranet websoftware our production might find useful to collect data input from our workers (we are somewhat small so there is no big ERP software as of now). When thinking how to realize the data input i thought that maybe a basic raspberry and some cheap 1280x800 10.1 inch touch panels would be best..its very tempting, but on the other hand i am not sure i am ready for that, my experience is shallow and only based on my own RaPi that i 99,99% run headless. On the other hand it would be a very small and space safing concept..and cheap..compared to the use of Laptops (the go to company solution when computers are needed).
It also had the risk that i am the only one that could unfuck anything if things go south..it also has the advantage that i am the only one who could fix things when it goes south...
so much temptation -
To work from home, I recently bought an internet connection at home. It has pretty good speed and is affordable for the base plan. The speed is around ~ 35 Mbps. Never had that fast internet in my life.
Now I have this sudden urge to buy a console and start gaming. That would require me to also buy a TV screen. So I'm now dealing with a temptation that would cost me atleast $500 in total.
This corona better stop soon...3 -
you know they call me 'good' which in their speech is an insult. do they ever pay fucking attention or can they not conceive of what a real human is like ? especially one that is conflicted on various levels as a result of abuses, loneliness, depression, survival interests, years of bullshit, etc ? I'm not immune to temptation or corruption, I'm just extremely resistant.
-
So.
Trash
Surrounded by it
Am not it
And it accumulates
Why is telling the truth ignored ?
Why should my life be reduced to mindless repetition while they add further temptation to simply throw said trash in the dumpster ?
Nothing seems to be enough for them
One slight after another
Wtf is wrong with them ?
Blank souless husks
That's what they are and what being around them leads to people being
But hey they're "powerful' when shredding themselves in the garbage disposal and limiting the time experiences remembered or proven to have existed
Or against things exactly 3 feet in heigt
Killing them would be a mercy
Their hollow brainless minds will learn eventually2