Mirco
Could you change your username please ? It affects readability of this chat
Anonymous
I want to install Django in Local Disk D Drive. Please help me out. It's auto installed in C drive.
Anonymous
Is there anybody who can help me out?
Alex
Is there anybody who can help me out?
There is a cool finnish guy called Linus Torvalds.
Maz
There is a cool finnish guy called Linus Torvalds.
He probably won't get that 🤣🤣 but miracles still happen so...
Alex
He probably won't get that 🤣🤣 but miracles still happen so...
imho, web-developer must use unix. Otherwise he is like 30 yo virgin guy.
Gaurav
Guys how to access manytoManyfield objects values?
Alex
Guys how to access manytoManyfield objects values?
I guess you mean band.members.all() where members declared as m2m field of Band
Gaurav
How do i access nested objects ?
Alex
It returns only the primary key
ur doin something wrong
Alex
share the code
Alex
pastebin
Mirco
Guys how to access manytoManyfield objects values?
Many to many fields are treated as list so you have to loop it and use what you need
Gaurav
I am making a API to get all the details in django
Gaurav
class TournamentSerializer(serializers.ModelSerializer): class Meta: model = Tournament fields = ('name', 'start_timestamp', 'end_timestamp', 'max_players', 'current_players', 'prize_money', 'movies')
Alex
-_-
Gaurav
movies field is a manytomany field
Gaurav
so i am getting the output like this
Gaurav
{ "meta": "", "data": [ { "name": "First tourny", "start_timestamp": "2020-06-12T13:32:33Z", "end_timestamp": "2020-06-26T13:32:38Z", "max_players": 30, "current_players": 0, "prize_money": 100, "movies": 1 },
Mirco
Ok so it's better you start reading relationships about serializers on official docs
Alex
As I said, ur doin it wrong
Afghjn
Hello everyone, I want to learn Django and I want little guidance and resourse (other than django documentation) Thanks in advance.
Doragonsureiyā
Hello everyone, I want to learn Django and I want little guidance and resourse (other than django documentation) Thanks in advance.
Looking for Django tutorials? you can follow these three recommended ones: * Official documentation and tutorial * Tutorial from MDN * Tutorial from django-girls
Hårßhæ
how to secure django admin panel from attacks
Hårßhæ
or tell me how to bypass authentication of django administration
Mirco
Check the deployment topic and security on official docs
Mirco
You will find all the settings Django offers you to increase security
Hårßhæ
thanks
Raffaele
i have a problem with my website (pythonanywhere)
Anonymous
Hello
Raffaele
when I put into Allowed_host localhost and my url the website give me this error Server Error (500)
Raffaele
I have debug= false to
Anonymous
Settings.py
Raffaele
yes
Anonymous
Set debug=True
Raffaele
why?
Raffaele
the website is on a webserver
Anonymous
Just use * in allowed host on your localhost
Raffaele
ALLOWED_HOST = ['*']
Raffaele
???
Mirco
Just use * in allowed host on your localhost
* is just to check if everything works, don't use it as normal practice
.
Some one help me to start web development in pycharm linux
Mirco
Yes , only on dev environment
He's taking about debug equal to False so Prod like env, not dev
Anonymous
Not security
Raffaele
Can be
but it's not working
Mirco
If I don't go wrong PythonAnywhere has logs, check or share the log error
Cheap
i have a problem with my website (pythonanywhere)
high chances there is problem with gunicorn/uWISGI
Raffaele
Cheap
how can I solve this problem?
share the logs as Micro said, and someone might be able to help you
Raffaele
or error log?
Alex
xd
Alex
I would start from error logs, yes
Raffaele
https://privatebin.net/?5d982d8cb29a9d6a#CJ6j66cz6LPq7VQQf77FMT41h8dvYzcFSBLAf8VEdN4Q
Raffaele
that's it
Anonymous
what message appears in the browser?
Raffaele
Server Error (500)
Alex
is it up?
Raffaele
I think yes
Alex
emm, try to connect to it from console for example?
Raffaele
I'm very stupid...
Raffaele
Upgrade required Postgres is not available on your account. If you want all its shiny postgressy goodness, you'll have to upgrade to a Custom plan with Postgres enabled :) Alternatively, if you're a reclusive millionaire, and you'd like to make a massive donation in order to enable free Postgres access for all users, then do get in touch and we'll see what we can do.
snc
xd
your age?
snc
huh?
just curious :/