python | Unsorted

Telegram-канал python - Python

135201

You will be muted until you read the rules. Read them! @Rules_for_Python A group about the Python programming language. Offtopic things go here: @pythonofftopic Resources to learn python: @pythonres Group for Hy: @hylang Selenium: @SeleniumPython

Subscribe to a channel

Python

and then i listen that not keep private sensitivity data into the cookie of the user, like user request for register, and after he enter the email id, i send the otp and i need store the otp value in redis, but what would i store this in the session cookie, as they say not to store sensitivity data like otp there, so i am confused here in this scenerio, if keeping storing the user_id in the sesion is secure so why not keep session[otp_valid_for_10_minut] = 12221 liek this is so bad?
i have this problem anyone know this pls say what i should to do there

storing otp in session rather in redis is really critical, as my main login string of user_id is in the sesion coookie, why this is not bad tehre

Читать полностью…

Python

https://pythonbooks.org/free-books/

Читать полностью…

Python

I am a student of bca first of all wht should learn in python anyone help by sharing any lessons or document

Читать полностью…

Python

access means seeing all old email or sending email, i knew sending email using smtplib '

Читать полностью…

Python

More a topic for @pythonofftopic. When you post there, please remove your post from here.

Читать полностью…

Python

hi every one
I am working on Python for Data Science and am looking for a partner to help me along the way and study together.

Читать полностью…

Python

Read this please:
http://www.catb.org/~esr/faqs/smart-questions.html

Читать полностью…

Python

https://pythonbooks.org/free-books/

Читать полностью…

Python

btw from full basic as i not know anything what what docs and article do you guys prefer so that i can start from know what and how to use and then learn what code to write properly what any articles u say feom user friendly

Читать полностью…

Python

How Do You Developer, say to learn Pytest, is this will help me only in web dev or in what other case it helps us, i mostly found using in web dev, is this really so necessary to learn in real production! what u think in real mind

Читать полностью…

Python

ok i will do making the project first 💚 thanks for you support btw

Читать полностью…

Python

as the SessionDep's di will be sit in top of routes.py's function, is not this bad as my reouts is using the di-flask library

Читать полностью…

Python

Stop thinking
Work

Читать полностью…

Python

Actually, sqlalchemy docs are one of the best
There is a great deal of information there and the library does support quite a lot of things.

Make sense that docs are dense and filled with content.
You need to READ IT
I dont care (or anyone does) what you think of them

They are there - read them
Practice from them

Stop wasting everybodys time and learn things or not

Its all up to you

Now stop sending messages and learn

Читать полностью…

Python

Stop with DI
Its over your head

Stick with simpler things untill you get it

Stop trying to be someone you are not. Stop trying to run before you know how to walk.

Just drop this DI thing and forget about FastAPI and SQLModel

Start with basics, then move on

Читать полностью…

Python

Hello i have started using the flask_login and by the some of the docs i found it say when i will use flask_login library, they say the behind the idea of login the user and later request to check if user is login alreay or not is to keep a user_id in the session of the user as a cookie in the browser storage, and later request my flask will get the id and retrieve the user object and by this it will know what the user is what his credential is.
So basic idea i will use a secret_key and store the user_id =str value in encrypted way in the browser, so that even the user try to change the cookie value by himself my flask will know that he try to modefy this so it will not valid to another user, right this concept is working like this?
i think yes what i need a confirmation if this is right ?

Читать полностью…

Python

docs.python.org
check some courses.

Читать полностью…

Python

https://codeberg.org/Ingwerperium/Ingwerperium/src/branch/main/Python_Lernplan_100_Projekte_en.text Looking for a Random Python Task Generator?

Читать полностью…

Python

Does I can access my gmail using python

Читать полностью…

Python

Hello,
Data science,
Could you specify more

Читать полностью…

Python

Anyone with link for python documentation?

Читать полностью…

Python

i wish to get basic from of pytest to learn 🤧

Читать полностью…

Python

Check out @PythonRes, a channel for Python resources - video courses, pdf books, tutorials and other info to help you learn Python.

Читать полностью…

Python

It is useful on any kind of projects, nor only web dev.

Читать полностью…

Python

i wish but didn't know about this before. how which

Читать полностью…

Python

Just stop or i will start reporting you
Figure it out yourself, we are not here for step by step instructions or holding hands.

If you dont have a specific error or specific question about python, go Google and learn things

Once you have a specific question to ask, come back

Читать полностью…

Python

Suppose a user want to register so after successfull verification i will store his data of email and password (not mandatory) so first my app will get the request with the email_id as string from the browser,

@auth_bp.route(
rule="/register",
methods=["GET", "POST"],
)
def register():
...

so as the DDD say rather than chekcing the id passwrod, user existance in db and so on in the routes.py's register function i will call anotehr functions or class method right?

See what i get,
After i get the email id i will call regiseter_user fun from service.py module, which will call UserRepository(session-> gives by SessionDep by flask_di) and call .is_exists(email_id) methods form this UserRepository.
Then based on this it will call a OtpRepository.send_otp(reason=login/register), and based on the otp send successfully or not it will depends and then it will say appropriately if the mail is banned temporarery, suspended, email server down /choose another method.
so i will do those so where does domain, application will be there, as i understand the service layer, and then i also thought service layer and applicaiton layer are same or not i think yes?
so i will total how many differne type of modules, domain-> service -> otp_service&database_service -> infrstructer(called by protocle instance) am i right now

Читать полностью…

Python

Now i think to start making my project structer properly with DDD, so that now even i use sqlalchemy later i can easily switch to sqlmodle or di like things for this as you says in past, i will need to separate responsibility into different moduels and functions(mostly by class methods) right?
see a hypothetical example.

Читать полностью…

Python

i also wish to start new things, but the repo i am using with Full DDD pattern there is a lot of overhead to change all the things to use sqlmodel to sqlalchemy(which docs are fully unclear and noob docs), and i checked sqlmodel db works with relationship and so on the problem i just there if i write normal databse crud function in with session block with sqlmodel then there is no need to worry about di thing right???

Читать полностью…

Python

That's you open my one of the eye of learning 💚💜❤️
i appreciate ur helping 🤜🫸🫵

Читать полностью…
Subscribe to a channel