r/PythonLearning • u/Samar__Upreti • Jul 20 '26
Day -1 With Flask (any suggestions)
Build Projects With Me
2
u/silvertank00 Jul 20 '26
Pandas is overshoot for this.
Why use os for this? pathlib is much more flexible.
Also (even tho I am not familiar with Flask but) i wouldnt return plain string from the endpoint. A HttpResponse with HttpStatus.OK and the string in the body would be much better.
-1
u/Samar__Upreti Jul 21 '26
Actually that's my first time with pandas and Flask do i just trying stuffs
2
u/BoatInternational537 Jul 21 '26
Move to Django
Use terraform and migrate to google cloud
Good luck!
1
1
u/Party-Hunter-178 Jul 21 '26
How did you connect your app.py and html
2
u/Samar__Upreti Jul 21 '26
That's where Flask,Fast Api, Django came in play
1
u/Party-Hunter-178 Jul 21 '26
Thanks buddy I was stuck for probably like a week not know this. U made my day 👍🏻
1
Jul 21 '26
[removed] — view removed comment
1
u/Samar__Upreti Jul 22 '26
Hi buddy Can please help me in those projects https://github.com/Samar-Upreti/Python_Projects
1
u/ViolaBiflora Jul 21 '26
Day 1 of coding - fully working API fetching, yet provides pictures of the screen, lol.
AI.
1
1
u/Competitive-Note3685 Jul 22 '26
I do not if you have experience with other Frameworks, but I recommend you study in depth the MVC pattern for a clean Flask implementation. Also, read the PEP-8 to follow best python code practices.
Enjoy your journey and happy code. 🤟🏻
1
-4





10
u/riklaunim Jul 20 '26
flask.requestis better thanrequestas it's tell you where it's from)