Alejandro Alomia
Made changes to the css ran python manage.py collesctstatic but the changes are not reflected in the template.
Md.
I want to apply css styles to a template but the styles I have declared are not visible.
press ( Ctrl + F5 ) after run the code it is called hard refresh
Nana
writer = models.ForeignKey(User, on_delete=SET_NULL ,null= True, blank=True) NameError: name 'SET_NULL' is not defined
B
Hi guys how can i make a simple table for django project?
Charly
Hi guys how can i make a simple table for django project?
You can write the HTML for the table in any template
F
Guys, please help me
Doragonsureiyā
Guys, please help me
Not until you explain your difficulties.
Maxim
Guys, please help me
please don't send useless messages
F
please don't send useless messages
Maxim N, I am having network issue here. Not able to send messages properly.
F
I have to update a model filed with unique constrain through CBV .
F
I have to update a model filed with unique constrain through CBV .
I want to prproduce the same operation in admin site
Hamza
How can delete old image field from media when upload new image ?
Ali
How can delete old image field from media when upload new image ?
there is a nice package for that django-cleanup
Ali
just add it in installed apps and enjoy
Алексей
Hi all! Can u help pls? How can I catch the info about authorized User on my webpage which clicking the Buttons (post requests)? Thanks in advance 🙏
Ali
Hi all! Can u help pls? How can I catch the info about authorized User on my webpage which clicking the Buttons (post requests)? Thanks in advance 🙏
in post buttons u can get the request.user in your app and that's it (0_0) and u can also create new model class like Click with user field and the button or button link etc and after clicking if it is an authenticated user u can add an object to ur model
Ali
I just need to identify the User Who clicked the Button and print it So Best option is request.user?
so u can /: what is the problem? in views.py in post method section u can get the user who clicked on the button if u don't know how to do that search about post method in django view and also getting the user in post request
Алексей
Worked well! Thank u @shalghamorg! 👍
Jasurbek
https://dpaste.org/dtB4c Hi, this part of the model is repeating in almost all of the models. What is the solution? does making a new model named CustomModel with all the fields above, and inheriting it from all the other models work?
$€nth!|
Where i start to learn django Any YouTube source or website
F
Can you get me an example or more info on Model.validate_unique(exclude=None)
Rahat
How to hide media folder in drf
Rahat
Or file hide
◔͜͡◔ محمد سلام ◔͜͡◔
how can i write for in script?
◔͜͡◔ محمد سلام ◔͜͡◔
used django
Doragonsureiyā
how can i write for in script?
What are you talking about?
◔͜͡◔ محمد سلام ◔͜͡◔
What are you talking about?
i have write forloop in script
◔͜͡◔ محمد سلام ◔͜͡◔
how can i do that?
◔͜͡◔ محمد سلام ◔͜͡◔
i cant send photo? 😔
◔͜͡◔ محمد سلام ◔͜͡◔
Doragonsureiyā
i cant send photo? 😔
Rule 5️⃣: Never post walls of text or screen photos. Use paste bins like https://linkode.org, https://nekobin.com (or your favorite one)
◔͜͡◔ محمد سلام ◔͜͡◔
https://linkode.org/#JeRiXG4CefZjtIPv4hIcH1
◔͜͡◔ محمد سلام ◔͜͡◔
this is my problem
Sonu
Can somebody help me with this 2022-09-21 12:29:12,019: WARNING/MainProcess] relation "django_celery_beat_periodictask" does not exist LINE 1: ...ango_celery_beat_periodictask"."description" FROM "django_ce... ^
𝘍𝘈𝘋𝘌𝘓 𝘈𝘉𝘉𝘈𝘚
https://www.sphinx-doc.org/
Rakesh
I think you need to use celery in your case.
As Alda suggested, i am using Celery, But now I have a problem like need to return the response from the task, Can anyone help me on this. [Celery task error help.docx] In the above document I have attached all the screenshots to make you understand my requirement and expectations Kindly suggest me on the next step to make the task return the response by itself
Rakesh
Not able to send doc
Rakesh
OK, let me explain the flow, I have a button the the front end, If I click on that it will extract the file. To extract the file it will take the particular details to connect to database, and take the particular sql query, and perform read_sql. And it perform to_csv from that dataframe. I am taking this export in HTTP response. And this response will return from that task. But, I know that celery will return json, I am not able to return that response in the task itself. Kindly need help on this. If I cannot do this task using celery, kindly suggest me any other solution to extract the file by query and connecting to database.
Vova
Hello everybody. Maybe someone had such a mistake? from django.core.management import execute_from_command_line ModuleNotFoundError: No module named 'django'
Nikita
Hello everybody. Has anyone encountered such a mistake? I can't find a solution for 3 days already (result, consumed) = self._buffer_decode(data, self.errors, final) UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd1 in position 67: invalid continuation byte
Koen de
Hello everybody. Has anyone encountered such a mistake? I can't find a solution for 3 days already (result, consumed) = self._buffer_decode(data, self.errors, final) UnicodeDecodeError: 'utf-8' codec can't decode byte 0xd1 in position 67: invalid continuation byte
Your information is rather limited. What is “data”? And what does your method _buffer_decode actually do? Are you willing to post the complete error trace and code? And… missing what this has to do with Django instead of basic Python. It seems though that you are trying to decode “something” with the utf-8 decoder but that “something” is not utf-8 encoded. Try chardet or libmagic to detect what encoding that “something” has; https://stackoverflow.com/questions/436220/how-to-determine-the-encoding-of-text Or have a look at this question/answer which has some nice pointers too https://stackoverflow.com/questions/10406135/unicodedecodeerror-ascii-codec-cant-decode-byte-0xd1-in-position-2-ordinal
S.F.
⏭️⏭️⏭️ please help Do you know any rest api package for authentication Login with phone number on email or user name
S.F.
It's not hard to implement that
I want with register - token - forget password and I don't have time
Nqabeni
Hi pythonistas, I am looking to encrypt django source code for a client. Has anyone done before.Please point me to the right literature.Many Thanks,
Nqabeni
You choose the wrong language to do that
please elaborate @Carlangueitor
Charly
please elaborate @Carlangueitor
Python is an interpreted language if you need to hide the code python is not the tool for that
Mojo
Is it possible to stream private videos from youtube on django?
Mohamed
what is the importance of put secretkey in .env file instead of settings.py
Anonymous
Any django architect from Mira Road.
MRT
Hello, has anyone here deployed django channels with daphne? I have a problem, the speed of sending data is normal on the local host, but after deployment, the speed of sending the file is very low. A file of 500 kilobytes takes 20 seconds.
Neo
what is the importance of put secretkey in .env file instead of settings.py
you dont want your secret key to be in your code where others can see it
Mohamed
Doragonsureiyā
Any django architect from Mira Road.
Rule 🔟: Job posts are SPAM unless they meet the requirements. Read the rules for details.
Ajay
Anyone having good knowledge of AWS here ?
Doragonsureiyā
Anyone having good knowledge of AWS here ?
Looks like you need an offtopic group, please continue this conversation at @pythonofftopic as it's not related to Python
Денис
Can I use few serialializers in redoc?
Денис
How?
Денис
I mean, I need to display two serializers In one endpoint, by two roles
Abd Al Rhman
Hello guys, i've started to study Django for backend. What is the most important advice you would give to me while learning it?
Charly
Hello guys, i've started to study Django for backend. What is the most important advice you would give to me while learning it?
My advice is: Read the documentation, (start with the official tutorial but also keep referencing to it for all other topicsl
Abd Al Rhman
When do you think I have read enough to build my first app?
Исматов Самандар