Денис
all migrations are done, there's no custom user class
Денис
Nevermind. Someone removed from settings this: 'django.template.context_processors.request',
Day
Django is really tuff or is it me who is stupid😁😁,,I had to get back to python basics...this framework ain't no joke,,,
Day
So who's making good moves in django??
SUPER
best source to learn django?
Doragonsureiyā
best source to learn django?
Check out PythonRes, a channel for Python resources (links to help you out).
Manik
In postgres ,want to store date time.now() but it's giving Integer out of range error.. Pls help
Manik
M using model in django for the same
Manik
Plz allow to send image's of code
Manik
Yes.
Muflone
share the code in pastebin
Manik
dt= Datefield() in models dt= date time.now() giving error
Muflone
datefield is not datetimefield
Manik
Yes that was done
Muflone
share the code in pastebin then
Abhi
share the code in pastebin then
Can anyone tell me aws groups information
Manik
share the code in pastebin then
Don't know how to ..
Muflone
Don't know how to ..
open the website and paste the code there
Jorge Luis
Somebody have a code snippet to make a search with pagination correctly in Django
Baggy ️️
I have setup Google oauth in my django project but after I logout. And click login again it doesn't ask me to choose new email It again directs to the previously logged in email account. How to make this work?
Manik
dt= Datefield() in models dt= date time.now() giving error
I removed this field from code but also giving error of integer out of range
Manik
In Python group they allowed to share photos of the code so that everyone can understand the problem n solutions
Anonymous
That is not allowed
Manik
I in telegram of Python its allowed
cj
In Python group they allowed to share photos of the code so that everyone can understand the problem n solutions
of course not, the rules are the same for Python group and Django group, go read them at @PythonRules, specially rule #9
Денис
Hello. Can I use __gt or __gte lookups with datetime fields?
Денис
also __lt and __lte concerned
Денис
why not?
I mean, are datetime fields comparable this way in django model?
Денис
say, I want to filter(start_time__gte=datetime.today())
Денис
just wanted to know if it's worth wasting time testing that
Anonymous
SMTP lib is not defined error comes
Anonymous
When I try to send email from script
Anonymous
I didn't know why
Anonymous
I have also import smtplib
Anonymous
But error comes
Anonymous
Someone look my error please
cj
Are screenshots qualify as photos?
a good screenshot snippet would be allowed if it shows relevant information
cj
I didn't know why
programming is mean to those who can read only, maybe you'll try luck taking care of animals or plants
Anders (izzno / gooood) 🇳🇴
Does Channels make your views fire asyncronously by default? Meaning; Theoretically with wsgi your app can only handle one request at a time (unless you have more workers). Wil channels fire vews async as the requests come (without rewriting them) ?
Anders (izzno / gooood) 🇳🇴
Followup question: Django 3 beta wont handle async views with ORM calls. Whats the point if you cant wait on the DB, this is where most of the waiting happens?
Anders (izzno / gooood) 🇳🇴
Final question: Does anyone have an article link or a tip on stresstesting django? I would like to do a before and after channels ;)
Anders (izzno / gooood) 🇳🇴
Thanks @pyflare, it's just some of my views "can" fire off about 1000 queries...
Anders (izzno / gooood) 🇳🇴
Debug toolbar warns me about simuler queries thoug I'm not quite sure how to go about that... :)
Anders (izzno / gooood) 🇳🇴
seems most duplication happens in the template, as i create tables and acces models. It seems to think looping over model instances are duplicates...
Anders (izzno / gooood) 🇳🇴
Anders (izzno / gooood) 🇳🇴
Holy shit that was effective 🤣
Anders (izzno / gooood) 🇳🇴
I like the fact you have to be more efficient when writing synchronous code. Forcing you to be efficient 👍, thanks again (best practice)
Anders (izzno / gooood) 🇳🇴
Thanks 👍, I am looping over objects displaying various properties and relationships in a table, and atm I deliver them all and do the pagination in the front end. One of the most used requests takes 400 queries and 100ms. Which theoretically means if 10 persons hit i at once someone might have to wait a second.
jam
Hi guys, i need help code how to do connection django in Maxdb
Prashant
!res
Doragonsureiyā
Check out PythonRes, a channel for Python resources (links to help you out).
d3vsh3d
How do I retrieve data from mutliple models and display them in html?
Mirco
How do I retrieve data from mutliple models and display them in html?
Get data into your view and pass via context to your template
d3vsh3d
Should I suppose to create a function for each model in views?
Muflone
Should I suppose to create a function for each model in views?
No, you need a view for each page you need , regardless the models
d3vsh3d
Because it works only for one model, but the rest is not working. Or I should use Dictionaries here in views to render all models
Muflone
Views render the pages, not the models
Muflone
You can have 1000 pages (views) with just one model
Maksim
Hi
ahmet
Hi
Hi bro
Денис
Because it works only for one model, but the rest is not working. Or I should use Dictionaries here in views to render all models
In class-based views you just pass the model you want to be in the view context. In method-based views you have to take a model and pass its fields as context variables
Paolo
https://twitter.com/pauloxnet/status/1175143459172302848
Mirco
https://twitter.com/pauloxnet/status/1175143459172302848
Much better! Thanks for the contribution!