the dark
i have collected static file but it not working
Aadhi
Guys, can we add additional fields to USER table
.
Guys, can we add additional fields to USER table
You can make your own User model, based on AbstractUser or AbstractBaseUser. Google it
.
Guys, can we add additional fields to USER table
or you can make Profile model with 1:1 relationship to the User model, if you by any resasons cannot drop current User model
Aadhi
Let me Google it . Thank you so much
Shubham
Hi All.. can anyone have an idea that how can we implement basic Auth in Django rest swagger.?
Alibek
Hi everybody. I have an issue. I want to make formula editor on django. I have 3 models Formula, Indicator, Unit. All binded by FK. Indicator is like a variable with measure unit (which is Unit model). On frontend user creates such formula: Indicator1 * 100% / Indicator2, saves it (as TextField). Then other users use this formula for own calculation and they use described above formula, How can I represent formulas as inputs like <input id="indicator1" type="text"/> * 100% / <input id="indicator2" type="text"/>
Modou-dev
is DRF accept thread?
Rammanoj
can you be more precise ?
Modou-dev
do I need to use thread in my django rest framework when I do a post request whitch has 2 serializer class?
Rammanoj
do I need to use thread in my django rest framework when I do a post request whitch has 2 serializer class?
I guess there is no need, you can make a serializer relation and use them
Modou-dev
So just when to launch my request in one time
Rammanoj
So just when to launch my request in one time
did not get you 😅😅, why do you want to use threads when making a post request
.
not threaded
007
TypeError: 'QueryDict' object is not callable https://dpaste.de/WYsQ#L
Modou-dev
ok
Modou-dev
https://dpaste.de/HAa5
Modou-dev
https://dpaste.de/HAa5
here is my thread method and the view where I call it
Rammanoj
TypeError: 'QueryDict' object is not callable https://dpaste.de/WYsQ#L
may be try replacing image = request.POST.get('image') with image = request.POST.get[image']
cj
do I need to use thread in my django rest framework when I do a post request whitch has 2 serializer class?
why are you still trying to do that? we told you a couple of days ago not to do that 🤷🏻‍♂️
Anonymous
Guys any idea about make Todo app in django!!!?
Anonymous
cj
What ??
that was my thought when I read your post
Anonymous
But why??
cj
But why??
I thought that too
Anonymous
I thought that too
My college project but I don't know from where to start any help??!!
Anonymous
Hi everyone
Modou-dev
I need a helper here https://dpaste.de/OCxB#L
Modou-dev
where is the traceback?
https://dpaste.de/2scF
cj
I need a helper here https://dpaste.de/OCxB#L
also at line 49 you're returning the function definition, not the function result 🤷🏻‍♂️
cj
how can I handler that
return run() 🤷🏻‍♂️
Modou-dev
cj
are you obsessed with using threads? do you know you're shooting your feet?
cj
I'm a new in the threads
then don't use them 🤷🏻‍♂️
Modou-dev
then don't use them 🤷🏻‍♂️
okay I see I have a problem with
Modou-dev
and my manager tell me to use thread
cj
and my manager tell me to use thread
oof.... 🙄🤷🏻‍♂️
Modou-dev
I'm so borring now
Rohan
That's a nice reason to use threading
Rohan
why ?
EXACTLY!
Rohan
That's the question you should be asking your manager
Modou-dev
okay I see
Modou-dev
I should ask him what he is waiting for
007
Exception Value: Object of type InMemoryUploadedFile is not JSON serializable. I want to pass image as parameter to API but it shows an error. link :- https://dpaste.de/84xD
007
Yeah but i have used data=json.dups(payload)
007
Where payload is image
cj
Yeah but i have used data=json.dups(payload)
your payload doesn't contain plain text values 🤷🏻‍♂️ it has a InMemoryUploadedFile, that's why
cj
tip: encode your image to base64
cj
Where payload is image
exactly that is the problem
007
exactly that is the problem
How can we assign image as parameter to api
cj
How can we assign image as parameter to api
I told you somewhere up there 👆
.
Very bad situation)
cj
just keep in mind JSON accepts only plaint text, nothing else
.
I'm trying to understand how he came to the threads
007
just keep in mind JSON accepts only plaint text, nothing else
Ok... Trying to convert image into base64
.
From which logic
.
😂
.
Just use threads! Even if you don't need it - find a reason and use it
007
just keep in mind JSON accepts only plaint text, nothing else
But while testing that api in postman it accept the image as a parameter
Anonymous
Which hosting do you acvice for django?
Anonymous
Im using webfaction, its very simple, and include they have email support
Anonymous
I need a shared hosting like webfaction
Anonymous
Which hosting do you suggest?
Anonymous
why shared?
I need to have min server development
Anonymous
Hi
Anonymous
What is the best hosting provider to host django based rest API