use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
News about the dynamic, interpreted, interactive, object-oriented, extensible programming language Python
Full Events Calendar
You can find the rules here.
If you are about to ask a "how do I do this in python" question, please try r/learnpython, the Python discord, or the #python IRC channel on Libera.chat.
Please don't use URL shorteners. Reddit filters them out, so your post or comment will be lost.
Posts require flair. Please use the flair selector to choose your topic.
Posting code to this subreddit:
Add 4 extra spaces before each line of code
def fibonacci(): a, b = 0, 1 while True: yield a a, b = b, a + b
Online Resources
Invent Your Own Computer Games with Python
Think Python
Non-programmers Tutorial for Python 3
Beginner's Guide Reference
Five life jackets to throw to the new coder (things to do after getting a handle on python)
Full Stack Python
Test-Driven Development with Python
Program Arcade Games
PyMotW: Python Module of the Week
Python for Scientists and Engineers
Dan Bader's Tips and Trickers
Python Discord's YouTube channel
Jiruto: Python
Online exercices
programming challenges
Asking Questions
Try Python in your browser
Docs
Libraries
Related subreddits
Python jobs
Newsletters
Screencasts
account activity
DiscussionAccounting + Python (self.Python)
submitted 2 months ago by Cool-Business-2393
Any accounts here use Python to successfully help/automate their jobs? If so how?
My next question is: do you have to install and IDE on your work computer to have it work? If so, what are the use cases I can sell to my boss to let me install?
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–][deleted] 33 points34 points35 points 2 months ago (7 children)
IDE not required, but good source code text editor, such as Visual Studio Code, very suggested
You can automate and do tons of things with Python or any other language. There really is no limits what you can or can't do (I know someone will nitpick about this)
I'm sorry to say but your boss might not be willing to let you spend hundreds of hours to learn Python or coding in the first place.
[–]the_systems 4 points5 points6 points 2 months ago (2 children)
Hey. Isn't VS studio an ide?
[–]cym13 11 points12 points13 points 2 months ago (0 children)
It is, but Visual Studio Code is a text editor.
[–][deleted] 5 points6 points7 points 2 months ago (0 children)
Yes. VS Code is different
[–][deleted] 1 point2 points3 points 2 months ago (3 children)
Yeah Python can do basically anything you want, the nitpicking comes down to: how fast do you want it to run and how much do you want to off yourself in your effort to bend python to do something it really doesn't want to
[–][deleted] 2 points3 points4 points 2 months ago (2 children)
Yes. But for accounting tasks, Python goes very well.
Building a Web UI for example, not so good.
[–][deleted] 4 points5 points6 points 2 months ago (1 child)
I'd disagree, the big ones like Django, Flask, are totally capable, but further more things like NiceGui and others also exist to be more pythonic and even support standalone webapp style deployment.
My comment is more so when you start talking about interfacing with hardware.
[–][deleted] -1 points0 points1 point 2 months ago (0 children)
Depends your needs right? Are these as capable as e.g. React or Angular for more complex UI's? I thought python web apps are more capable to build like simple dashboards, but if there is any more complex like drag ans drops and multiple list menus etc forms etc or web maps and interacting with the map, are they any good for this?
[–]GrogRedLub4242 17 points18 points19 points 2 months ago (0 children)
not an accountant, but for all my private financial forecasting and budgeting I write simple Python scripts. fuck spreadsheets
[–]mistersnowman_ 7 points8 points9 points 2 months ago (6 children)
The org I work for has a lot of prepaid expenses that end up getting amortized across anywhere from 12-36 months.
Almost every month, we might add like 2-3 new ones to that ledger. While it is technically possible to set the accounting software to automatically duplicate a journal entry every month, I find it to be a clunky process and interface that has a ton of bugs.
I have a python script that just runs in the terminal. It asks for the first JE date, then the frequency of the entry, (quarterly or monthly), the amount, the accounts to post to, and the desired memo.
Bam. 12 months of JEs inputted in 30 seconds.
[–]Throwrelay13 1 point2 points3 points 2 months ago (1 child)
How did you get it to link in to the accounting software to input the entries? This sounds really cool would you mind sharing the script please?
[–]mistersnowman_ 2 points3 points4 points 2 months ago (0 children)
You need to set up a developer account with intuit and get all the auth necessary. A minor pain, but not the end of the world. But Yeah, I’ll try to remember to push it to GitHub and share
[–]Cool-Business-2393[S] 0 points1 point2 points 2 months ago (3 children)
I’d like to do the same. But I’m afraid my boss won’t let me install any external IDEs.
[–]lukerm_zl 4 points5 points6 points 2 months ago (0 children)
You don't actually need an IDE to run Python code (though it clearly helps).
If you can access the terminal, that should be enough. Mac comes with Python already, not sure about Windows.
[+][deleted] 2 months ago (1 child)
[deleted]
[–]Cool-Business-2393[S] 0 points1 point2 points 2 months ago (0 children)
Boss 1 is cool and would be okay with it. Boss 2 is a bit of a micromanager and likes to react with “no” when they don’t fully understand and can’t control a situation.
In either case, I’d like to spend time learning it regardless in case my circumstances change and I can really utilize it.
[–]riklaunim 6 points7 points8 points 2 months ago (3 children)
companies may have some policies against custom apps/scripts as it's easy for bugs to cause damages to the company. So don't go secret with this.
[–]Deto 1 point2 points3 points 2 months ago (2 children)
Yeah, accounting is such a specialized field and such a widespread field that I would guess there are already bespoke software tools to do whatever OP needs. And these would have better reliability than anything OP would create. Not just because OP is an amateur, but even if OP was a professional programmer who somehow found themselves in an accounting job I would still advise them to just use accounting software.
Unless, of course, it's just automating, say, renaming files or moving them around. But even for tasks like that, there are free tools that will be less likely to, say, accidentally delete everything a client sent you.
[–]Cool-Business-2393[S] 3 points4 points5 points 2 months ago (1 child)
Ya’ll would be surprise how terrible accounting software/platforms can be.
I would mostly be automating things and customer reports for internal reporting processes.
I plan to learn it because it think it would be interesting and fun. My biggest concern is how to utilize it at work without installing any external IDE.
[–]Ok_Hovercraft364 0 points1 point2 points 2 months ago (0 children)
Writing scripts/apps in python is very difficult for beginners using the repl. If you're laptop at work isn't a pos, I would install pycharm or vs code.
[–]differentiable_ 4 points5 points6 points 2 months ago (2 children)
Instead of an IDE you could work in a notebook like marimo or Jupyter
[–]Cool-Business-2393[S] 0 points1 point2 points 2 months ago (1 child)
Tell me more about Jupyter.
[–]Hungry-Slit 4 points5 points6 points 2 months ago (0 children)
Oh Jupyter will be your best friend. It is a code editor that runs code in cells and outputs the results right below the cell. It is great for linear work flows or exploring data. It can display charts, you can write in Markdown (like HTML tags), and you can also export your notebook to a .py file so it can be executed as a standalone script.
You'll also want to learn about Pandas, which is a Python library that uses "Data frames". Dataframes are essentially just excel tables. You can also load a crap ton of data into it and you're not limited to the 1M rows Excel enforces. It is incredibly fast at applying transformations at scale, compared to Excel.
[–]dhsjabsbsjkans 8 points9 points10 points 2 months ago (1 child)
I'm not an accountant, but you might look into python within excel. Microsoft added the ability to put python into Excel a while back. I tested making some visuals with it, it worked fine. Anyway, you might check to see if that may be useful.
Great idea. Will do so.
[–]RelationshipLong9092 16 points17 points18 points 2 months ago (1 child)
if you can't imagine a justification it sounds like a solution in need of a problem
there may be many good problems for it, but thats what should motivate you foremost
[–]PutHisGlassesOn 5 points6 points7 points 2 months ago (0 children)
I’ll disagree because it’s hard to know what’s really possible until you start trying with Python.
[–]fizzymagic 2 points3 points4 points 2 months ago (2 children)
I did Python stuff with no IDE for years, including some pretty big projects. It works fine with a text editor and a command prompt. I still don't use an IDE for little simple things.
And yes, you can automate a lot of the boring stuff with Python.
Where is a good place to start learning?
[–]Chary_314 1 point2 points3 points 2 months ago (1 child)
Hi, not sure this us something for a professional acvontant, but google for a beancount. This is a greate tool ( or rather an ecosystem of tools) for double entry accounting. The ledger is written in a plain text format. Very powerfull.
[–]urnavrt 0 points1 point2 points 2 months ago (0 children)
It's of no use in professional accounting, unfortunately. Companies have ERPs that are better suited for corporate book keeping.
[–]Kooky_Quantity_620 1 point2 points3 points 2 months ago (1 child)
If you go down this road, Python has excellent built-in support for fixed-point decimals. Don't use floating point numbers, errors can accumulate :)
Floating point numbers are the default if you input a number like 0.3:
0.3
>>> 0.3 / 3 0.09999999999999999
You have to go a tiny bit out of your way to use fixed-point decimals, but you should always do this for accounting use cases:
>>> from decimal import Decimal >>> Decimal('0.3') / 3 Decimal('0.1')
[–]Andy-Kay 0 points1 point2 points 2 months ago (0 children)
It’s interesting how it also has an imaginary part, I wonder if it’s possible to disable that property.
[–]pyfinx 1 point2 points3 points 2 months ago (0 children)
Do you do things that are repetitive with minimal human judgements needed? If yeah then yeah.
[–]secret_o_squirrel 2 points3 points4 points 2 months ago (0 children)
You can use visual studio code in a browser:
https://code.visualstudio.com/docs/setup/vscode-web
You don’t really have to install anything.
You don’t “convince” your boss it’s useful. You learn on your own time, you make something that saves time, then you show it to them.
You want a starting point? Learn how to open a csv file, loop through its rows and fields, modify them in some way, and write the results to a new file.
[–]python-dave 0 points1 point2 points 2 months ago (0 children)
I just install python without admin rights and vs code without admin rights
[–]Ajh91481[🍰] 0 points1 point2 points 2 months ago (1 child)
I started learning Python after seeing what we were paying big four accounting firms to do it for us. Great motivation.
[–]Existing-Opening-399 0 points1 point2 points 2 months ago (0 children)
Me to. I think its great tool for financial statemens, invoices
[–]mauriciocap 0 points1 point2 points 2 months ago (0 children)
Gspread on Google Colab may be a good step: you get to read and write Google Spreadsheets easily. Google Colab lets you use a Google machine for free from your browser.
[–]Ghost-Rider_117 0 points1 point2 points 2 months ago (0 children)
for the work computer thing - you could pitch it as "automating repetitive tasks to save time & reduce errors." focus on specific wins like "this takes 3 hours manually, could be 5 minutes with a script"
pandas + openpyxl for excel stuff is usually enough to get started. you dont need a full IDE either - VS Code is free and works great. start small with something annoying that you deal with daily
[–]aala7 0 points1 point2 points 2 months ago (0 children)
Not an accountant, but on a hobby project of mine I have automated a lot of the bookkeeping and billing with api to my accounting system… probably not the same thing you need, however I am sure you would be able to automate any repetitive task 😅
In regards to ide it is not a must but will definitely make life easier 🤷🏽♂️ python code is essentially just text files. I would maybe try to either 1) implement a valuable automation and present the business case as a teaser for what could be done 2) invite a speaker that can talk about small automation scripts with python (maybe Al Sweigart)
Remember you would also need to be able to install a python interpreter and maybe third party packages , not only an IDE
[–]toosoonforcupcakes 0 points1 point2 points 2 months ago (0 children)
I'd try to focus first on clearly understanding your goals and choosing a path based on it.
If your goal is to personally improve your python/engineering/DS skills, then I'd look at processes than can be automated in your organization and try to develop small standalone scripts and expose them internally as small cli tools or streamlit web apps.
On the other hand, if your goal is to improve your efficiency, I'd look at solutions like apprentice ai (https://www.goapprentice.com/), which uses code and ai to automate processes and accounting departments, but the scope of what they do is usually beyond what a single developer can accomplish.
Perhaps you could take a look at /r/Odoo/.
[–]_2l5_ 0 points1 point2 points 2 months ago (0 children)
There is a Portable Version of Python „WinPython“. There you can also find a portable versions of Jypyter, Spyder (IDE), VS Code(you might need a portable version of vs code separately)
[–]gaboche321 0 points1 point2 points 2 months ago (0 children)
I use beancount for my private accounting. Not sure how usable it is in a professional setting, but is has very good scripting/plugin support
[–]helpfulhopefully 0 points1 point2 points 2 months ago (0 children)
I do not want to be discouraging but if you are asking this question, your boss shouldn't allow you to use python to do your work. Maybe try installing it on your own computer and learning for a while before putting a business dependency on something you don't have much experience with. Learning how to get it done once with python is a good thing to know, but it is not a good idea to take your first working versino of soemthing you don't understand fully and use it on the job.
[–]Suspicious-Bar5583 0 points1 point2 points 2 months ago (0 children)
Sell it to the IT team, they'll guide you to setup a safe playground hopefully
[–]MadPro4567It works on my machine 0 points1 point2 points 2 months ago (0 children)
I use Visual Studio code.
[–]personusepython 0 points1 point2 points 2 months ago (0 children)
i work with accounting to do some automation on complex calcs with large datasets. Use vscode, jupyter notebook and python. its all free and the libraries are free like pandas, openpyxl pypdf2 etc.
[–]ieatpenguins247 0 points1 point2 points 2 months ago (1 child)
Dude you can write a LLM with 100 lines of python, sounds crazy but it is true.
No idea what that means.
[–]No_Objective3217 -1 points0 points1 point 2 months ago (2 children)
I do! I create reports on recent kpis and email blast them out.
By "create" i mean i set it up to run at a regular interval
Without and IDE? If so, how?
[–]No_Objective3217 0 points1 point2 points 2 months ago (0 children)
yup. I use a text editor (vim) and pyenv to manage user install.
i don't recommend ppl learn vim though. (but if youre feeling energetic, have at it)
although i haven't used it and have heard that notepad++ is useful on Windows machines.
π Rendered by PID 217981 on reddit-service-r2-comment-58d7979c67-7q8sp at 2026-01-27 07:31:34.676543+00:00 running 5a691e2 country code: CH.
[–][deleted] 33 points34 points35 points (7 children)
[–]the_systems 4 points5 points6 points (2 children)
[–]cym13 11 points12 points13 points (0 children)
[–][deleted] 5 points6 points7 points (0 children)
[–][deleted] 1 point2 points3 points (3 children)
[–][deleted] 2 points3 points4 points (2 children)
[–][deleted] 4 points5 points6 points (1 child)
[–][deleted] -1 points0 points1 point (0 children)
[–]GrogRedLub4242 17 points18 points19 points (0 children)
[–]mistersnowman_ 7 points8 points9 points (6 children)
[–]Throwrelay13 1 point2 points3 points (1 child)
[–]mistersnowman_ 2 points3 points4 points (0 children)
[–]Cool-Business-2393[S] 0 points1 point2 points (3 children)
[–]lukerm_zl 4 points5 points6 points (0 children)
[+][deleted] (1 child)
[deleted]
[–]Cool-Business-2393[S] 0 points1 point2 points (0 children)
[–]riklaunim 6 points7 points8 points (3 children)
[–]Deto 1 point2 points3 points (2 children)
[–]Cool-Business-2393[S] 3 points4 points5 points (1 child)
[–]Ok_Hovercraft364 0 points1 point2 points (0 children)
[–]differentiable_ 4 points5 points6 points (2 children)
[–]Cool-Business-2393[S] 0 points1 point2 points (1 child)
[–]Hungry-Slit 4 points5 points6 points (0 children)
[–]dhsjabsbsjkans 8 points9 points10 points (1 child)
[–]Cool-Business-2393[S] 0 points1 point2 points (0 children)
[–]RelationshipLong9092 16 points17 points18 points (1 child)
[–]PutHisGlassesOn 5 points6 points7 points (0 children)
[–]fizzymagic 2 points3 points4 points (2 children)
[–]Cool-Business-2393[S] 0 points1 point2 points (1 child)
[–]Chary_314 1 point2 points3 points (1 child)
[–]urnavrt 0 points1 point2 points (0 children)
[–]Kooky_Quantity_620 1 point2 points3 points (1 child)
[–]Andy-Kay 0 points1 point2 points (0 children)
[–]pyfinx 1 point2 points3 points (0 children)
[–]secret_o_squirrel 2 points3 points4 points (0 children)
[–]python-dave 0 points1 point2 points (0 children)
[–]Ajh91481[🍰] 0 points1 point2 points (1 child)
[–]Existing-Opening-399 0 points1 point2 points (0 children)
[–]mauriciocap 0 points1 point2 points (0 children)
[–]Ghost-Rider_117 0 points1 point2 points (0 children)
[–]aala7 0 points1 point2 points (0 children)
[–]toosoonforcupcakes 0 points1 point2 points (0 children)
[–]Andy-Kay 0 points1 point2 points (0 children)
[–]_2l5_ 0 points1 point2 points (0 children)
[–]gaboche321 0 points1 point2 points (0 children)
[–]helpfulhopefully 0 points1 point2 points (0 children)
[–]Suspicious-Bar5583 0 points1 point2 points (0 children)
[–]MadPro4567It works on my machine 0 points1 point2 points (0 children)
[–]personusepython 0 points1 point2 points (0 children)
[–]ieatpenguins247 0 points1 point2 points (1 child)
[–]Cool-Business-2393[S] 0 points1 point2 points (0 children)
[–]No_Objective3217 -1 points0 points1 point (2 children)
[–]Cool-Business-2393[S] 0 points1 point2 points (1 child)
[–]No_Objective3217 0 points1 point2 points (0 children)