Re: Improvements to the startproject template

2022-04-21 Thread Albert
It is possible to do in current version of Django with two lines of code:mkdir my_projectdjango-admin startproject config my_projectI have been working for many companies that use Django and I have seen that each ot them has their own structure of project. And usually project is created once

RE: Adding Support for DB Views

2022-02-22 Thread Albert
Hi,I am using the same approach, migrations with RunSQL and model and in most cases it is working well.Introduction of supporting views is easy at a first glance. But when you think more then it is not so easy. People would see the view in admin panel, but admin panel is based on an idea that

adding permission_required decorator for class based view

2022-02-09 Thread Albert
Hi,For class based views there are mixins, LoginRequiredMixin, PermissionRequiredMixin which give the same

Deprecation of using pk in public ORM API

2022-02-02 Thread Albert
Hi Daryl,I agree and disagree with you, it depends on place and context of using "pk" alias :)I am not sure if it is good in filter and as object attribute. For our internal use we could use "_pk" or other name.You motivated me to check one thing.class Car(models.Model): pk =

Proposal of standardize of reverse foreign key and m2m

2022-02-02 Thread Albert
e query there is empty QuerySet returned. Proposal is to raise error instead return empty QuerySet in Foreign Key like M2M does. Albert -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from

Re: Deprecation of using pk in public ORM API

2022-02-01 Thread Albert
Thank you for response.Now i see that it is not so easy as I thought.It is used in many other places in Django and probably also in django rest framework and other third parties libraries. -- You received this message because you are subscribed to the Google Groups "Django developers

Deprecation of using pk in public ORM API

2022-01-27 Thread Albert
ed to do extra work to support it. I think that "pk" could be only a private attribute of a model ("_pk") and only for internal use or avoid using it at all. I think it would give us more flexibility to develop/improve orm. What do you think? Regards, Albert Defler -- You receiv

Re: DEPs: Django Enhancement Proposals

2014-04-14 Thread Albert O'Connor
gt; > > -- > "I disapprove of what you say, but I will defend to the death your right > to say it." -- Evelyn Beatrice Hall (summarizing Voltaire) > "The people's good is the highest law." -- Cicero > GPG Key fingerprint: 125F 5C67 DFE9 4084 > > -- > You rece

Re: Working towards a simpler GCBV implementation?

2013-10-05 Thread Albert O'Connor
tion. Thanks, Albert O'Connor On Sat, Oct 5, 2013 at 7:27 AM, Tino de Bruijn <tin...@gmail.com> wrote: > > On Thu, Oct 3, 2013 at 11:09 AM, Tom Christie <christie@gmail.com>wrote: > >> * If a simpler GCBV implementation along the lines of >> django-vanilla

Re: Featurereuqest: Helpfull tracebacks

2013-08-21 Thread Albert O'Connor
rather vague and could be more helpful, but not if it requires hacks. You can look into the values of variables in the rather long stacktrace to figure out what is happening. Albert > -- > You received this message because you are subscribed to the Google Groups > "Django devel

Re: Changes to django's settings module

2013-03-24 Thread Albert O'Connor
of an up hill battle where the onus is on the contributor at every stage, not the project maintainers. Albert O'Connor On Sun, Mar 24, 2013 at 7:10 AM, Russell Keith-Magee < russ...@keith-magee.com> wrote: > > On Sun, Mar 24, 2013 at 6:28 PM, Omer Katz <omer.d...@gmail.com&g

Re: Django's CVB - Roadmap?

2012-06-05 Thread Albert O'Connor
won't know what the get does. I can imagine use cases exist where CBV make sense, but they seem to be instances where customization and testing are critical which points me back to library views explicitly meant for reuse, not every day business logic heavy views. Albert On Tue, Jun 5, 2012 at 11:33

Re: Django's CVB - Roadmap?

2012-06-05 Thread Albert O'Connor
cept many for the one your provide in your distinct use case. It should be noted a vast majority of views that developers write which aren't "generic" will never ever be reused and thus probably should be CBV. Albert On Tue, Jun 5, 2012 at 10:46 AM, Donald Stufft <donald.s

Re: Django's CVB - Roadmap?

2012-06-05 Thread Albert O'Connor
providers would have made more sense than mixins. If people have uses for CBV, they should be available, but advocating that more builtin or contrib views should be made class based is something I would be against personally, unless it really made sense in a specific use case. Albert O'Connor

Re: Django 100% threadsafe with DB?

2007-09-26 Thread Istvan Albert
On Sep 25, 10:58 pm, Graham Dumpleton <[EMAIL PROTECTED]> wrote: > ensure there own code is multithread safe, but now again someone is > saying that Django itself is not multithread safe. :-( Well, I was just repeating the what I heard from the developers. Not so long ago a proposal was made

Re: Django 100% threadsafe with DB?

2007-09-25 Thread Istvan Albert
Django is 0% threadsafe (as in nada, null or zilch) it is not supposed to be run that way, but if you must keep locking around every operation. i. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Django

Re: Newforms: colon after label

2007-03-29 Thread Istvan Albert
I think the OP is correct, if you want the label to end with a colon ... then add the colon to the label. It doesn't get any simpler than that. Any other solution just gets in the way. i. --~--~-~--~~~---~--~~ You received this message because you are

Re: django documentation - editing

2007-03-27 Thread Istvan Albert
On Mar 25, 8:06 pm, Malcolm Tredinnick <[EMAIL PROTECTED]> wrote: > I fear that one day I will achieve that and will then be asked to leave > the safety of the monastery and journey the world righting injustice in > episodic television format... that is quite funny ... one more reason to read

a simple patch for streaming uploads

2007-02-05 Thread Istvan Albert
There is ticket (and a patch) for enabling streaming uploads, but it seemed a little complicated and until it gets accepted (or reworked) here is nice workaround to do the same. See patch at the end. It is backward compatible, the current behavior stays the same, you can use still request.FILES

Re: Django with CherryPy 3.0

2007-01-22 Thread Istvan Albert
Jeremy Dunck wrote: > That said, most of the time, this is good stuff. Perhaps a management > option to turn it off? My understanding is that no part of basehttp.py is used when Django is deployed via modpython. If that is correct then this addition would make no difference in a production

Re: Django with CherryPy 3.0

2007-01-22 Thread Istvan Albert
There is an easy way to turn on multi-threading for the default server, see the diff below: Index: basehttp.py === --- basehttp.py (revision 4183) +++ basehttp.py (working copy) @@ -7,10 +7,16 @@ been reviewed for security

Re: Call for comment: Forms/manipulator replacement, take 1

2006-10-27 Thread Istvan Albert
>{{ form.message.errors }} >Message: {{ form.message }} A very common use case is to format/highlight the error message or input area upon error. I can already see myself extending the Form class to include something of the sorts {{ form.message.errors }} Message: {{ form.message }}

Re: Convince us to continue using setuptools

2006-08-03 Thread Istvan Albert
Never really understood why you needed this in the first place. The automatic setuptools installation has caused me some grief as it installs an obsolete version ... I forgot the exact specifics but it took me quite a while to track down that installing django was causing all kinds of strange

Re: Connections not being closed in m-r

2006-04-05 Thread Istvan Albert
> I don't understand how the traceback module ends up being None > Adding a check for None will make the warning message go away fixing up code to make a mysterious error message go away is vey very suboptimal (ok ... so I've done I it myself a few times as well ...)

Re: HttpResponse with file-like objects

2006-04-02 Thread Istvan Albert
> just can't imagine any practical application of this... suppose one wants to return content created by two generators ... they could wrap it themselves into a single one but why not write it both to the response and let that iterate thru each, if your code would support that it would end up

Re: HttpResponse with file-like objects

2006-04-02 Thread Istvan Albert
but it is not an arbitraty iterator one is writing to, it is the the HttpResponse, why couldn't it handle new content being added just because some content is present as an interator? once it exhausts the original iterator it could continue on (if new content was added after it) or why not let

Re: HttpResponse with file-like objects

2006-04-01 Thread Istvan Albert
Two observations: 1. It is hard to believe that Django does not already do this ... it is somewhat depressing to see that trivial behavior such as streaming output was never implemented 2. I'm commenting here as an outsider, but looking at the patch it seems that the _is_string attribute is

Re: Streaming uploads to temp files

2006-03-26 Thread Istvan Albert
> But I have concerns about performance in the common case. File upload is inherently a slow process strictly limited by the connection speed so it is not clear that any kind of performace problems would be noticable at all (even if there were such problems) Loading files into memory is

Re: ANN:DjangoInstall package 0.1 released

2006-02-08 Thread Albert Lee
wonderful2006/2/9, limodou <[EMAIL PROTECTED]>: I'm very pleased to announce that DjangoInstall package 0.1 released.=Django Install Package=:Author: limodou ( [EMAIL PROTECTED]):Blog: http://www.donews.net/limodou:Date: