Do all the things like ++ or -- rants, post your own rants, comment on others' rants and build your customized dev avatarSign Up
Get a devDuck
Rubber duck debugging has never been so cute! Get your favorite coding language devDuckBuy Now
Search - "light mode"
So I'm working on a computer vision project that grabs video from my webcam and detects faces in each frame. Earlier yesterday morning I was capping out at 30 frames per second, which is what I believe to be the max for my webcam. As the day became night and I was wrapping up my work on a portion of the project, I noticed that my newly compiled version was only getting around 8 frames per second. Confused, I looked into my frame grabbing + face detection code.
"Maybe I can only detect faces in a certain region of the image, based on where the face was in the previous image?" No, still 8fps. Hmm.
"How about I lower the resolution of the image, that would definitely help!" I tried that, but no speed boost came either. What??
I start to dig deeper. Maybe I'm not linking my libraries correctly, and it's using an older library I compiled. So I recompile that. Nothing.
"Am I low on resources?" I close out of all my other apps. Nothing.
Okay, wtf. Now I just comment out the face detection code entirely, and only grab webcam frames.
Suddenly, I get an idea. I get out of my desk, walk over to the doorway of my room, and flip the light on. I sit back down, and run my code.
The stupid webcam switches to "night mode" when it detects low light, which restricts its ability to output frames at high speed and caps at 8fps. Damn, I felt like a fool 😂5
Look I understand online privacy is a concern and we should really be very much aware about what data we are giving to whom. But when does it turn from being aware to just being paranoid and a maniac about it.? I mean okay, I know facebook has access to your data including your whatsapp chat (presumably), google listens to your conversations and snoops on your mail and shit, amazon advertises that you must have their spy system (read alexa) install in your homes and numerous other cases. But in the end it really boils down to "everyone wants your data but who do you trust your data with?"
For me, facebook and the so-called social media sites are a strict no-no but I use whatsapp as my primary chating application. I like to use google for my searches because yaa it gives me more accurate search results as compared to ddg because it has my search history. I use gmail as my primary as well as work email because it is convinient and an adv here and there doesnt bother me. Their spam filters, the easy accessibility options, the storage they offer everything is much more convinient for me. I use linux for my work related stuff (obviously) but I play my games on windows. Alexa and such type of products are again a big no-no for me but I regularly shop from amazon and unless I am searching for some weird ass shit (which if you want to, do it in some incognito mode) I am fine with coming across some advs about things I searched for. Sometimes it reminds me of things I need to buy which I might have put off and later on forgot. I have an amazon prime account because prime video has some good shows in there. My primary web browser is chrome because I simply love its developer tools and I now have gotten used to it. So unless chrome is very much hogging on my ram, in which case I switch over to firefox for some of my tabs, I am okay with using chrome. I have a motorola phone with stock android which means all google apps pre-installed. I use hangouts, google keep, google map(cannot live without it now), heck even google photos, but I also deny certain accesses to apps which I find fishy like if you are a game, you should not have access to my gps. I live in India where we have aadhar cards(like the social securtiy number in the USA) where the government has our fingerprints and all our data because every damn thing now needs to be linked with your aadhar otherwise your service will be terminated. Like your mobile number, your investment policies, your income tax, heck even your marraige certificates need to be linked with your aadhar card. Here, I dont have any option but to give in because somehow "its in the interest of the nation". Not surprisingly, this thing recently came to light where you can get your hands on anyone's aadhar details including their fingerprints for just ₹50($1). Fuck that shit.
There are and should be always exceptions when it comes to privacy because when you give the other person your data, it sometimes makes your life much easier. On the other hand, people/services asking for your data with the sole purpose of infilterating into your private life and not providing any usefulness should just be boycotted. It all boils down to till what extent you wish to share your data(ranging from literally installing a spying device in your house to them knowing that I want to understand how spring security works) and how much do you trust the service with your data. Example being, I just shared most of my private data in this rant with a group of unknown people and I am okay with it, because I know I can trust dev rant with my posts(unlike facebook).29
I've been on dark devrant since it was released and today I was wondering what the light mode looked like again..
*switches to light*
After my eyes burned away I remembered why I use dark mode in the first place and switched back 😂10
Apple you drove of delusional suckers! When will your retarded fashion devices finally support WEBP?!
A gallery page with images, and thanks to WEBP, it's 408 kB. Because Google made WEBP and handed out a well documented CLI FOSS compression tool that even can convert the source PNGs to lossy WEBP with bloody transparency. Well done, Google!
Except that Apple's shitty management can't take it that Google actually made something nice, so no WEBP. Instead, JPEG-2000 that enjoys nearly no fucking tool support. The free tools that even can deal with that mostly don't support transparency, and the encoder sucks donkeys so that JPEG still fucks JPEG-2000 big time.
So it's JPEG with matching background for iOS. Fine, but since JPEG's blocky artifacts are much more visible, the compression can't be that high, and it's 769 kB. That's 88% more image data for Shittari than for non-retarded browsers and even Edge! EDGE!!
Oh and if the user changes light/dark system mode according to surrounding light conditions, guess what happens? Yep, since JPEG doesn't support transparency, now it's different JPEGs with dark background via the media query in the "picture" element, and it's another 754 kB download. Bloody 1523 kB instead of 408 kB, that's a factor of 3.7!
Fuck your ass Crapple, with an electric eel!19
So probably about a decade ago at this point I was working for free for a friend's start-up hosting company. He had rented out a high-end server in some data center and sold out virtualized chunks to clients.
This is back when you had only a few options for running virtual servers, but the market was taking off like a bat out of hell. In our case, we used User-Mode Linux (UML).
UML is essentially a kernel hack that lets you run the kernel in user space. That alone helps keep things separate or jailed. I'm pretty sure some of you can shed more light on it, but that's as I understood it at the time and I wasn't too shabby at hacking the kernel when we'd have driver issues.
Anyway, one of the ways my friend would on-board someone was to generate a new disk image file, mount it, and then chroot to that mount path. He'd basically use a stock image to do this and then wipe it out before putting it live.
I'm not sure exactly what he was doing at the time, but I got a panicked message on New Years Day saying that he had deleted everything. By everything, he had done an rm -fr /home as root on what he had thought was the root of a drive image.
It wasn't an image. It was the host server.
In the stoke of a single command, all user data was lost. We were pretty much screwed, but I have a knack for not giving up - so I spent a ton of time investigating linux file recovery.
Fun fact about UML - since the kernel runs in user space as a regular ol' process, anything it opens is attached to that process. I had noticed that while the files were "gone", I could still see disk usage. I ended up finding the images attached to their file pointers associated with each running kernel - and thankfully all customers were running at the time.
The next part was crazy, and I still think is crazy. I don't remember the command, but I had to essentially copy the image from the referenced path into a new image file, then shutdown the kernel and power it back on from the new image. We had configs all set aside, so that was easy. When it finally worked I was floored.
Rinse and repeat, I managed to drag every last missing bit out of /proc - with the only side effect being that all MySQL databases needed to be cleaned up.3
!rant && Announcement
The closed beta for the new DEVRANT TOOLBOX is starting for chrome users.
The Toolbox is an UNOFFICIAL web extension for Chrome and Firefox.
- Compact mode: reduced image height in the feeds
- Extended page navigation controls for feeds
- Timestamps for rants
- Image preview on mouseover
- Autoreload for the recent feed (180 sec)
- Highlighting new rants after a reload (recent feed only, see screenshot)
- Highlighting own rants (inside feeds) and comments (inside rants)
- Hiding personal scores (still visible by mouseover) and share buttons inside rants
- Colored notifs (different colors for the notif types)
- Notifs with clickable usernames: a click will open the rant AND the username (in a different tab)
- 3 additional Themes: Black, Monochrome, Dark blue
(Next themes to come: solarized light and dark)
- Global history.back on rightclick (for faster navigation)
- Increased feed width (see screenshot)
- Plain background (just the feed on screen)
- Weekly rant
All features can be switched on/off.
The weekly rant is a temporary feature. It uses the devrant api.
I will remove it when that feature is added to the original devrant webfeed.
@dfox: If you dont like the use of the api or some of the features please contact me.
Chrome users can join this group to get the beta:
I NEED SOME FEEDBACK!!!
Therefore a feedback is my term of use.
Please post it as a comment (or in the google group).7
So I have seen this quite a few times now and posted the text below already, but I'd like to shed some light on this:
If you hit up your dev tools and check the network tab, you might see some repeated API calls. Those calls include a GET parameter named "token". The request looks something like this: "https://domain.tld/api/somecall/..."
You can think of this token as a temporary password, or a key that holds information about your user and other information in the backend. If one would steal a token that belongs to another user, you would have control over his account. Now many complained that this key is visible in the URL and not "encrypted". I'll try to explain why this is, well "wrong" or doesn't impose a bigger security risk than normal:
There is no such thing as an "unencrypted query", well besides really transmitting encrypted data. This fields are being protected by the transport layer (HTTPS) or not (HTTP) and while it might not be common to transmit these fields in a GET query parameter, it's standard to send those tokens as cookies, which are as exposed as query parameters. Hit up some random site. The chance that you'll see a PHP session id being transmitted as a cookie is high. Cookies are as exposed as any HTTP GET or POST Form data and can be viewed as easily. Look for a "details" or "http header" section in your dev tools.
Stolen tokens can be used to "log in" into the website, although it might be made harder by only allowing one IP per token or similar. However the use of such a that token is absolut standard and nothing special devRant does. Every site that offers you a "keep me logged in" or "remember me" option uses something like this, one way or the other. Because a token could have been stolen you sometimes need to additionally enter your current password when doings something security risky, like changing your password. In that case your password is being used as a second factor. The idea is, that an attacker could have stolen your token, but still doesn't know your password. It's not enough to grab a token, you need that second (or maybe thrid) factor. As an example - that's how githubs "sudo" mode works. You have got your token, that grants you more permissions than a non-logged in user has, but to do the critical stuff you need an additional token that's only valid for that session, because asking for your password before every action would be inconvenient when setting up a repo
I hope this helps understanding a bit more of this topic :)
Keep safe and keep asking questions if you fell that your data is in danger
Decided to delete devRant and reddit for a few months. Now I'm back, and the first thing that greets me on both is Light Mode 🤢
Thank God that I haven't cancelled my devRant subscription. Once you go black you never go back! 😏5
Just got the darkest mode on devRant and it’s fucking amazing.
The medium darkness looked so gross that I used the whitess mode until I felt like I was blinded by the light and got the darkest theme instead.
My eyes thank me, my bank account doesn’t.😂6
I think I might change my middle name to "I told you so"
Couple of weeks ago I proposed integrating a daily process job into an existing WPF application (details of what+why would be too long to explain) and the manager suggested I make the changes
Me: "I can do it, but Jay has the most experience with that application. I don't have his WPF skills"
Mgr: "How hard can WPF be? If it uses the MVVM pattern, it should be a snap."
Me: "Its nearly an 8 year old WPF project with several chefs in that kitchen. I pretty sure I could figure it out, but that is a difference between 2 weeks and 2 days. Integration is pretty straight forward, Jay could probably do it in a day."
DevA: "WPF is easy. MVVM makes it even easier. I worked on the shipping app."
Me: "That's was a brand new, single page app, but yea, it should be easy."
DevB: "WPF has been around a long time and the tools have really matured. I don't understand what is so difficult."
Me: "I didn't say anything would be difficult, I know with that application, there is going to be complexity we need to figure out."
DevB: "It uses the MVVM, so all we need is the user control, a view model, controller, and its done."
DevA: "Sounds easy to me."
Mgr: "If you need more time to work on the vendor project, I'll have DevB work on the integration."
Me: "How is the integration going?"
DevB: "This app is a mess. I have no idea how they got the control collections to work. If I hard-code everything, I can get it to work. This dynamic stuff is so confusing. Then there is the styling. Its uses dark mode, but no matter what I do, my controls show up in light mode."
Me: "The app uses Prism, so the control configuration is in, or around, the startup code."
DevB: "That makes sense. Will it fix the styling too?"
Me: "I have no idea. When I looked at it, some controls loaded the styles from the main resource, other's have it hard-coded. Different chefs in the kitchen, I guess. How far have you got?"
DevB: "I've created invoice button. That is as far as I got"
Me: "I'm finished with the vendor project and I'll be wrapping up the documentation today. I can try to help next week."
DevB: "Thanks. I think we might have to get Jay to help if we can't figure this out."
Me: "Good idea"
Two weeks and only a button. A button? I miss Delphi.3
I think that Google has alien employee's.
NOW Why Do I Say that???
Because all the stock Android versions do not have a "DARK MODE".
If they were human developer's they would have included it.
Same statement is Worthy to all their apps.
Light is killing me !!!2
Whelp. I started making a very simple website with a single-page design, which I intended to use for managing my own personal knowledge on a particular subject matter, with some basic categorization features and a simple rich text editor for entering data. Partly as an exercise in web development, and partly due to not being happy with existing options out there. All was going well...
On my TODO-list: Comment and/or upvote system, spoiler tag, GDPR compliance (if I ever launch it haha), data-limits, a simple user action log for admins/moderators, overall improved security measures, refactor various controllers, clean up the code...
It STILL uses a single-page design, and the amount of feature requests (and bugs) added to my Trello board increases exponentially with every passing week. No other living person has seen the website yet, and at the pace I'm going, humanity will have gone through at least one major extinction event before I consider it "done" enough to show anyone.
I dual boot windows and Linux. I use Windows primarily for light gaming on the weekends.
Somehow, the windows updates have successfully managed to break my grub menu, and my Linux partition is booting into Grub Rescue mode.
Right now tolerating the windows updates, which have been painfully going on for the past 2 hours now. Later, I'll have to deal with fixing my Linux partition boot.5
I used to prefer light mode, but switched to dark one day just for the heck of it and now light burns my eyes and makes me cringe7
Sometimes I ask myself why dark theme isn’t the default setting on apps. I mean, light theme WRECKS YOUR EYES!!! How can the common way of designing is to make light theme default or JUST NOT HAVE A DARK THEME!!!!! It’s so unnatural!!!! Anyway...8
The Play Store just added even more white to it's design with the latest update.
Once again Google is going the wrong way with their design choices....
Can we please just have a dark mode.1
With all of them going gaga about Dark Mode everywhere, is there anyone else at all who thinks light mode is so much more easy on the eyes during the day alone at least?36
So for the past few days I decided to create my own personal blog because I wanted to start blogging again. Anyways, I setup a basic WP website (sorry wp haters xD) and installed a pretty cool free theme that I tweaked all over the place.
I was thinking of cool things to add while I'm just in that setting up phase and I really admired that whole dark/light mode toggling feature :) so I spent the past day or so creating my own and it works finally, even across different pages! So i thought I'd share. (Please excuse the BS posts, its strictly for testing. Havent actually started writing posts yet xD)
Heres also a link to this terrible js file I wrote that controls the logic lol (I'll have to refactor quite a bit but it works)
Any feedback is appreciated as I'm still just developing it :)14
I think dark mode is the best thing ever invented and glad devRant has it, otherwise I would have been blinded by my bright white screen.
*Awkwardly starts playing Blinded by the Light song*8
It was on this day, we give thanks to our lord and saviour Apple, for enabling dark themes for all!!!5
-Had low battery so I put the phone on power saver mode (decreases brightness) and manually lowered it to minimum as well
-Couldn't see shit
-Thought something is wrong with my phone
-Reset it completely
-Now the screen is fine
-The light blinked in my brain and I realized I'm an idiot
WHAT ANDROID PENDEJA MADE THIS EVEN POSSIBLE TO BE DONE YOU SON OF A BITCH1
Dark mode on MacOS Mojave is a great addition, but why is it that we have dynamic wallpaper based on time of day and yet there isn't a way to switch between light and dark mode the same way?4
Here, a full retrospective of my Apple products ownership.
iPhone SE – after Android, I was absolutely amazed by how fast it worked. No UI lags, camera works absolutely instantly no matter the light conditions, all the GPU-heavy games work butter smooth.
After camera and charging port failures on Xperia flagship and CPU literally melting through screen rendering it unusable on Meizu, it was enough to make me interested in Apple products.
When I was using Meizu, I actually got a twitching eye which was triggered by UI lags. After two months of using iPhone, I noticed that something was missing – my eye wasn't twitching anymore.
iPhone actually cured me.
MacBook 12 – a 900 grams laptop with passive-cooled mobile CPU running many Chrome tabs, heavy Webpack HMR build, VSCode and Slack just fine. Yes, you can't play games, but I don't even require it from a laptop this tiny.
Butterfly keyboard that internet hates so much actually increased my typing speed and comfort compared to MX Red mechanical keyboard, and ForceTouch trackpad made me forget about mouse. I learned how to disassemble the Butterfly keyboard if I ever need this but the keyboard never failed.
I use this laptop to this day and it still even smells like the day one, a beautiful smell of a new Apple product.
iPhone X – got it because of the camera, stayed for great battery life and amazing OLED display. I use telephoto lens exclusively and it made me lay off my Canon DSLR with Helios lens which stays on my bookshelf covered in dust to this day.
True black of OLED display which is undistinguishable from the screen bezel is stunning. To this day, battery surely works for one and a half days and I watch youtube really often.
I sometimes struggled to unlock iPhone SE with wet fingers, but with FaceID, as soon as I look at the screen the phone is unlocked. Works perfect every time, never had an issue with this.
Stainless steel body feels premium compared to aluminum. Stereo sound is a major selling point if you're like watching videos and playing games on your phone. Overall amazing product and a huge improvement over SE.
Apple Watch series 4 – really comfortable fit. Nice battery life, once I forgot about it for like ten days during lockdown and it was still working, even though on power reserve mode. Really reliable in terms of battery life and liquid protection. Very satisfying Taptic Engine crown clicks. I run every day and Apple watch always measure my heart rate correctly, and the running app is well designed and a pleasure to use. Overall a nice accessory to have if you use iPhone.
Powerbeats Pro – great sound and battery life. I switched from Shure SE215 which was great, but it had wires. I listen to a lot of music so the sound quality is important for me. When I was choosing earphones I visited a store where you can listen to them all. I listened through earphones like Noble Audio Kaiser Encore and JH Audio Layla, and of course $4000 Laylas sound better than $249 bluetooth earphones, but the difference in sound doesn't justify the difference in price to me.
Powerbeats pro is the Apple H1 chip true wireless earphones with largest driver of them all which makes them sound better than AirPods Pro – it's just physics. Bass in Powerbeats is amazing, which is also true for my Shures, but Powerbeats also win in clarity.
It connects seamlessly to both my MacBook and my iPhone, and everyone in voice chats can hear me really good.
Huge case is a major throwback compared to AirPods, but the battery life of earphones themselves is so great that I just leave the case at home and only carry earphones and it works for me.
Apple Link bracelet in space black – really better than I expected. Intricate detailing, literally the steel that Rolex uses, top-notch finishing and polishing – all that for just 450 dollars. I only used it for several days now, but it already feels like a really satisfying product.
Before all that I was using Linux. It took a year for elementaryos devs to fix wifi for my laptop. Ubuntu looks and feels ugly. Pop OS felt like garbage. Manjaro was also just that – garbage. KDE Plasma – I don't even want to talk about that. A monstrocity where you accidentally click a wrong switch in the settings and your system won't boot up again. Also, PulseAudio. Struggles with proprietary drivers and software updates.
Windows? I serviced a lot of Windows PCs through my career and it never, never worked as intended. I'm no dumbass, I always managed the rights correctly and never installed sketchy apps. My latest ryzen gaming build with a lot of ram also lags somehow even in Windows 10 UI.
Before I switched, I defended Linux.
My life was a lie.
I'm sorry to everyone who I offended based on their opinion on Linux.44
Light theme + inverted colors = devRant supporter dark theme. Also, when you browse through Android in this mode, you can get some design inspiration.8
Hi people first as you know my English is not very poor im sorry for that.
I try to make an automat a sprinkle water and a auto light on a interior garden in aquarium.
For that in python i use main thread, a class Water.py extends Threading and Light.py extends Threading
In the __init__.py file i put my main function that get argv for execution. One of my arguments is -v (--verbose)
I want to pass that args to my class instances.
-I don't want to make one parameter in my constructors because I think we don't passe verbose mode in parameter of constructor.
-I use global not working through de import.
Do you have some magic for me :/ ?6
Every time I use an application that has both light and dark mode, I always use dark, and when I decide "Hey, I want to try light again" I immediately regret ever clicking the option.4
How Microsoft expect anyone to develop using any technology they introduce with so many limitations.
Moi a Microsoft dumb enthusiast said to myself : hey dude you are a developer stop whining about the app gap bust a move create decent array of apps and release them, went into a full project management mode wrote requirements did sketches and some prototypes, time to execute.
1. first app: image files organizer, viewer , with some light editor capabilities and album creator after some work i came to discover that you don't have a proper file system APIs to show a folder tree view in my app "WTF" there are work arounds and dirty solutions but seriously? i can only access the stupid media folders created by Microsoft and that's it.
so i ditched the apps until uwp become a development tools with target audience other than kids who eat crayons, and while using "Edge" i thought to my self : "you know what dude extensions are cool and if you do something like a speed dial it would be awesome"
fire up my text editor started writing my extension to discover that:
"you cannot use localStorage from local HTML files".
moral of the story
MS is failing with consumers not because people hate MS but rather MS hates itself like no engineer over there said to him self this is fking stupid ?
other limitations :
no proper system tray access
no registry access what so ever
and i have started 2 days ago.
yeah Ms this is the main app gap problem the uwp sucks big time. compared to android Java which has a great access to every aspect of the device even apple provide better APIs for their systems.
if uwp is MS future then rip MS.
please i stand corrected if anyone knows better.2
Dynamic wallpaper seems to only work in light mode for the OS. The dark mode version just shows the night picture the whole time... #fail #imcryingrightnow #ios6
Macbook - How do you get "True Tone" soooo wrong. If I wanted to automatically switch from light mode to dark mode every 20 seconds I'd ... I'd ... I'm not sure what I'd do, but seriously, that fucking shit has to stop.
What the fuck is different in vscode's light mode?
I use light mode everywhere. Much to the annoyance of everyone around me. But I cannot use the integrated light mode from vscode. Neither its own theme nor the solarised version.
This is a legitimate question for people who understand what make colours work as they do, because I definitely don't understand colours: Why is this one actually painful to my eyes? What is special about this light mode?8
A memorable bus journey to Calicut from Bangalore
Calicut is popularly known as Kozhikode. It is renowned for its beached and people frequently visit this place from Bangalore. The beautiful city of Calicut happens to be the capital of Malabar for almost 500 years in the ancient times. For centuries together the city has been engaged in trading of cotton and spices with the Jews, Arabs and the Chinese. It was in the year 1498 at Vascodagama had set his foot on a remote beach of Calicut and declared that he had discovered India. It is at this time that he established several trade routes in the West. Even today, Calicut happens to be the centre of the flourishing and domestic international trade. It has helped the country become one of the pioneers in trade commerce and economic development. Today Calicut is the marketing centre for pepper, rubber, coconut, coffee and lemon grass oil which are produced in the neighbouring district of Wayanad. Located in quite proximity to the Arabian sea and hills on the other side it boasts of some of the most serene views. Some of the top places you can visit when in Calicut include the light house the back waters, Beypore and the Lions Park. The Park is located just next to the light house on the Beach.
Bangalore, regarded as a one of the highly developed and speedily growing cities in India. Folks staying in Bangalore usually working in colossal businesses search a at ease mode of experience. The city has good-networked roadways, railways and airways fulfil sudden journey requisites of people. Commuters looking for a quick escape from Bangalore to Calicut usually choose to take up a bus journey. As the fact is justified, that buses are affordable and easy to access at any time of the day.
Individuals keep traversing from Bangalore to Calicut and vice-versa, as both the cities serve the IT sector mostly. Buses create an enormous convenience for a lot of, as there is no early planning of your journey is required. I took my tickets for bus from https://redbus.in/bus-tickets/... and this online platform helped me to book tickets in a short span of time. The AC sleeper bus was super comfortable and they gave rest stops too. The 9 hours of travelling was tiring but an interesting one. The bus passed through many scenic places and I enjoyed experiencing all of these. I boarded the bus from Kalasipalyam in Bangalore at 3:30pm and reached Calicut at 11:30pm. The bus came with clean interiors and ensured that all the passengers were travelling in ease. This bus staff was polite and completely ensured that I undergo a pleasant travel experience from Bangalore to Calicut.
I was eagerly waiting to explore the sea town that has an active port with flourishing trade and commercial centre. The best places to visit were on my list like the Kappad Beachand Beypore Fort. I have visited the Kadalundi Bird Sanctuary, which was an awesome experience as I am a bird lover.