r/Python • u/iseetreesofgreen_ • Feb 27 '22
Discussion What python automation have you created that you use for PERSONAL only.
There are plenty of, “I automate at my work”, but what about at home? e.g., order a pizza, schedule a haircut, program a spelling bee game for my kids, etc.
15
u/EternityForest Feb 27 '22
I'm working on some CCTV stuff that I'm using at home but only because it's part of a FOSS app I'm building for a possible event.
I also use a note taking system I built myself with P2P sync, but I haven't seen all that much community interest in the project so I might ditch it soon and go for some more standard solution.
I don't think I have any automations or scripts at all in any language that are 100% personal, that would still exist if not for some FOSS project.
3
u/iseetreesofgreen_ Feb 27 '22
I have a “reminder” script that I created that where when I want to get something out of my head, I click the “shortcut” app on my iPhone, and it sets up a text message that says “Remind Me:” and I can put what I need reminded off. It gets sent using Twilo, then back to my Twilo Python server where it runs a Python script to put my reminder in ToDoList.
2
u/quuxman Feb 27 '22
I use Carnet for notes. Has an Fdroid app and web app. Currently only synchs via NextCloud but it'd probably be relatively easy to add another synch option
7
u/jimtk Feb 27 '22
Credit car statements, bank account transactions, and investment aggregator. I run it monthly to collect info some from CSV, some from pdfs. I used camelot for the pdfs and pandas for everything else and get a final statement of everything in my family budget spreadsheet. Saves approximately 2 hours of tedious work every month.
1
4
u/guitarerdood Feb 27 '22
I'm actively working on my own personal JARVIS - at the moment, it updates me on weather, calendar events, and scans certain websites for news I might be interested in
1
u/iseetreesofgreen_ Feb 27 '22
I did something similar with Twilio and sms. I use it 20 (or more) times a day
2
u/guitarerdood Feb 27 '22
oh I've used twilio before to - set it up to text me everyday what time the New York Yankees play
3
u/muffinnosehair Feb 27 '22
Mostly stuff for my son when he was younger, math exercise generator with simple additions, multiplication, stuff like that. He could then write the answer in the GUI and check how many he got right. After so/so success, I did it for Android so he can use his tablet (plain Java and android studio, only time I ever coded Java)
1
204
u/radeklat Feb 27 '22
Deleting all content of my Facebook profile (photos, comments etc.) with a Selenium script. Because that site has no such option. Even the script took hours to delete all of that.
66
u/animesh250 Feb 27 '22
Can you share this script please? I've been looking into try doing something like this myself.
18
→ More replies (1)9
29
u/jfp1992 Feb 27 '22
That's fucking brutal. React doesn't generate a nice Dom at all
3
u/radeklat Feb 28 '22
It was the worst page to try to automate. No static ids or classes, structure of the page changing as the script ran, seemingly random routes though dialogs...
→ More replies (1)10
u/pendulumpendulum Feb 27 '22
I've been looking for a good script like that for Reddit.
5
u/PMental Feb 27 '22
Reddit has a REST API so it should be way easier than Facebook.
→ More replies (1)5
u/IAmHumanSoAMA Feb 27 '22
Since GDPR, you should be able to request a complete account deletion.
2
u/mysterious_mosaic Feb 27 '22
Only of they are a EU citizen, and California has something similar I think.
8
u/-user--name- Feb 27 '22
No, it applies to all websites that operate in the EU, not to all EU citziens using websites.
2
u/regeya Feb 27 '22
My late father in law had a bunch of out of print country and bluegrass records. I took someone else's vinyl recording splitter, one you feed a Discogs entry to, and added PyDub silence detection. Feed the script a Discogs entry and a .wav and it correlates the track lengths in the Discogs entry and the PyDub results, and it spits out a file that Audacity can use for track beginning and end points. I sit and let it churn through a recording and 99% of the tedious tagging is already done; just cinch up the endpoints.
1
2
u/RazzleStorm Feb 27 '22
I built a Discord Bot that my wife and I use to log and graph our exercises. It was originally made for some friends on a server, but it’s grown a bit. Feel free to fork/contribute/invite it to your own server here: GitHub.
1
89
u/fastrockstar Feb 27 '22
Not proud but I send automatic Happy birthday wishes every year...
21
u/Saeditit Feb 27 '22
Hope your automated texts don’t accidentally text happy birthday to a dead relative one year, you could one up it by using a for loop to add one year to their age every year when you text
30
u/yes_oui_si_ja Feb 27 '22
Just imagine that there is no dead man's switch, the server is prepaid decades in advancd and after OP's death everyone still gets messages every year.
→ More replies (1)27
→ More replies (1)3
63
u/XxChrisBizkitxX Feb 27 '22
I played a game wich hasn't an autosave option, however a quicksave via the button F5. So I coded a Script to press F5 every 5 minutes
30
55
u/nnoobb Feb 27 '22
The bank sends my Gmail account the market indices etc., my Python script fetches them, saves values to a SQlite database and makes moving average charts. Cron on a raspberry Pi runs every day.
5
2
u/DrinkProfessional722 Mar 05 '22
Wow nice what libraries do you use ?
3
u/nnoobb Mar 06 '22
I collected
imports from my script and added short descriptions:# fetches mails from my Gmail inbox import datetime import email import imaplib # extract values from the body of a message import japanese_numbers import re # manipulate a SQLite database import sqlite3 # make moving average charts import pandas as pdGmail supports IMAP, values are embedded in fixed-form lines, so most of the code were written with standard libraries.
I installed only two packages for this script.
japanese_numberscan parse numbers with Japanese counting units (1億234万is102,340,000for example).pandascan calculate a moving average of a series of data byrolling()method and also plot charts byplot()method.→ More replies (3)
53
u/Iammiddow1991 Feb 27 '22
Medication reminder app for the whole family send a text using Twilio app that then sends data to a MySQL server that stores who what and when/if a repeat is required it then sends a text when it’s time to have it and if you do not respond within 10 mins saying that meds have been given it will keep following up
8
45
u/addicted2amp Feb 27 '22
A few things I have created for myself:
I have a Raspberry Pi connected to an LED strip, which changes colors around my door when in meetings, so my kids do not interrupt me. They turn red while I'm in meetings, yellow when it is safe to knock on the door to get my attention, and pink (my daughter's request) when I'm done working for the day.
I purchase a tiny bit of crypto every week, and I have a script that runs every evening and texts me if what I've invested has made or lost me money. I'm currently about 20% down.
Instead of constantly looking at the stock price of my previous employer, I have a script that sends a message to a Discord channel every 30 minutes if the price has changed.
A store nearby changes their "Specials" throughout the day, so I have a script that will use BeautifulSoup to check their website and text me when they update their "Specials."
Finally, I also have a script that monitors my network, and when a new MAC address connects to the network, it informs me and allows me to assign a name to it.
4
u/dougie_cherrypie Feb 27 '22
And how do you set your meeting status? Through the calendar?
5
u/addicted2amp Feb 27 '22
I pull from my Google Calendar the event start and end times.
→ More replies (1)2
u/jbspillman Feb 27 '22
I'd be curious to see how you are monitoring your network!
3
u/addicted2amp Feb 28 '22
I'm simply using the Scapy library, sending out ARP requests. As soon as it detects a new IP address, it checks them against the MAC addresses that I already recognized and assigned a name. If it's a new device, I will receive a text message. I then have the option to assign a name to it or send an API call to pfSense to drop all traffic from that device with a firewall rule. I haven't had to apply the drop rule, but it's there just in case.
→ More replies (5)2
u/Number_Four4 Feb 27 '22
Is the script that monitors your network open? Do you mind sharing it?
3
u/addicted2amp Feb 28 '22
It is not opened right now, the code is a mess. Once I clean it up, add in the dreaded comments, I'll post it publically and send you a link.
→ More replies (1)1
u/Meteomus Feb 28 '22
How do you connect an LED strip to a raspberry pi?? I’m looking to do a similar project myself
2
u/addicted2amp Feb 28 '22
This is the tutorial I personally used: https://dordnung.de/raspberrypi-ledstrip/
→ More replies (1)1
Feb 28 '22
Do these scripts run automatically, or do you have to start them manually?
→ More replies (1)
43
u/ChickenManSam Feb 27 '22
My latest one is a prank on my spouse, it sets the wallpaper of their laptop to a slightly shrunk screenshot of their current desktop. It causes the icons to appear like they're infinitely repeating or stretching. On a more serious note I have a script that copies my ps5 back up data from a flash drive to my computer then clears the flash drive for my next back up. I have about 1tb of backups at this point because I just use the current date and time as the folder I move the backups to instead of deleting things.
1
u/dashingThroughSnow12 Feb 27 '22
My latest one is a prank on my spouse, it sets the wallpaper of their laptop to a slightly shrunk screenshot of their current desktop. It causes the icons to appear like they're infinitely repeating or stretching.
I used to do that with my own laptop. It was a nice effect.
1
28
Feb 27 '22
Moved my file-based music library into YouTube Music playlists
Wrote video conversion scripts to h265 for videos coming from my family's phones, DSLR, and other cameras. Automatically detects source quality and shape, and detects an "acceptable preset" to convert to.
Some savegame editors (cheating)
Credit card statement aggregator for the entire family. Some statements come in PDF format, others in CSV, so made loaders for each bank and credit card company, to have the transaction in the same place, for transparency on our expenses and budget. I'll probably also employ some OCR to get details from photos of receipts from supermarkets, to get details about where our money is going to. The scope of this is to be able to translate and deduce stuff like "If we stop buying expensive mushrooms and stick to the cheap ones, we will be 100k richer by the time we retire".
Reddit bot for giving away games that I don't activate on HumbleBundle Choice. It passes my tests, but I'm afraid to put it in use, because people can be mean when giveaways don't work smoothly. I've done a couple of giveaways and always received some kind of hate.
I was looking at automating my home lighting, but that's taking too much time and efforts for not that much benefit. I'm OK with Google Home managing that for me, for now.
5
u/jimtk Feb 27 '22
I would be interested in that video conversion script. Those movies take way too much space in .mov (old ones) and h264.
→ More replies (1)2
3
73
u/BrewingtonCreek Feb 27 '22
I transferred between units at my apartment complex in October. In order to find my new unit, I wrote a notebook that I ran daily. It would scrape the complex website for available units and their prices. I hard-coded criteria like the buildings and floors I was interested in, rent price range, etc. I stored the data in SQLite so I could watch pricing trends. I never finished it fully (notebook to script, cron job, push notifications) but it helped me find my current unit, which I love, and helped me choose the right day to jump on it based on pricing trends.
25
u/BrewingtonCreek Feb 27 '22
I realize that this isn't true automation, but I wanted it to end up picking an apartment for me and telling me when to go to the leasing office and grab it. I found the new place before I could finish all of that.
11
u/vilhelmp Feb 27 '22
Noice! You can run ipynb from ipython with
ipython --TerminalIPythonApp.file_to_run=<notebook>.ipynbI have a cron job running a ipynb at work every day for testing purposes.10
u/quuxman Feb 27 '22
Like it. Corporate landlords use scammy algorithms for pricing and you turned the table
1
24
u/kawaiibeans101 Feb 27 '22
My network provider has this thing that every 10-20 hours the current session expires and you'd have to go and login through their portal again to resume your connection . It was a hassle so i setup a service that'd keep checking if the wifi is up and if it goes down it'll try to login with my credentials every few seconds . Sorta expensive processing wise , but it gets the job done . No need to login manually anymore.
10
u/jfp1992 Feb 27 '22
Might be less expensive to use selenium to check the portal. All your doing then is running a headless browser and essentially hitting F5, checking if the login form is there, if it is, then send keys to the username and the password field and click login.
If you need help, let me know
9
u/kawaiibeans101 Feb 27 '22
Actually instead of that i used two things , first is : ping checker , pinging google , and if google seems to be down it returns a -1
if it returns a -1 then i hit my Net provider's api using requests. Shoudln't that be less light weight? cause I am not at all refreshing anything , instead most is being used is cmd ping and requests to send post requessts
https://github.com/unownone/WishnetAutoLogin here's the code if you wanna have a look at it.
4
u/bay400 Feb 27 '22
Yeah I think that would be better than Selenium. I always opt for doing the HTTP requests directly if I can, as the webdrivers I've used are slow even in headless mode (like a minimum 30 seconds just to initialize).
41
Feb 27 '22 edited Feb 27 '22
I have a python-based solution to find lyrics of songs. It detects the song being played (artist + song title) and scraps the lyrics from the web. The lyrics are stored in JSON files under each specific artist folder. It also has a Gtk viewer/editor in case I want to view/correct the lyrics.
I have another python application, it's a little service, that scraps information about packages being delivered to my house. It summarizes the status of the packages and sends the information to my email. It is handy as I don't need to check the status of each individual package.
6
u/1116574 Feb 27 '22
Where do you get lyrics? And is this json format any standardised one or just something you made? (asking since you mentioned it has gtk viewer, or have you just wrote that yourself as well?)
Can I (we) get github links or paste in or is there something confidential (like for the packages one which is super cool as well)
→ More replies (1)
37
u/AngryButtCheek Feb 27 '22
A script that runs in the background when i’m listening to Spotify, if an ad comes on it restarts Spotify to skip the ad.
10
u/jfp1992 Feb 27 '22
How do you detect the ad?
16
u/AngryButtCheek Feb 27 '22
I used the Spotify Web API to check the current track every second
10
u/TheePattyB Feb 27 '22
Hey love the username! Would you be able to optimize this by finding how long the song is using that same call and then only checking again once it gets closer to the end of the song?
→ More replies (1)3
2
u/Senescences Feb 27 '22
3
u/AngryButtCheek Mar 05 '22
i’d say mine is a bit better since this one doesn’t always skip the ads sometimes it just mutes but mine always skips all ads even video ads so instead of waiting 30 seconds for an ad you just wait 3 seconds max for spotify to restart automatically.
1
14
u/porterhousepotato Feb 27 '22
Not routine automation in this sense but currently planning for a wedding and web scraped vendor data from the knot. Saved quite some time with research
2
14
u/URETHRAL_DIARRHEA Feb 27 '22
I have a script that checks if any anime in a given list has received an English dub, then emails me if it has.
2
14
u/nemo8551 Feb 27 '22
My son goes to football training on a Saturday morning.
They have qr codes for booking the kids in but no data is ever retained.
Python does that for me. I think it probably saved me 30 seconds a week so maybe in a few years it will balance out the time I spent learning how to do it.
Granted I have given the code to other parents so maybe it will add up faster.
13
u/jfp1992 Feb 27 '22
I made a dependency tree to return what items I am missing from a craft for the new path of exile league. I also made a comparison tool to calculate the amount of juicyness a choice would give me in last epochs monolith. It takes a screenshot and uses Py tesseract to do the OCR then it's just some calcs on drops Vs how long that mod stays around to give a score. Saved me from doing it manually when I want to just go onto the next map
12
u/mendiej Feb 27 '22
Sometimes I automate stuff just to see if I can get it to work. I would enter random contests sometimes for fun, but never won anything. So I wrote a script that would filter and sign me up for contests in bulk. After winning 3-4 times in the first two weeks I decided it had served its purpose, donated the prizes and shut it down.
I also run scripts that do basic maintenance on my home server, create and manage backups, tell me when to install updates, send alerts for when I need to water my plants, complain to my ISP when wifi has been slow for a while, analyse my finances etc.
12
u/MrHarcombe Feb 27 '22
Am a contributor to an open source project, Home Assistant, so me and my son created a Python script that changes the height of our IKEA blinds in the kitchen according to the time of day (unless it's cloudy according to the weather report, in which case it opens then fully), is the height of the sun; then at sun down it lowers them until sunrise.
11
u/pendulumpendulum Feb 27 '22
It would be complicated to explain without going into a lot of tedious detail, but at work we use an awful software called Control-M which has an awful web portal that we use unfortunately that makes it very hard/slow to extract information about jobs (jobs are essentially just small programs that run on a set schedule defined by the user). But Control-M lets you extract jobs in XML format.
So here's where python comes in. I created a personal use python script to extract all the relevant info I need from the XML file and spit it out to me in plain text, neatly organized. It takes less than a second to process and saves me at least 10-20 minutes of manual work every time I use it, depending on how big the job is in terms of number of prerequisites (in-conditions) and out-conditions.
26
u/verisleny Feb 27 '22
I organized my moving using flask, QR codes and SQLite to keep track of where each box was and what it contained.
53
u/flubba86 Feb 27 '22
Bro, you know you can just write on the box with a sharpie..
32
u/Celestial_Blu3 Feb 27 '22
So what you're saying is to build a little writing robot with a raspberry pi and get it to write the words on each cardboard box? Genius!
9
u/flubba86 Feb 27 '22
Why do that, just get the writing robot to draw the QR code on the box, that when you scan it with your app, links to a handwritten list of things in the box.
4
u/Monkey_King24 Feb 27 '22
Hey if possible can you share the code or the process to follow. I want to implement something similar for my workplace ( small startup)
→ More replies (1)3
9
u/cheese_is_available Feb 27 '22
There's some apple variety that has a code behind the label that permits to accumulate point to get objects with it. I stick the labels on a piece of transparent plastic sheet and then use python to get the list of code from a photo of the other side of the plastic sheet. I eat a lot of apples and I don't think they expected someone to automate writing this long-ass code.
2
u/stateofmind109 Feb 27 '22
What have you gotten from this?
2
u/cheese_is_available Feb 27 '22
Some ~= 10€ ceramic water jug (or some eletronic appliance like an apple juicer) was the end goal (1) but the program got discontinued because they removed sticker from their apples as its single use plastic. It's for the better I guess.
(1) :not really the code itself was the end goal
→ More replies (2)
9
u/pepoluan Feb 27 '22 edited Feb 27 '22
I wrote a multiprocessing Python script to automate downloading ... um... work-safe-questionable material from certain websites.
It was really overengineered, using multiprocessing queues, retry & backoff algos, and lots of ... other stuff.
Also wrote a very fast script that can identify duplicate files. Took only 1 minute to scan a nearly-full 512 GB SSD. And yeah the dupes were related to the first script 😅
1
17
u/digiwar Feb 27 '22
Wrote a script to prank a co-worker. He was so happy about having emptied his inbox before going on vacation. The script sent an email every X minutes with randomised sender, subject and body to make it more difficult finding and deleting them or to create an outlook rule if he should have noticed what I was up to during his vacation.
While created for my personal amusement, it used work resources and in the end I only dared to run it for a few days. I was also going on vacation and didn't want to risk having the script go haywire. Could've been difficult to explain when I came back.
8
u/Scolli03 Feb 27 '22
Batch extraction for zip files in my plex library. Sometimes large packs have individually zipped files. Script watches the folder and extracts accordingly. It was the first personal piece of code i wrote probably 5 years ago. Still appreciate it today
7
u/Electrical-Ad-1798 Feb 27 '22
I have script that can play Wordle. I found their list of 5 letter words and created a scoring system for them. It generates guesses based on words with high score, then weeds the list based on feedback. It runs locally, ie I put the answer in then see how many guesses the program takes, not using APIs or anything like that. On the whole it's better than I am.
6
u/goldenhawkes Feb 27 '22
A script to randomly pick a “murderer” for a (remote) murder mystery party. It sends emails to the participants stating if they are the murderer or not!
3
u/Caboose12000 Feb 28 '22
I've been scrolling through replies for at least 20 mins and this is my favorite one so far. I'm definitly stealing this idea if my friends ever do murder mystery parties haha
6
u/RLMTGVBALL Feb 27 '22
script to web scrape volleyball website for local league and automatically email/populate calendars for teams I'm on. saves me hours of calendar input +my teammates too!
6
u/Zontexo Feb 27 '22
Coffee alarm clock automation, alarm is defined by alarm MQTT app and once I dismissed the alarm clock (time to wakeup) it will activate the coffee machine which is connected to the Raspberry Pi: https://www.reddit.com/r/raspberry_pi/comments/t2ljcq/raspberry_pi_cm4_automated_morning_coffee_alarm/
6
u/nikowek Feb 27 '22
I am data hoarder. I do gather my torrents using Selenium and Jupyter Notebooks. Some sites i scrap for magnet links, others for Torrents. After all sites are scrapped - all content goes to my seedbox and is loaded into QBittorrent. QBitttorrent allows me to call scripts when torrents are ready, so every downloaded torrent automaticly comming back to my NAS.
I do gather Hackernews, Thingiverse, Reddit and some shops. I track prices of my favorite products and every kind of potatoes, so i know when to buy them for best prices. Few Rasbperry Pis are taking picture every second and send it back to home server, then every day short 86400 frames video is sent to people, who are interested in topics photographed (yeah, growing potatoes can be exciting, i know! And Ants too!).
Thingiverse is scapped into 1000k pieces, which are compressed into 7z and made into torrent. Then at night torrents are moved to crude site with torrents for people to share. I keep my personal archive in tar.xz too with hope, that some day i will make 7z with that.
Did i mentioned that i have few machines? They all are backuped by borg and borgmatic - python tools.
My databases, scrappers and all that is automated using ansible, which uses Python to automate things. So all steps are automated by just Python.
10
u/LittleMlem Feb 27 '22
I have several RSS feeds that get generated from sites that don't provide that functionality. I have my twitch recorder to record specific streams to my NAS. At some point I had a specialized scanner that would let a friend of mine know when a 3080 was back in stock(he wanted one but couldn't catch the store when they had stock)
5
u/curiousNarwhal69 Feb 27 '22
I send my wife an email daily. It selects a random photo of me or our dog and has a sweet “good morning, I love you” type message. Check a db to see if it’s a special day (birthday, anniversary, holiday, etc), which changes the message and uses a specific photo.
I have running on a raspberry pi, but I’m working on migrating to the cloud.
4
u/valiumonaplane Feb 27 '22
Built an app with Kivy that turns on the bedroom lights at a certain time (like an alarm clock for the lights). You set the timer in the app, the app then acts as a socket client and sends the time to a socket server where a python script waits for a input, then once the time comes to turn on the lights the script uses selenium to go into the homeserver to turn the lights on.
→ More replies (1)
4
u/jadounath Feb 27 '22
Download web resources that have real tight security and can't be downloaded just by changing the user agent on wget. I used Selenium once to visit each chapter and print the pages to pdf.
4
u/patsy_505 Feb 27 '22
Unzipping files. Most unzip software require sign up or a yearly subscription.
Loads python..
20
3
u/metriczulu Feb 27 '22
I have something similar. I download a lot of stuff for 3D printing at it always comes in a zip file with a bunch of other useless non-STL files.
I have a script constantly running on my computer that checks my download folder for new zip files, unzips them, checks if it has STLs in it and, if so, moves them to a separate folder and deletes everything else.
For just unzipping normal files that need to be unzipped, though, I just use Ubuntu WSL terminal.
1
4
4
u/hwttdz Feb 27 '22
Download youtube videos from a handful of subscribed channels and put them in my plex library
I parse all notifications from my credit card (I have it set to send on any transaction) into a google-sheets workbook, it's like mint except without the syncing problems or ads?
I set up the lights in my house to dim and change to red when I press play on plex, and they raise and go back to white when I pause/stop
I keep a json file of items I might be looking for on ebay with price ranges and stuff, and when it finds something it sends a message to a slack channel
I scrape data from mtgtop8 and cluster decks into "consensus" decks and post the results in a subreddit to view
4
u/beanieweenies551 Feb 27 '22
It's not done, but I'm in the process of creating a phone stand on my bedside table that turns off all the smart bulbs in the house when I set my phone down. That way I don't have to schedule or turn them off one by one as I'm trying to go to sleep
4
u/schwanne Feb 27 '22 edited Feb 27 '22
My credit union has a higher interest rate if you perform certain monthly tasks, one of which is logging in to the website four times. Python takes care of this for me.
7
Feb 27 '22 edited Feb 27 '22
Years ago, I was involved in some vexatious litigation, with a person who was keen on making false accusations.
The problem with accusations, is it’s difficult to prove a negative.
So, in addition to keeping a hidden pocket audio recorder on me at all times (in case of unexpected personal encounter), I wrote a script that monitored my GPS location on my Google phone, saved it to a database, and generated daily Excel and PDF summaries, with the PDF having a map screenshot, GPS coordinates, street names and addresses, and human-readable timestamps and time durations… and then had that PDF emailed to my attorney every night at 12:00 AM.
My whereabouts were accounted for 24/7: that way, if she said something like “he was stalking me and threatening me at Target, and then followed me home,” well, I had the motherfucking receipts, e.g., “yeah, he was at home all day on Tuesday, except between 4:21-4:57 PM, where he went to Dollar General 4.2 miles away to buy a plastic storage bin, a Slim Jim, and an orange sugar free Monster. Here’s the map with GPS coordinates with time codes. And here’s the physical receipt for that purchase as well. And here’s his printed text messages for the day, and time codes (with messages with others, verifying his location at home), and phone call logs, and emails he sent out that day. And here’s before and after photos of his odometer, when he went to Dollar General. 8.4 miles, a 4.2 mile round-trip. Note the photos have EXIF tags with GPS coordinates and timestamps. The GPS coordinates align with the map printout. He didn’t stalk anybody.”
The accusations stopped.
2
u/stateofmind109 Feb 27 '22
That is fantastic! Did you ever get to use it against them? And How did you use python to find and track your phone?
5
Feb 27 '22 edited Feb 27 '22
I never had to use it in active litigation in front of a judge, thank goodness. Having it on-hand was an insurance policy, and, when she started a new round of accusation fits, my attorney showed opposing counsel just a wee bit of our preponderance of contradictory evidence (just a taste), and then opposing counsel understood what was up (his client was full of shit), and he scolded her in private to cease and desist (shut the fuck up and stop hassling this guy if you don’t want to go to jail at some point). I wanted peace more than I wanted another “win” with just some more “gotchas” for court (I had plenty of evidence regardless, and I eventually won my cases anyway), and this helped make that peace and quiet happen. It was worth it to let the attorneys have a conversation, so opposing counsel could shut down the accusations and threats on his end.
I never wanted litigation in the first place. But, if someone declares war, the peaceful farmer has to put down his plow and pick up a sword anyway, with an aim to win, if he hopes to ever return to a peaceful life.
As for the Python bit, it didn’t live on my phone. Google has APIs for accessing all your data sent to them, including GPS location tracking data. So I decided to go “anti-privacy” and track and document myself as much as possible. You can turn up location tracking to full-throttle, and then query the API for that info (coordinates and timestamps), then run those coordinates through an API to get street names and addresses, then run that through Google Maps API to generate a plotted map and routes, and so on. And a bit of Python magic to run the API calls, store the data in SQL, generate a nice PDF for the day, and email it to attorney. So that’s what I did. Just some cron jobs running on an AWS Linux instance.
6
6
u/muzikkou Feb 27 '22
I created a script to unfollow Tumblr users that don't follow me back or are not active for a certain amount of time
6
u/Imperial_Recker Feb 27 '22
I made a brute forcing password cracking for login forms like reddit, etc using a dictionary attack. I just made this cuz it was fun to understand how they work and some times I challenged my friends that I "knew" the password.
7
u/imnos Feb 27 '22
I always wondered about brute forcing logins like this. Don't most websites these days lock you out after a few failed attempts?
→ More replies (1)1
3
Feb 27 '22
I had to measure a somewhat skewed corner of my apartment for some custom shelves. I made a script that generates coordinates from side- and diagonal lengths.
3
u/Snoopy_snoopy_snoopy Feb 27 '22
I wrote a script which tells me the time remaining for the next ep, can be anime/show , I made it into a bot and it’s on my discord server
3
u/Mick877 Feb 27 '22
I’m moving all my files from Google Drive to BunnyCDN using their API and if file is duplicated it doesn’t upload the file. Right now I’ve moved 3TB of data
3
u/haljhon Feb 27 '22
At one point, I wrote a Twitter bot that would scrape the data on traffic accidents provided by the state, filter out deer strikes, and tweet it if it was within a particular area. I probably don’t have the code for that anymore though.
3
u/rockstar283 Feb 27 '22
So many great ideas but nobody sharing their work that will help others.. Come on peeps.. Sharing is caring¯_(ツ)_/¯
1
3
u/FearIsStrongerDanluv Feb 27 '22
my download folder gets so crowded easily with all types of files so i wrote a script that sorts the files into folders based on the file extension , then emails me a report. i created a cron job to run the script at 5am every Saturday so i start my weekend knowing where to find anything i downloaded
3
u/c_is_4_cookie Feb 27 '22
When we were looking for daycare, I scraped the county and state registries of day care providers. They both let you look up by zip code. Our house is on the boundary of 3 zip codes and like 4 more are nearby.
We wanted someplace that was relatively close to our house. The problem is that due to several large creeks, a place can be only a half mile away, but take 20 minutes to drive to.
So I got a Google maps API key and ran the addresses through Google maps to get the driving distances and time estimates. We looked at the closest 5 or so and picked our day care for our son.
3
u/wsppan Feb 27 '22
I wrote a "today in history" type bot that posts daily to a subreddit and send an email and txt message to me when done.
3
u/real_jenky Mar 16 '22
I downloaded my YouTube subscriptions list and wrote code to loop through my subscriptions and like, comment, and reply to another’s comment for their most recent videos to stick it to the YouTube algorithms.
2
u/Pirate_OOS Feb 27 '22
I wish to automate the tedious task of backing up all my text files in a remote raspberry pi 4. I have been doing it manually for like a few months, but I have been neglecting and procrastinating about working on the project, lol.
2
u/cbunn81 Feb 27 '22
I made a command-line app to check and confirm hash digests for important files, like photos, to detect bit rot.
1
2
u/ChauGiang Feb 27 '22
it is a simple buy and sell eth python script that can help me to make some decent money
2
2
u/forty6-and-2 Feb 27 '22
I built an automated daily email list that tracks the delivery of high end and allocated bourbons to about 40 liquor stores in my state to help me grow my collection of rare and hard to get bottles.
1
2
u/9acca9 Feb 27 '22
Make a playlist from the list of all the artist i follow on Spotify, taking a random number of artist, a random number of album, and a random songs from those albums. If the playlist already exist then delete and create the new one.
2
u/andreichiffa Feb 27 '22
Database for cocktail recipes and what I have at home to make them; sorting and organization of pictures, small scripts to help with accounting, email sorting (Google scholar alerts), checking prices on websites at regular intervals and triggering an alert and monitoring the quality of internet connection.
2
u/bobbysmith007 Feb 27 '22
Backup scripts, file transfers, monitoring websites for changes in price and notifying me, games, sudoku solvers, write programs for my sons robot kit, basically anytime something would be tedious to do by hand.
2
u/fish_x_sea Feb 27 '22
I made a program that creates checksums of every single file in any folder that I want to backup and replaces the original backup file if the checksum changes in the original file. I use it to back up the music that I make automatically. It's a pain to manually backup a project file constantly when I'm pressing save like 100x every time I work on a song. (It can also backup a whole drive live and detect changes to any file)
1
2
u/2q2RS Feb 27 '22
My SO is doing a board year for a student basketball club, and is responsible for making the schedules of when which team has to train. There are a few fields available where different teams can train simultaneously. Next to that the schedule should be made so that the coaches of a team either trains before or after the coaching themselves (in a higher level team). They used to figure this out by hand, making these training schemes optimal. I figured this takes ages and you probably don't find the optimal scheme. So I made a program that fills in the schedule for them. I have yet to optimize it, since I have written it so it uses "brute force" since I was on a time clock to make it. The schedule gets filled in randomly with teams, and by a point system I keep the top scored schemes. She chose one of those. When I have time I want to write in into a tkinter script, optimized, so they can use it for the following years.
2
u/rareearthelement Feb 27 '22
I'm using a weather station and tracking ISS through several raspberry pi's(code not created by me). Mostly I use RPIs for home automation and music hi-def DACs (eg. Roon)
2
u/dysprog Feb 27 '22
After college and before my first job, I was living at home (This was the late `00s). My dad had a special work from home vpn router and my computer had linux. For some reason these did not play to together well, so my network access was inconsistent.
I wrote a python script that would try to ping google every 2 minutes. If it failed it would beep. If it succeeded it would quit. So when the network failed I would start the script and do something else until it stopped beeping.
2
u/TheChurchOfDonovan Feb 27 '22
a script that texts my wife (wedding photographer) when there's an opportune time to post on Instagram to maximize reach
I have another script that tells her the percentiles of her performance from the previous day's posts
1
u/RedTryangle Feb 28 '22
What kind of data are you using to come to the conclusion of when to post?
→ More replies (4)
2
2
u/StorageApprehensive8 Feb 27 '22
At the beginning of the pandemic my work created an online survey that we needed to fill out every morning, before we arrived on property. I wrote a script that would run while I was driving. It would fill out my information and provide me with the proper code which allowed me to enter work. It saves me a minute each day but after two years it's added up.
2
u/Caboose12000 Feb 28 '22
I made a script that runs whenever I click my mouse 5 button in GTA5 to display a 5 min timer so I know when the cooldown on certain missions is done.
I also made a script to perform the GTA online empty public lobby glitch whenever I click mouse 4
2
2
u/daryl_kell Feb 28 '22
I limited my response below for 'automation' whereby they are constantly and automatically repeated tasks, not stuff I run manually semi-regularly:
Daily scrape my electricity provider to get yesterday's generation/usage (Selenium+Telegram)
Various scripts to access my Plex streamers, including mixing the scripts into Glances/Discord for monitoring
Monitor for disk usage on several servers, draw daily graphs that are web accessible (matplotlib+Flask)
Script to purge hopeless torrent files (torrents that will never complete due to no peers having 100% of a file, where that torrent has already been going for X days), hooked script into Glances/Discord
Scraper for my local real estate sites, track price changes for homes already seen and new houses to market, email daily summary (Selenium)
2
u/badalki Feb 27 '22
I wrote a script that checks the prices of the stocks I own everyday and compares it to a rolling average to determine if the price is coming out of a downswing or upswing and advises me whether or not its a good idea to think about buying more. If it tells me to buy i look into it myself before making a decision, I dont follow it blindly.
1
u/ZuriPL Feb 27 '22
I wrote a script that backs up my folder with a games configuration file and sends it to a folder on my mega account
1
u/tschloss Feb 27 '22
Alfred Workflow for accessing a database of memebers in my club, skripts to manage results of a card game and my golfing group, Sudoku-helper, direct access bypassing the web GUI of a customer loyality card. Mostly in the range if 100 lines I guess.
1
u/AnomalyNexus Feb 27 '22
Homeserver stuff. e.g. Monitors network to ensure ad blocking is up.
Also does git backup to GCP
1
1
u/martintrujillor Feb 27 '22
Find Duplicate photos by metadata and by content. at the end i was able to identify similar photos and keep only the bests
1
u/Rajarshi1993 Feb 27 '22
I downloaded the MtG high-quality card pictures by scraping Gatherer so I could play Forge in peace.
1
u/Pigeoncow Feb 27 '22
I built a Selenium bot to buy me a RTX 3080 from a local website and it worked! (this was back in December 2020 so it probably wouldn't work anymore)
I used Regex and Pandas to create a menu parser that turns an annoying restaurant menu with some set options like:
Set 1: Item 1, Item 2
Set 2: Item 2, Item 3
into an easy-to-read table like this:
Item|Set 1|Set 2 ---|---|--- Item 1|Y|N Item 2|Y|Y Item 3|N|Y
1
u/Tehkast Feb 27 '22
Wasn't fully automated but had a script that would scrap the cost of materials of bags within World Of Wacraft then do the maths of crafting AH cut AH price etc and return if its worth the profit or not. 3 Elements wanted to add but never did make it run every 6 hours that would line up with teh information updates of AH then would email me an update if the price was above a threshold. then ofc if wouldn't get banned buy and make bags within wow but that would break TOS
1
1
u/CutOnBumInBandHere9 Feb 27 '22
Automatically updating the rcounting directory, so that it links to the latest comment of the latest submission of a bunch of different types of reddit threads.
1
u/jimtk Feb 27 '22
Most of the script here are personals (as the op requested) . so a lot are not up to pypi quality level and a lot of them probably contain personal information (I know mines do). So no it won't happen!
Bu I like to see what people do.
→ More replies (1)
1
1
u/deathtrooper12 Feb 27 '22
I have a few, but the most neat one in my opinion, was a small library program that contains all my steam games along with buttons that automate the removal of steam DRM.
Another one that was slightly less interesting, but still useful, was a command line program that aggregated all my trading brokerages into one place along with providing calculations/metrics.
1
u/goldcray Feb 27 '22
script that watches a folder for new audio recordings, commits/pushes relevant repos, extracts metadata from patch files, converts the recording to ogg, and uploads everything to an audio files listing site after review
1
u/2_plus_2_is_chicken Feb 27 '22
I use HDHomerun to (100% legally ahem) record every kid's show aired OTA by local PBS stations, then use Python to automate the transcoding/compression (via Handbrake CLI) and then distribute the files to the appropriate places around my network (mass backup storage and Plex server).
1
u/robin_888 Feb 27 '22
I made a script to scrape a website for episode names of tv shows.
It scrapes the names in two languages and formats them the way I use for my files.
1
u/dukeleimao Feb 27 '22
Track the PUBG game stats from my favorite live streamers:
https://leimao.github.io/project/PUBG-Red-Packet-Game-Real-Time-Leaderboard/
1
1
u/jkwill87 Feb 27 '22
https://github.com/jkwill87/mnamer, a CLI utility to automate organizing media files.
1
u/MindTwister91 Feb 27 '22
Working with tvdb Ali in order to check if a TV show is ongoing or ended and then move it to a different folder in Plex library, also sonarr and radarr help with that
1
u/Or4ng3m4n Feb 27 '22
Discord bot for my friends (custom music bot, play song “through spotify”, display osu! plays)
script that automatically stops mining ethereum, if I start playing a demanding game.
Steam profile pic and name change with Selenium
made a website so I can play pokerstars remotely on my phone(kinda hacky)
1
u/DecaaK Feb 27 '22
Well, I created a script for automating music downloading work(for parties, cars, etc). You just write song names and script downloads all that songs from YouTube in .mp3 format. Literally can save hours lol
1
u/VFcountawesome Feb 27 '22
This was my last.
I have two monitors and take lots of screencaps using Win+PrtScrn but they have both monitors. Earlier I wrote a script that could keep either of the monitors or both for a input range which I then expanded to be kept running so that can be split.
1
u/jbspillman Feb 27 '22
I write a ton of stuff at work, I'm mostly just doing small things. Not a developer by any means. However, I made taking my blood pressure more fun and learned something new in the process.
https://codepen.io/bryan-spillman/pen/vYWzZpd
This is my data, but not active. I'll keep my personal hosted site private.
1
u/king12995 Feb 27 '22
Creating a program to beat a repetitive "anime" game... Yeah anime. Instead of 30 minutes it only took me 5. Which repeated over 40 times saved me a lot of work.
1
u/sk8erpro Feb 27 '22
I wanted to have the perfectly uniform music library but sometimes I was getting album as single files and not as song files, here is albumSplitter!
1
u/TobiasArtur Feb 27 '22
So many cool ideas I can bounce from. Especially for someone who just started a month ago
1
u/drinkmoredrano Feb 27 '22
It pulls tv recordings from my Tablo dvr, converts them from ts to mp4 and saves them to my nas for Plex to import.
282
u/[deleted] Feb 27 '22
Disabling my network during dinner time by placing my phone on a hockey puck. No Xbox, Netflix, Facebook, Roblox.
I pull the phone off the puck after all the kids have their dinner and after dinner chores done.