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xqsFxnAhnecjdMCv/TJLXMNk9LihEeUEZo
4U7bitCfyO17dt6NC/7wbGZCJmNPO7V3YYeI8MwzOkvmXqLcHz0IPQATuLMB1HKr
oG/Vrwq029ftqnuDluS/DzmuIqWLuAT+2nIe1JLWFlS9OUTi4i+y0NDlxWCZOaGp
ucR+ueFKv1de3nVjdd6oN+MIO9gQ3NE53FrO46A3APy6Ex02Mxub8nNnQjXcStHZ
BHO6KilQ+QLzSektD8IpHM7tR6P+5PP6AQ==
=NePe
-----END PGP PUBLIC KEY BLOCK-----
On 07/06/2022 06.59, Mukul Verma wrote:
> yeah i was saying in Django Thanks Everyone please tell me something in
> steps for this like how to use session variable in django and can create
> session currently i am able to generate token (access and refresh) and
> further need to create session with this.
>
https://docs.djangoproject.com/en/4.0/topics/http/sessions/
Kind regards,
Kasper Laudrup
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/0bb76cb7-85e8-129f-2a86-2817506e7c0a%40stacktrace.dk.
Tuesday, June 7, 2022
Monday, June 6, 2022
Re: Session in Python for Login and Logout
yeah i was saying in Django Thanks Everyone please tell me something in steps for this like how to use session variable in django and can create session currently i am able to generate token (access and refresh) and further need to create session with this.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/41e0599f-6f42-4a1a-a8d0-cf51d8ad5a30n%40googlegroups.com.
Thanks
On Tuesday, 7 June 2022 at 08:10:44 UTC+5:30 juw...@gmail.com wrote:
I think what he meant is 'session' in django.Probably can take a look at this: https://docs.djangoproject.com/en/4.0/ref/request-response/For example, django app wants to know who is the current user, can use something like:`request.user`On Mon, 6 Jun 2022 at 22:45, 'Kasper Laudrup' via Django users <django...@googlegroups.com> wrote:On 06/06/2022 11.16, Mukul Verma wrote:
> Hii,
>
> Help me out in this stuff please, some steps for solve this out
>
Python is a programming language so there's no such thing as a "session
for login and logout".
If you want someone to help you, you should try to clarify what you
actually need help with. I assume you mean something with Django
sessions but it's impossible for me or anyone else to know exactly what
kind of issue you need to solve.
Kind regards,
Kasper Laudrup
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/ade6fd19-d942-f5e9-dc9e-1f921d94b648%40stacktrace.dk.
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/41e0599f-6f42-4a1a-a8d0-cf51d8ad5a30n%40googlegroups.com.
Re: uvicorn and ASGI
Hi Dan.
Your question interested me so I went looking. The page you link to further links to the uvicorn documentation which seems to indicate their suggestion for production deployments is to use gunicorn and the uvicorn worker.
Their rationale seems to be that uvicorn is great at running an event loop and operating asynchronously but the worker process management including increasing and decreasing them and hitless upgrades were managed by gunicorns more mature features here.
The way I am conceptualising the core benefit here is multi core machines where workers can be thrown into different process threads to utilise all available cores while the asynchronous benefits improve parallelisation of requests where applied to reduce time to run particular views to completion. So they work together for best effect.
https://www.uvicorn.org/#running-with-gunicorn
Regards
Alexander
Alexander Neilson
Neilson Productions Limited
021 329 681
alexander@neilson.net.nz
On 6/06/2022, at 16:06, Dan Davis <dansmood@gmail.com> wrote:
I am doing some work comparing various ASGI frameworks, SQL Alchemy, just writing the SQL, and that sort of thing, in order to determine what I think. Speed isn't every thing, but speed is a thing.Anyway, I was reading about this at https://docs.djangoproject.com/en/4.0/howto/deployment/asgi/uvicorn/ and it is curious that the advise is to run uvicorn as a work rather than a full ASGI server. Can someone explain why this is necessary or better?Thanks,-Dan--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/5dbf8350-1c28-4eb1-a3c8-f3a06566a06dn%40googlegroups.com.
Sunday, June 5, 2022
Re: Best approach for audit logging in Django.
i also have the question regarding this, is that i have to create auditing log file for all the activities performing in the project smallest or biggest may you please tell how to initiate this task from beginning.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/415a6eee-74b2-4cbf-b708-2ff15091aeecn%40googlegroups.com.
Thanks
Mukul Verma
On Friday, 3 June 2022 at 23:32:04 UTC+5:30 sutharl...@gmail.com wrote:
Hi Sencer, signals will be helpful only if you are auditing on certain modelsbut if you are trying to audit a set of views then middleware will be a better choice since that will be more manageableOn Fri, 3 Jun 2022 at 18:29, Jason <jjohn...@gmail.com> wrote:one good source when you have a question "is there anything in django that does X?" is to go to djangopackages.org.https://djangopackages.org/grids/g/model-audit/, for example, is a list of packages for model auditing and historyOn Friday, June 3, 2022 at 6:33:37 AM UTC-4 sencer...@gmail.com wrote:Hi,I've been planning to add audit logging to the project.But, I can not decide which approach is the best;Using signals or creating middleware?Project needs to being log events on change of model object with these informations below:- If a record is inserted, updated and deleted:- who is taking this action (ForeignKey)- what is the action (Choice)- which applications model object affected (ContentType)- affected object (Generic relation)- current data in json format- previous data in json formatKind regards,Sencer HAMARAT--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/f5586723-4e6a-4ce6-93d9-b74cd277dc91n%40googlegroups.com.
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/415a6eee-74b2-4cbf-b708-2ff15091aeecn%40googlegroups.com.
Re: Nested json in django rest framework
Thanks for your time I've learnt something new from your message and I solved the problem yesterday itself it was my mistake I added the wrong model to serializer
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/1e14a36d-0960-4083-a208-9396340c3912n%40googlegroups.com.
On Sunday, 5 June 2022 at 23:15:47 UTC+5:30 Kasper Laudrup wrote:
On 05/06/2022 07.06, Koushik Romel wrote:
> I want those #One and #Two to be in curly braces {} and not as square
> bracket [] , and Thanks in advance
A good start would be to understand what the difference between square
brackets and curly braces is. The JSON format is very simple:
https://en.wikipedia.org/wiki/JSON#Syntax
So you actually want to convert your array to an object with anonymous
properties/members. That doesn't really make any sense and wouldn't be
valid JSON.
Of course you could write a dirty hack and do it anyway but I seriously
doubt that's really what you want.
Hope that helps.
Kind regards,
Kasper Laudrup
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/1e14a36d-0960-4083-a208-9396340c3912n%40googlegroups.com.
Re: ComboBox
Thanks for the responses.
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/cdd3deef-3f9b-401b-b7df-864848d09086n%40googlegroups.com.
rgam - I appreciate what you are saying. I think it is roughly what I am doing now, but it is a bit clumsy in that the user (of a financial application) will typically have a list of regular customers to select from, and also may have other customers that are one-off, or infrequent which they will not want to clutter their options list with but still need to record against a transaction.
Ryan - thanks, the datalist looks like it might be right option. I will look at custom widgets.
All the best - Phil
On Wednesday, 1 June 2022 at 09:13:11 UTC+1 rgam...@gammascience.co.uk wrote:
HiIf any arbitrary text is allowable, then at the model level I'd just use a CharField. I wouldn't add a choices= argument to the field unless is the value is strictly constrained to those choice as other test would then fail validation.At the Form level, I'm not sure. I'd probably work just mirror what the frontend needed.Does that help ?On Tue, 2022-05-31 at 09:52 -0700, Phil Parkin wrote:Hi all
I am converting a desktop application to Django web application. The desktop app uses comboboxes (editable dropdown/select). Is their any elegant way of applying the same functionality in Django? Stack Overflow etc. all seem to be about dropdown select lists only.
I can see ways of doing this with a Choicefield plus a separate Charfield, but is there a better way?
Thanks -Phil
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/1b7836ae-e52e-4e35-aefc-739ce6f586d0n%40googlegroups.com.
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/cdd3deef-3f9b-401b-b7df-864848d09086n%40googlegroups.com.
Saturday, June 4, 2022
Re: ComboBox
The HTML element you probably want is a datalist[1]. There's no built-in Django support for datalist[2] so you'll probably need to create a custom widget.
[1] https://stackoverflow.com/a/14614750
[2] https://code.djangoproject.com/ticket/32125
[1] https://stackoverflow.com/a/14614750
[2] https://code.djangoproject.com/ticket/32125
On May 31, 2022 11:52:31 AM CDT, Phil Parkin <philparkin2611@gmail.com> wrote:
Hi all
I am converting a desktop application to Django web application. The desktop app uses comboboxes (editable dropdown/select). Is their any elegant way of applying the same functionality in Django? Stack Overflow etc. all seem to be about dropdown select lists only.
I can see ways of doing this with a Choicefield plus a separate Charfield, but is there a better way?
Thanks -Phil
Subscribe to:
Posts (Atom)