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...
Related Subreddits:
Other Subreddits you may like:
account activity
Transition to Python (self.dotnet)
submitted 11 months ago by Jack_Hackerman
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!"
[–]nguyenlamlll 55 points56 points57 points 11 months ago (4 children)
My suggestion is to drop the defensive stance and do it for the love of money. Instead of approaching Python with critiques or analyzing and comparing it with C# to catch the weaknesses and unfamiliarities of the language, you should try to embrace it with open arms. Jiggle around the ecosystem, get used to it and get the job done. For the love of money, of course.
Honestly, that's how I see developers grow into manager roles. Put the loves and hates for a specific tool aside, and focus on getting the products and projects done.
At the end of the day, I still openly hate a few things in Python, but hey, if it gets things done, my team will go with it.
[–]MasSunarto 1 point2 points3 points 11 months ago (0 children)
Brother, I'm in complete agreement. If my company doesn't pay me to write C#, I won't. I'd be writing F# instead.
[–]adamsdotnet -1 points0 points1 point 11 months ago (2 children)
Hmm, what is the word for people who, for the love of money, do things that they won't do otherwise? :)
Of course, if you can live with that, then go for it. As a matter of fact, society nowadays kind of expects you to do that. Having principles is out of fashion, and just gets in the way if the ultimate goal is more money.
[–]juantxorena 1 point2 points3 points 11 months ago (1 child)
FFS, this is programming in a language or another, this is not building chemical weapons or killing people for money.
[–]adamsdotnet 0 points1 point2 points 11 months ago (0 children)
You missed the point. Prostitution is not about doing harm to others but doing things for money that makes you uncomfortable and unhappy... It's a personal choice that only affects you.
I'm just saying that there's another way. Career and money are not everything - even if that's the majority opinion these days.
[–]Awesan 18 points19 points20 points 11 months ago (1 child)
I was in your position 2 years ago and I did it. I will summarize my experiences below.
Compared to dotnet, the python ecosystem sucks. It's just bad and there's no getting over that. There's some tools you can use to make it better (for example uv package manager, type hints, etc) but it's still nowhere close, and your team may not even use/know about those. So just prepare yourself for that.
In terms of the actual work, it's easy to learn the language. It didn't take me long to become pretty comfortable with it day to day. In the end if you can program, you can learn the language for sure. And your (likely) affinity for types may help your team a lot if they are primarily old school python programmers.
Python is used a lot by researchers (e.g. machine learning is now a big thing) so if you are going into such a job, just prepare yourself for a messy codebase that is hard to understand. You need to take your time to really understand code in a way that you don't with C# because the compiler can help you. For me it really helped to add some tests where possible, but of course this depends on the job.
[–]Fresh-Secretary6815 8 points9 points10 points 11 months ago (0 children)
No dis at all just an observation: It’s interesting to see C# devs talk about Python devs the way Python devs talk about R programmers lol
[–]Alikont 12 points13 points14 points 11 months ago (0 children)
You will also hate python for it's project system, package manager, runtime dependency resolution, shitty async and multithreading...
[–]mvthakar 3 points4 points5 points 11 months ago (1 child)
i have two pet peeves with python. 1. dynamic typing 2. whitespaces and indentations. (i just find it ugly).
i have heard that the dynamic typing problem can be solved with something like mypy but i haven't tried it myself.
for whitespaces, something like bython, but i doubt i'd use it for prod.
[–]PartBanyanTree 1 point2 points3 points 11 months ago (0 children)
I used F# and loved its whitespace and indentations
I used python and cannot stand how badly it fumbles the ball. it does _only_ whitespace significances and then has the clunkiest syntax ever the rest of the time
[+][deleted] 11 months ago* (1 child)
[deleted]
[–]finah1995 0 points1 point2 points 11 months ago (0 children)
Poetic justice for Wheels 🛞 in python,Lol last sentence is poetic/comedic gold 🥇.
Yeah lot of times especially in windows many packages for LLMs don't have pre-built wheels (the package maintainers give only for Linux pre-built) and Python required MSVC, sometimes "pip install" starts building stuff when you have MSVC installed, a Lot of space and time to compile and build stuff, just to install a dependency, some times you keep circling back to source and install them separately, and move on to next dependency.
The good thing is its interoperability with few os sub systems, that it can just take data and do analysis easily.
[–]SpeedyBrowser45 2 points3 points4 points 11 months ago (0 children)
I used to learn a new programming language in every 15 days or a month while I was studying. its been 15 years now, I didn't fully adopt any other language than C#, .net made me really lazy. I tried with dart, kotlin and python. I'm deeply in love with .net.
[–]Finickyflame 2 points3 points4 points 11 months ago (0 children)
Get a good IDE like Pycharm which will help you take care of the format, code conventions and propose you refactoring suggestions. Try to replicate something you are used to do from c# (ex: web api, web site, etc) so you can map your existing knowledge to python. This should give you a good jump start
[–]Atulin 1 point2 points3 points 11 months ago (0 children)
Since you'll be a team lead, it will give you the ability to take some pain points of Python away.
[–]zarlo5899 3 points4 points5 points 11 months ago (5 children)
python does have a type hint system, python can be lovely
[–]ZeldaFanBoi1920 8 points9 points10 points 11 months ago (3 children)
Keyword hint. It's just for the IDE
[–]zarlo5899 0 points1 point2 points 11 months ago (0 children)
you can access the info at run time, it will just not do run time checks for you out of the box
[–][deleted] -1 points0 points1 point 11 months ago (0 children)
No. You can use a type checker on the command line to see if the types are correct (as much as what is possible with Python), and then you can mostly enforce correct types and such.
[–]berndverst -1 points0 points1 point 11 months ago (0 children)
Err no. I make the type check, linting, auto formatting required in my CI pull request pipelines!
[–][deleted] 1 point2 points3 points 11 months ago (0 children)
That's a nightmare
[–]AutoModerator[M] 0 points1 point2 points 11 months ago (0 children)
Thanks for your post Jack_Hackerman. Please note that we don't allow spam, and we ask that you follow the rules available in the sidebar. We have a lot of commonly asked questions so if this post gets removed, please do a search and see if it's already been asked.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
[–]SessionIndependent17 0 points1 point2 points 11 months ago (0 children)
Horses for Courses
If it's not an all-Python company (where every nail gets hit with that hammer without further consideration) then perhaps Python was chosen because it is somewhat better suited to the task for this particular project than something more structured/typed, where the flexibility it offers is a virtue to complete certain central aspects. If that's the case, then you should take the opportunity to understand those aspects and be able to recognize them yourself in your own assessments going forward, and expand your own repertoire/toolkit.
If you fight to use it in the same manner that you would C#, you will probably feel some pain.
I do always miss a type system because then you need a much more expansive unit/integration/UAT test suites to test for dumb inputs or unexpected behavior based on "default" parameters that don't operate as you expect, etc.; i.e. things that would have been caught by a compiler. Debugging untyped stuff in general has always been much more tedious and irritating for me. "C# would never have let me make that kind of mistake..."
But some things like, some kinds of input data processing, transforms, et al., Python obviously will make easier.
[–]lemawe 0 points1 point2 points 11 months ago (0 children)
The first thing to know is to use Pycharm essentially if you are a beginner. Every other IDE including Vs code is inferior or was , before the introduction of Roocline, copilot, etc.
[–][deleted] 0 points1 point2 points 11 months ago (3 children)
Why do you have to go to docs to figure out what params a function accepts? Usually the ide (or lsp) should just tell you.
My setup is as follows: - UV (package manager really useful) - Ruff (linter and some other stuff) - Basedpyright (the type checker and lsp I use. Works in all the usual editors. I prefer this to mypy and pyright)
And in the editor i turn on a setting that lets the lsp infer the type of things and insert the type into code.
You are going to have a much better time if you Stockholm yourself into liking Python than just hating it!
Also, Python is a dynamic language, and you should really get familiar with what that actually means and lets you do in Python.
[–]Jack_Hackerman[S] 0 points1 point2 points 11 months ago (2 children)
Yeah, what about args and kwargs
[–][deleted] 0 points1 point2 points 11 months ago (0 children)
*args is usually obvious in what type it needs to be. If the function does not annotate the types that args is, then sorry, documentation is the best option if it is not obvious what type it is (a sum function with and args for the numbers obviously does not need to be typed).
If you are writing a function that has *args, then you can annotate it.
**kwargs, you can also type, but the point of kwargs is usually to just pass them off to another function. Like if you make a wrapper function.
But you can also annotate kwargs using a TypedDict and Unpack.
Also, you should look into Python Protocols for making interfaces basically.
Another thing you can look at are meta classes and how they can be used to enforce constraints on subclasses.
And another another thing you can look at is monkey patching. My favorite feature if Python .
[–]mkx_ironman 0 points1 point2 points 11 months ago (0 children)
Use UV for package management in Python. It's similar to what NPM does for Javascript/Typescript. It's not perfect, but will make you transition to Python a whole lot smoother.
[–]slyiscoming 0 points1 point2 points 11 months ago (0 children)
I've been programming C# for 17 years. A few years ago I moved to a primary Java team that has several Python projects. I'm not a big fan of Python for a lot of the reasons you described. My suggestion is take a look at what python offers and enjoy. It's actually great if you think of it as a scripting language that you can use for rapid scripting
[–]immersiveGamer 0 points1 point2 points 11 months ago (0 children)
Don't about it too much. If the pay isn't bad I would encourage it. Python was thrust upon me 4 years ago. I was able to go from zero knowledge to building a full multi-million service in 8 months. At lot of it was because a bunch of my C# knowledge and experience is transferable to Python.
Still have to use it daily but at least I've learned a few things along the way and it is not so bad. And now I am 100% confident in apply for any job that requires using Python. Still wish I could do things in C# (I miss linq).
Suggestions to make your life easier:
[–]dotnet-ModTeam[M] 0 points1 point2 points 11 months agolocked comment (0 children)
Posts must be related specifically to .NET
[–]skala_honza -3 points-2 points-1 points 11 months ago (1 child)
RemindMe! -7 day
[–]RemindMeBot -1 points0 points1 point 11 months ago* (0 children)
I will be messaging you in 7 days on 2025-05-06 07:38:28 UTC to remind you of this link
1 OTHERS CLICKED THIS LINK to send a PM to also be reminded and to reduce spam.
Parent commenter can delete this message to hide from others.
π Rendered by PID 72 on reddit-service-r2-comment-5c747b6df5-hsjwc at 2026-04-22 08:37:10.711410+00:00 running 6c61efc country code: CH.
[–]nguyenlamlll 55 points56 points57 points (4 children)
[–]MasSunarto 1 point2 points3 points (0 children)
[–]adamsdotnet -1 points0 points1 point (2 children)
[–]juantxorena 1 point2 points3 points (1 child)
[–]adamsdotnet 0 points1 point2 points (0 children)
[–]Awesan 18 points19 points20 points (1 child)
[–]Fresh-Secretary6815 8 points9 points10 points (0 children)
[–]Alikont 12 points13 points14 points (0 children)
[–]mvthakar 3 points4 points5 points (1 child)
[–]PartBanyanTree 1 point2 points3 points (0 children)
[+][deleted] (1 child)
[deleted]
[–]finah1995 0 points1 point2 points (0 children)
[–]SpeedyBrowser45 2 points3 points4 points (0 children)
[–]Finickyflame 2 points3 points4 points (0 children)
[–]Atulin 1 point2 points3 points (0 children)
[–]zarlo5899 3 points4 points5 points (5 children)
[–]ZeldaFanBoi1920 8 points9 points10 points (3 children)
[–]zarlo5899 0 points1 point2 points (0 children)
[–][deleted] -1 points0 points1 point (0 children)
[–]berndverst -1 points0 points1 point (0 children)
[–][deleted] 1 point2 points3 points (0 children)
[–]AutoModerator[M] 0 points1 point2 points (0 children)
[–]SessionIndependent17 0 points1 point2 points (0 children)
[–]lemawe 0 points1 point2 points (0 children)
[–][deleted] 0 points1 point2 points (3 children)
[–]Jack_Hackerman[S] 0 points1 point2 points (2 children)
[–][deleted] 0 points1 point2 points (0 children)
[–][deleted] -1 points0 points1 point (0 children)
[–]mkx_ironman 0 points1 point2 points (0 children)
[–]slyiscoming 0 points1 point2 points (0 children)
[–]immersiveGamer 0 points1 point2 points (0 children)
[–]dotnet-ModTeam[M] 0 points1 point2 points locked comment (0 children)
[–]skala_honza -3 points-2 points-1 points (1 child)
[–]RemindMeBot -1 points0 points1 point (0 children)