223 rows where "changetime" is on date 2009-02-25

View and edit SQL

Suggested facets: changetime, stage, component, severity, version, resolution, owner, has_patch, needs_better_patch, needs_tests, needs_docs, created (date), last_pulled_from_trac (date)

changetime (date)

  • 2009-02-25 · 223
id ▼ created changetime last_pulled_from_trac stage status component type severity version resolution summary description owner reporter keywords easy has_patch needs_better_patch needs_tests needs_docs ui_ux
903 2005-11-24 23:01:02 2009-02-25 19:58:49 2019-06-24 00:24:53.620536 Unreviewed closed contrib.auth enhancement minor master fixed change login_required The way it is now the login_required decorator only redirects to /accounts/login I want to be able to change this so I don't have to change my mod_python settings just to make /accounts urls handled by Django. adrian Dagur decorators login_required login_url 0 1 0 1 0 0
1642 2006-04-15 08:12:02 2009-02-25 19:51:44 2019-06-24 00:32:42.355160 Design decision needed closed Database layer (models, ORM) enhancement normal master duplicate a directory option for FilePathField, or a DirPathField I would like to use FilePathField to return a list of directories. Alternatively, a DirPathField could be created that works just like FilePathField but on directories and not on files... nobody frank.hoffsummer@gmx.de fs-rf 0 1 0 0 0 0
2553 2006-08-17 04:45:10 2009-02-25 19:51:44 2019-06-24 00:42:24.448651 Design decision needed closed Generic views enhancement normal master wontfix Generic views should support serialization Pretty much what the title says. Given that we have serializers for QuerySets, and that we're shipping simplejson, it'd be nice if generic views could respond in formats other than HTML; perhaps an additional `format` keyword argument (defaulting to 'html') could be used to control this. jacob James Bennett <ubernostrum@gmail.com>   0 0 0 0 0 0
3553 2007-02-22 22:53:50 2009-02-25 19:51:44 2019-06-24 00:53:04.001182 Design decision needed closed Core (Other)     0.95 wontfix urlpatterns uses urllib.quote/unquote should use urllib.quote/unquote_plus When using the + character to represent spaces in urls it is impossible to differentiate between a literal + and an escaped %2B in the url. Example {{{ urlpatterns = (r'/search/(?<query>.*)$,app.search) }}} {{{ def search(request, query): print "query: "+query }}} Observed Visiting http://example.com/search/foo%2B+bar causes django to print foo++bar Expected Visitin http://example.com/search/foo%2B+bar should cause django to print foo+ bar Solution I assume that django is using urllib.quote/unqoute Changing it to use urllib.quote_plus and urllib.unqoute_plus would produce the expected behavior and not have any side affects graham_king justin-django@qunu.com sprintsept14 0 0 0 1 0 0
5888 2007-11-07 13:43:19 2009-02-25 19:51:44 2019-06-24 01:18:16.468357 Accepted closed Testing framework     master fixed Add head, options, put, delete to test Client To aid in unit testing RESTful interfaces I've added methods to the HTTP Client to support HEAD, OPTIONS, PUT and DELETE. No tests. leahculver Scott Barr <scott@divisionbyzero.com.au> Client 0 1 0 1 1 0
6398 2008-01-16 23:08:47 2009-02-25 19:51:44 2019-06-24 01:23:46.238193 Accepted closed Template system     master fixed Add optional {% default %} clause to {% for %} template tag As [http://simonwillison.net/2008/Jan/16/django/ requested by Simon] I propose an {{{{% else %}}}} tag for the {{{{% for %}}}} template tag which could be used like this: {{{ from django.template import * >>> t1 = Template(""" {% load mytags %} {% for athlete in athlete_list %} {{ athlete }} {% else %} No athlete in list! {% endfor %} """) >>> c1 = Context( {'athlete_list': ['me', 'myself', 'I'] }) >>> t1.render(c1) u'me myself I ' >>> c2 = Context({}) >>> t1.render(c2) u'No athlete in list!' }}} For a standalone version look at http://www.djangosnippets.org/snippets/546/ jezdez jezdez easy-pickings 0 1 0 0 0 0
6484 2008-01-28 16:08:37 2009-02-25 19:51:44 2019-06-24 01:24:42.650907 Design decision needed closed Uncategorized     master wontfix Add default mime.types for Windows systems Use local mime.types for Windows systems, since they usually don't have one installed, and the default types are not really exhaustive. Note: the included mime.types file is taken from a Debian system. It should be fairly complete. nobody Bastian Kleineidam <calvin@debian.org>   0 1 0 0 0 0
6652 2008-02-24 02:37:59 2009-02-25 19:51:44 2019-06-24 01:26:31.016160 Design decision needed closed Forms     master fixed Allow 'clean()' to specify the wrong field Currently the {{{Form.clean()}}} method has no way to specify which field is invalid, but it's the only place where validation involving many fields can be accomplished. Taking your example in the documentation: ''This is where you might put in things to check that if field A is supplied, field B must contain a valid email address and the like. '' If the field B doesn't contain a valid email address, the error message should appear next to the B widget, not at the top of the form. An easy fix is to add a 'field' optional attribute to the {{{ValidationError}}} and use it if provided. I already used this method in other programs of mine (my exception class was called {{{ValidationError}}} too!) nobody Daniele Varrazzo <piro@develer.com> feature 0 1 0 0 0 0
6791 2008-03-16 21:13:11 2009-02-25 19:51:44 2019-06-24 01:28:04.273968 Ready for checkin closed contrib.sessions     1.0 fixed Cached DB Session Backend Right now, I consider the "cache" session backend to be broken, especially when used with the memcached session backend. In a large memcached environment, servers enter and leave the memcached pool frequently. Each time this happens, the pool mapping changes and automatically logs users out (and loses their session data). Attached is a new backend which is basically a copy of the DB session backend with a django.core.cache wrapper on accesses to the session data; all writes are write through to the database and cache and all reads come from memcache except in case of a memcache failure when it reads from the database. jacob jhenry   0 1 0 0 0 0
6873 2008-03-24 21:08:38 2009-02-25 19:51:44 2019-06-24 01:28:59.214169 Design decision needed closed Forms     master wontfix Make rendering of SelectMultiple consistent across browsers At the moment the SelectMultiple widget renders without a size attribute. This is ok in Firefox as this browser simply increases the number of visible lines to match the actual number of choices till it reaches 21 or so. IE7 simply displays 4 lines regardless of the number of choices. Opera uses ''one'' line by default. Needless to say this makes the widget even more unusable than it is anyway. One has to scroll and then ctrl+click. The attached patch changes the render() function to add a size attribute by default that is equal to the number of choices but smaller than 10. Making the display (and usability) equal on all browsers. The place where this is the biggest problem for me at the moment is the multiple select widget for user groups in the admin. But I believe this is a general problem with the SelectMultiple widget. nobody jarrow   0 1 0 0 0 0
7000 2008-04-09 21:13:41 2009-02-25 19:51:44 2019-06-24 01:30:20.624218 Design decision needed closed Core (Other)     master wontfix Provide option to automatically open development server URL with webbrowser (std lib) I think it would be a very useful addition in the daily development work to have an option that opens the URL of the develeopment server in the default system browser. For example [http://mg.pov.lt/restview/ restview] makes use of Python's [http://docs.python.org/dev/library/webbrowser.html webbrowser module] that is used in the attached patch. jezdez jezdez browser command runserver 0 1 0 0 0 0
7014 2008-04-14 01:41:23 2009-02-25 19:51:44 2019-06-24 01:30:30.978017 Design decision needed closed Forms     master fixed Newforms dates crash for < year 1900 See below trace. Fair enough dates before 1900 aren't supported, but they should raise a ValidationError rather than a ValueError, so the app doesn't fall over. {{{ Traceback (most recent call last): File "/home/littlealma/lib/python2.5/django/core/handlers/base.py", line 82, in get_response response = callback(request, *callback_args, **callback_kwargs) File "./matrix/register.py", line 68, in _get_order File "./matrix/register.py", line 140, in reg_agent File "/home/littlealma/lib/python2.5/django/newforms/models.py", line 56, in save_instance instance.save() File "./matrix/models.py", line 1088, in save File "/home/littlealma/lib/python2.5/django/db/models/base.py", line 233, in save db_values = [f.get_db_prep_save(raw and getattr(self, f.attname) or f.pre_save(self, False)) for f in non_pks] File "/home/littlealma/lib/python2.5/django/db/models/fields/__init__.py", line 547, in get_db_prep_save value = value.strftime('%Y-%m-%d') ValueError: year=1234 is before 1900; the datetime strftime() methods require year >= 1900 }}} nobody Simon Litchfield <simon@quo.com.au> newforms dates datetime date year 1900 0 1 0 0 0 0
7310 2008-05-26 18:15:56 2009-02-25 19:51:44 2019-06-24 01:33:42.361960 Design decision needed closed *.djangoproject.com       fixed Change Trac encoding to UTF-8 Django translation files are difficult to read in the Trac browser because non-ascii characters are not displayed correctly ([http://code.djangoproject.com/browser/django/trunk/django/conf/locale/es/LC_MESSAGES/django.po#L1611 example]). I believe that changing the encoding set in [wiki:TracIni#trac trac.ini] will fix the problem (at least that fixed it on my Trac installs), i.e.: {{{ [trac] ... default_charset = utf-8 ... }}} nobody benspaulding trac encoding utf-8 0 0 0 0 0 0
7398 2008-06-09 14:57:09 2009-02-25 19:51:44 2019-06-24 01:34:38.987335 Accepted closed Core (Cache system)     master fixed Making it easier to add custom cache backends I ran into an inconvenience with the Django cache. I wanted to add my own custom cache backend without having to muck about with the Django core. This proved to be a bit challenging since the backend importer uses a complete path to the module (e.g. "django.core.cache.backends.memcached"). I did a small patch which lets you define extra backend modules without touching the Django folder. Essentially it uses the BACKENDS dictionary in core/cache/__init__.py to keep information about the full import paths, like this: {{{ BACKENDS = { # name for use in settings file --> path to the backend module 'memcached': 'django.core.cache.backends.memcached', 'locmem': 'django.core.cache.backends.locmem', 'file': 'django.core.cache.backends.filebased', 'db': 'django.core.cache.backends.db', 'dummy': 'django.core.cache.backends.dummy', } if hasattr(settings, "CACHE_BACKEND_MODULES"): BACKENDS.update(settings.CACHE_BACKEND_MODULES) }}} So if I wanted to add a new backend in my project, I'd do something like: settings.py: {{{ CACHE_BACKEND_MODULES = { 'penandpaper': 'backends.cache.penandpaper' } }}} and place the backend in my_app/backends/cache/. There has been a bit of talk about it lately on the developer mailing list: http://groups.google.com/group/django-developers/browse_thread/thread/e0fbaff909c44336 nobody lau@iola.dk   0 1 0 0 0 0
7484 2008-06-17 16:44:53 2009-02-25 19:51:44 2019-06-24 01:35:34.762931 Design decision needed closed Tools     newforms-admin wontfix Per user permissions Hello, I was building my own admin zone as the admin doesn't have the features I needed for some projects. Basically, I needed to manage a tree structure of models where each object had a user owner. {{{ class Library(models.Model): user = models.ForeignKey( User ) name = models.CharField(max_legth=255) class eAdmin: constraints = {'user':'request.user',} user_field = 'user' class Book(models.Model): library = models.ForeignKey(Library) title = .. pages = ... class eAdmin: constraints = {'library':'parent',} user_field = 'user' class Chapter(models.Model): book = models.ForeignKey(Book) number = ... class eAdmin: constraints = {'book':'parent',} user_field = 'user' }}} The eAdmin was similar to the Admin application of Django but the templates look like: ||Library name||Relations|| ||My library||Book - ... || If you click book the list would be like: ||Book name||Relations|| ||The Django Book||Chapters - ... || I haven't finished it yet, but it's usable, and as nfa is heavily developed, I thought it might be interesting. I just open this ticket to evaluate the idea, and if it's accepted I'll be happy to help, although I understand with the roadmap there is no much time to implement more things. Anyway, I prefer to have this in the nfa rather than create a custom eAdmin myself. The app checks the permissions that the user have before creating/editing/deleting anything. Also if we have this data: * User1 * Library1 * Book1 * Chapter1 * Chapter2 * Book2 * User2 * Library2 * Book3 * Chapter3 * Chapter4 * Book4 When a user tries to add/edit/delete an object the eAdmin always checks if that object belongs to the user recursively (user_field = 'user'). For example, if we are user2 and we hack the url to delete Chapter1, the app tries to find a field with name: 'user' in Chapter, if is not found, in Book, and finally in Library. If it's found and the … nobody Adrian Ribao <aribao@gmail.com> extra features tree objects per user 0 0 0 0 0 0
7582 2008-07-01 09:07:40 2009-02-25 19:51:44 2019-06-24 01:36:38.360582 Accepted closed contrib.admin     master fixed Sorting by nullable ForeignKey In the admin site (using latest newforms-admin), it is not possible to sort a table by a ForeignKey with null=True. See this little example: {{{ class Group(models.Model): name = models.CharField(max_length=200, primary_key=True) class Person(models.Model): name = models.CharField(max_length=200, primary_key=True) group = models.ForeignKey(Group, blank=True, null=True) }}} You cannot sort Person by group here. See also http://groups.google.com/group/django-users/browse_thread/thread/f1f0e50a731834d2/3a44be2ab21e778b Patch By Karen Tracey <kmtracey@gmail.com> nobody alerades@gmail.com   0 1 0 0 0 0
7625 2008-07-03 17:51:37 2009-02-25 19:51:44 2019-06-24 01:37:06.002343 Design decision needed closed contrib.admin     master wontfix admin.list_filter should accept methods with boolean property Example: I have a model with a start_time, end_time. And a method that does something like this: def overnight(self): if self.end: if self.start.day < self.end.day: return True else: return False overnight.boolean = True It would be nice to be able to add overnight to list_filters, at least if boolean property set. nobody ashley@xthought.org   0 0 0 0 0 0
7633 2008-07-04 21:51:56 2009-02-25 19:51:44 2019-06-24 01:37:11.227568 Unreviewed closed Contrib apps     master wontfix Feature request: Admin-configurable settings interface I have a suggestion for Django's included admin framework. Essentially, it's the ability to create app settings pages that could be editable from the admin. The essential idea behind it is that there's one record per site. It can be used to configure global app settings - for example, if you're sharing your code with someone else, writing an app specifically for distribution to other users, or just want to make it easier to change things without editing your templates directly. It would be pretty simple - you just create a Model like you would normally, but in the Admin section of the Model definition, you would do something along the lines of setting a "Mode" parameter to "Settings". It would then show up under your app heading in the admin, but when you click on it, it will immediately call up the editor. After changing the settings, you'd then be able to retrieve the data somehow - maybe by using the existing Model systems, or maybe by using some sort of "Settings.<model-name>.<field-name>" setup. I would greatly appreciate it if this setting was implemented. Regards, Leaf nobody Leaf <LeafStormRush@gmail.com> db, settings 0 0 0 0 0 0
7672 2008-07-08 06:34:43 2009-02-25 19:51:44 2019-06-24 01:37:36.278691 Design decision needed closed Database layer (models, ORM)     master fixed Add filter for 'Day of week' on Date / DateTime fields It would be very useful to be able to do DB filtering based on the day of week (eg Mon, Tue, Wed). For example: {{{ Event.objects.filter(event_date__dow=3) }}} would result in SQL similar to: MySQL: {{{ SELECT [select query etc here] WHERE DAYOFWEEK(event_date) = 3; }}} PostgreSQL: {{{ SELECT [select query etc here] WHERE EXTRACT(DOW FROM event_date) = 3; }}} Oracle: {{{ SELECT [select query etc here] WHERE TO_CHAR(event_date,'D') = '3'; }}} I have tested the syntax of MySQL's DAYOFWEEK() and Postgres' EXTRACT(DOW) functions. I don't have access to Oracle to check the syntax of the above queries. I assume SQLite will need a wrapper function similar to what's used for {{{__month }}} et al right now. Unsure at this stage of best way to handle different locales where the start date may change between Sunday/Monday/other, or different database systems assuming a week start day. The attached patch is my intitial draft. It has been tested in both MySQL 5.0 & PostgreSQL 7.4. Oracle is untested, and I haven't yet figured out the SQLite code. I have a concern the Oracle code will bomb out due to TO_CHAR returning a char, and the Django ORM tries to compare it to an integer. '''References:''' MySQL Date Ref: http://mysql-tips.blogspot.com/2005/04/mysql-date-calculations.html Postgres: http://www.postgresql.org/docs/8.0/interactive/functions-datetime.html Oracle: http://download.oracle.com/docs/cd/B28359_01/olap.111/b28126/dml_functions_2113.htm nobody rossp   0 1 1 0 0 0
7686 2008-07-09 10:40:01 2009-02-25 19:51:44 2019-06-24 01:37:45.026106 Ready for checkin closed contrib.localflavor     master fixed Add Austrian localflavor Patch to add AT (austria) module to django.contrib.localflavor: ATZipCodeField, ATStateSelect. nobody bernd   0 1 0 0 0 0
7688 2008-07-09 13:48:41 2009-02-25 19:51:44 2019-06-24 01:37:46.269715 Design decision needed closed contrib.admin     newforms-admin invalid newforms-admin: need mechanism for further modifying a newly saved object after it has been saved ModelAdmin.save_add(...) creates a new_object and then returns an HttpResponseRedirect(). It would be really useful if there was a hook for further modifying that object after it had been saved. It's possible to do this using a custom save() method on the model at the moment, but that has two limitations: 1. The save() method doesn't have access to a request object. Admin customisations often involve extra form stuff being passed in as part of the request. 2. You might want custom behaviour that only runs on objects created using the admin, not objects created using other means. Having a post_save_add() method that is passed the request and the newly created object and does nothing by default (but can be over-ridden in ModelAdmin subclasses) would be one way of solving this, but I'm not sure it's the best way. nobody simon   0 0 0 0 0 0
7703 2008-07-10 11:45:11 2009-02-25 19:51:44 2019-06-24 01:37:55.732197 Design decision needed closed contrib.admin     newforms-admin duplicate ModelAdmin.get_fieldsets calls ModelAdmin.get_form without the obj parameter When subclassing {{{ModelAdmin}}} to generate different forms depending on a field in an existing object or a parameter in {{{request.GET}}}, then he/she needs to override {{{ModelAdmin.get_form(self,request,obj=None)}}}. {{{ModelAdmin.get_form}} is called in multiple places but when it is called from get_fieldsets the obj parameter is not passed to the get_form function. obj=None appears in the parameter list of get_fieldsets, so the simple fix is to change from {{{get_form(request)}}} to {{{get_form(request,obj)}}} in the {{{ModelAdmin.get_fieldsets}}} function. nobody sureshkannan get_form, ModelAdmin 0 1 0 1 0 0
7744 2008-07-14 00:10:31 2009-02-25 19:51:44 2019-06-24 01:38:21.963134 Design decision needed closed Core (Cache system)     master fixed cache.add() should return result Currently, cache.add() doesn't have a documented return type and for most backends doesn't return anything useful. I think it should return ''something'', though I'm unsure as to what. For example, in the memcached libraries we call, add() returns True or False depending on whether the key gets added or not. One of the reasons behind this is so that locking can be emulated through the cache with a single add() call. Currently you'd have to add() some unique value, then get() it back out and compare the values. nobody qmanic cache add 0 1 0 0 0 0
7778 2008-07-16 08:15:49 2009-02-25 19:51:44 2019-06-24 01:38:43.933391 Accepted closed Core (Other)     master fixed Model subclasses cannot be deleted if a nullable foreign key relates to a model that relates back We use model subclasses in our application and we have come across a situation where Django gets confused when it tries to delete a model object and its related items. Our model contains a class that refers to a base/subclass model with a foreign key, and the base/subclass model in refers back to this class in turn. The example below should make this clearer. Let's say we are interested in celebrities, which are categorised into subclasses including the TV Chef celebrity subclass. Celebrities can have multiple fans, but a celebrity can have only one "greatest" fan. {{{ class Celebrity(models.Model): name = models.CharField("Name", max_length=20) greatest_fan = models.ForeignKey("Fan", null=True, unique=True) class TvChef(Celebrity): pass class Fan(models.Model): fan_of = models.ForeignKey(Celebrity) }}} With these model relationships, Django will be unable to delete the !TvChef subclass if it has multiple related Fans. If you run the test program below, it will try to nullify a non-existent column in the !TvChef database table. {{{ from subclass_deletion.models import * c1 = Celebrity.objects.create(name="Madonna") c2 = Celebrity.objects.create(name="The Queen") c3 = TvChef.objects.create(name="Huey") f1 = Fan.objects.create(fan_of=c3) f2 = Fan.objects.create(fan_of=c3) c3.greatest_fan = f1 c3.save() # You cannot delete the TvChef subclass, it fails with the error: # OperationalError: no such column: greatest_fan_id # This error occurs when it tries to run the SQL (sqlite3): # UPDATE "subclass_deletion_tvchef" SET "greatest_fan_id" = NULL WHERE "celebrity_ptr_id" IN (3) c3.delete() }}} The attached patch performs a sanity-check before Django attempts to clear related fields, and will avoid doing so if it cannot find the expected column name in the class that is the "to" destination.   James Murty foreign key 0 1 1 0 0 0
7795 2008-07-17 16:09:01 2009-02-25 19:51:44 2019-06-24 01:38:54.720260 Design decision needed closed contrib.admin     master wontfix QuerySet used instead of Admin.manager.get_queryset() this prevents me from modifying the admin search behaviour by setting a custom Manager patches for trunk and new-forms branch attached. nobody xek   0 1 0 0 0 0
7877 2008-07-21 22:25:47 2009-02-25 19:51:44 2019-06-24 01:39:47.128891 Unreviewed closed Database layer (models, ORM)     1.0 invalid incorrect ProgrammingError in IPython I ran into this today and couldn't debug it. There's something weird in the interaction between IPython (Ubuntu's version 0.8.1-2) and Django. The symptom is {{{<class 'psycopg2.ProgrammingError'>: current transaction is aborted, commands ignored until end of transaction block}}} after executing a statement that throws a ''single'' SQL error. The immediate cause of that, as looking in django.db.connection.queries confirms, is that the query is actually getting run ''twice''. It only happens when not storing the output in a variable; when the statement is an assignment, the real (original) database error is displayed. Example: {{{ In [1]: from csamoa.conceptnet.models import * In [4]: from django.db import connection In [5]: connection.queries In [6]: a=Assertion.objects.all()[0] In [7]: connection.queries Out[7]: [{'sql': 'SELECT "predicates"."id", "predicates"."batch_id", "predicates"."raw_id", "predicates"."frame_id", "predicates"."predtype_id", "predicates"."stem1_id", "predicates"."stem2_id", "predicates"."polarity", "predicates"."modality", "predicates"."score", "predicates"."created_on", "predicates"."text1", "predicates"."text2", "predicates"."creator_id", "predicates"."sentence_id", "predicates"."language_id", "predicates"."visible", "predicates"."source" FROM "predicates" ORDER BY "predicates"."score" DESC LIMIT 1', 'time': '0.005'}] In [9]: a.creator ... traceback ... execute in db.backends.util... <class 'psycopg2.ProgrammingError'>: current transaction is aborted, commands ignored until end of transaction block In [10]: connection.queries Out[10]: [{'sql': 'SELECT "predicates"."id", "predicates"."batch_id", "predicates"."raw_id", "predicates"."frame_id", "predicates"."predtype_id", "predicates"."stem1_id", "predicates"."stem2_id", "predicates"."polarity", "predicates"."modality", "predicates"."score", "predicates"."created_on", "predicates"."text1", "predicates"."text2", "predicates"."creator_id", "predicates"."sentence_id", "predicates"."language_id", "predicates"."visible", … nobody kcarnold   0 0 0 0 0 0
7879 2008-07-22 00:09:18 2009-02-25 19:51:44 2019-06-24 01:39:48.383830 Design decision needed closed Core (Other)     master wontfix reverse/url tag assumes view is a module-level callable **django.core.urlresolvers.reverse**, when called with a string argument, requires that string to reference a view inside a module, which means that the following won't work, since **site** is a class, and **admin** is the module. {{{ reverse('django.contrib.admin.site.root') }}} The faulty code is **get_callable** inside urlresolvers.py. nobody miracle2k   0 0 0 0 0 0
7894 2008-07-22 14:45:31 2009-02-25 19:51:44 2019-06-24 01:39:57.834337 Design decision needed closed Core (Other)     master duplicate Support handler optimisations for file downloads Sometimes a django app wants to return a file in a response. You can currently do this by returning the data or an iterator for the data in the content of an HttpResponse. However WSGI provides an optional mechanism for higher performance file transmission... http://www.python.org/dev/peps/pep-0333/#optional-platform-specific-file-handling ...and I imagine mod_python is capable of a similar speed up. In order to flag to the handler that the response is suitable for this speedup I suggest a new HttpResponseFileWrapper object that wraps a file like object. This response falls back to providing its content via an iterator that reads in block_size (a extra optional parameter) bytes at a time. The speedup mechanism can also use the block_size as a suggestion for reading data from the filelike object. So for example... {{{ from django.http import HttpResponseFileWrapper def view(request): return HttpResponseFileWrapper(open('foo.pdf'), block_size=8192) }}} nobody graham.carlyle@maplecroft.com   0 1 0 0 0 0
7915 2008-07-23 11:20:41 2009-02-25 19:51:44 2019-06-24 01:40:12.388789 Accepted closed Core (Other)     master wontfix Add additional exception information from validators I had some trouble figuring out exactly why my image uploads weren't working properly via the admin interface. Using the python shell and manually stepping thru the validationprocess of isValidImage() I caught some exceptions where some features of PIL were missing (decoders or somesuch). Would have been swell if the exception message instead was brought into the admin interface instead of the very generic "This isn't a valid image". nobody ejot   0 0 0 0 0 0
7929 2008-07-24 02:51:37 2009-02-25 19:51:44 2019-06-24 01:40:21.485197 Accepted closed contrib.admin     master fixed Admin code cleanup As I was browsing the contrib.admin code I found some unused/unnecessary imports, some dead code and a bad indentation. The attached patch fixes those out. nobody julien   0 1 0 0 0 0
7965 2008-07-26 00:26:38 2009-02-25 19:51:44 2019-06-24 01:40:44.621853 Design decision needed closed Documentation     master wontfix Documentation should encourage users to use double-quotes in template tags. I found out the hard way that template tags only sometimes accept single quotes (see #7295). I think we should mentioned somewhere (probably [http://www.djangoproject.com/documentation/templates/ here]) that when passing in a string, users should use double quotes at all times. nobody jashugan   0 0 0 0 0 0
8044 2008-07-30 18:24:09 2009-02-25 19:51:44 2019-06-24 01:41:39.660012 Design decision needed closed Template system     master wontfix random filter should be smarter about querysets Apologies in advance if my terminology isn't quite right, I'm new to all of this... Right now, the random filter's implementation naively chooses from the supplied list. In the case of querysets, this might be wildly inefficient -- converting the queryset into a list causes evaluation of the entire queryset, which might be fairly large. Ideally, the desired outcome is that random will simply limit the queryset to one of its elements (or None if the queryset is empty). This patch should leave existing behavior intact for everything except querysets. Patch + documentation attached. Be gentle and tell me what to do next if something is lacking. Particularly: I think I correctly did the cross-linking to the docs about limiting querysets correctly (in the templates documentation for the random filter) -- but would appreciate a check from somebody else. Due credit for this goes to bram_ and elliott on #django; I came in there to ask about "how best to choose a random element" and this cropped up. The code for the filter is bram's from pastebin. The documentation and diffwork is mine. :) nobody idangazit   0 1 0 0 0 0
8055 2008-07-31 11:20:53 2009-02-25 19:51:44 2019-06-24 01:41:46.923911 Accepted closed Core (Serialization)     master fixed Transaction error when doing loaddata I'm using MySQL 4.1 with InnoDB tables and when doing ./manage.py loaddata data.json, I get the following traceback: {{{ $ ./manage.py loaddata data.json Installing json fixture '/home/rime/www/rabakyla/packages/rime/data' from '/home/rime/www/rabakyla/packages/rime/data'. Traceback (most recent call last): File "./manage.py", line 11, in ? execute_manager(settings) File "/home/rime/www/rabakyla/packages/django/core/management/__init__.py", line 301, in execute_manager utility.execute() File "/home/rime/www/rabakyla/packages/django/core/management/__init__.py", line 248, in execute self.fetch_command(subcommand).run_from_argv(self.argv) File "/home/rime/www/rabakyla/packages/django/core/management/base.py", line 77, in run_from_argv self.execute(*args, **options.__dict__) File "/home/rime/www/rabakyla/packages/django/core/management/base.py", line 91, in execute output = self.handle(*args, **options) File "/home/rime/www/rabakyla/packages/django/core/management/commands/loaddata.py", line 157, in handle transaction.leave_transaction_management() File "/home/rime/www/rabakyla/packages/django/db/transaction.py", line 71, in leave_transaction_management raise TransactionManagementError("This code isn't under transaction management") django.db.transaction.TransactionManagementError: This code isn't under transaction management }}} I initially used MyISAM tables (which are the default), then recreated the database with InnoDB tables, but it didn't help. I also discovered that the database was using latin1 instead of UTF-8 so I recreated the tables using UTF-8 as the default encoding which made the problem go away. But what disturbs me is that Django is not giving a good error message for this. I mean, latin1 and UTF8 are not even related to transactions, and even if they are due to some implementation details, it's really hard to make the guess. So I think loaddata should give a better error message! (Running the latest revision of Django trunk… ramiro Erik Allik <eallik@gmail.com> loaddata fixtures print_exc 2.3 traceback 0 1 0 0 0 0
8081 2008-08-01 20:08:11 2009-02-25 19:51:44 2019-06-24 01:42:03.906185 Someday/Maybe closed *.djangoproject.com     master wontfix [settings.py] Permalinks to referenced resources The two external references existing in the settings.py file really should be permalinked to a resource controlled by the django-project itself: http://www.i18nguy.com/unicode/language-identifiers.html http://en.wikipedia.org/wiki/List_of_tz_zones_by_name These create a dependency upon uncontrolled resources. The links could go dead or the information could become outdated (not likely, I know). Consider providing this info on: http://djangoproject.com/languages http://djangoproject.com/time_zones A minor improvement, i know, but an easy fix just the same. These are the only examples I am aware of, but the same should go for any external resource (as far as the information is freely available). nobody snirpyor jacob 0 0 0 0 0 0
8128 2008-08-05 22:04:26 2009-02-25 19:51:44 2019-06-24 01:42:37.449753 Accepted closed Uncategorized     master fixed Contrib.syndication throwing AttributeError in latest trunk revision Here is my traceback: {{{ Traceback (most recent call last): File "/home/pbeeson/webapps/django/lib/django/core/handlers/base.py", line 87, in get_response response = callback(request, *callback_args, **callback_kwargs) File "/home/pbeeson/webapps/django/lib/django/contrib/syndication/views.py", line 19, in feed feedgen = f(slug, request).get_feed(param) File "/home/pbeeson/webapps/django/lib/django/contrib/syndication/feeds.py", line 146, in get_feed pubdate = pubdate.replace(tzinfo=FixedOffset(tzOffset)) AttributeError: 'NoneType' object has no attribute 'replace' }}} nobody patrickbeeson@gmail.com syndication contrib 0 0 0 0 0 0
8130 2008-08-06 01:11:50 2009-02-25 19:51:44 2019-06-24 01:42:38.863189 Unreviewed closed Core (Other)     master invalid url pattern resolving doesn't work for urls that have groups (ex: admin) this is the line in urls.py for admin app: url(r'^admin/(.*)', admin.site.root, name='admin_page'), i'm calling this within the template like this: {% url admin_page '' %} - django can't resolve and match the '' part.. it says: TemplateSyntaxError at /tr/blog/ Could not parse the remainder: '''' from '''' If I write any word I want (instead of '' part) in {% url admin_page '' %} then it would work fine.... nobody alperkanat   0 0 0 0 0 0
8138 2008-08-06 18:40:19 2009-02-25 19:51:44 2019-06-24 01:42:44.190007 Accepted closed Testing framework     master fixed Switch django tests to use transactions Currently the Django testsuite flushes the database after every test. That is a major performance drawback. The fixture loading/truncating takes much longer than the actual test. So I propose to switch the Django testtools to use transactions: * Before every test a transaction is started * The fixtures (if existing) are loaded * No commit is performed * The tests run * A rollback is performed There is a matching discussion on django-developers: http://groups.google.com/group/django-developers/browse_thread/thread/49aa551ad41fb919 My first tests with the concept show some promise. The first try at a patch breaks some tests (1 on SQLite, 25 on PostgreSQL), but the performance improvement is significant. With the django testsuite the results on my Laptop (slow disk - IO is the bottleneck with the tests here) so far are: * SQLite in-memory-db: * before: 415 sec * after: 79 sec * PostgreSQL: * before: 4285 sec * after: 359 sec As suggested by Russell Keith-Magee, I renamed the original test.TestCase to test.TransactionTestCase and implemented the new functionality in test.TestCase. If someone explicitly wants to use transactions inside a test, he can use TransactionTestCase and will only loose the performance gain. With the current patch all doctests now use transactional behaviour. We'll see, if I can implement a choice there, too - if it is necessary. nobody mremolt     1 0 0 0  
8215 2008-08-10 20:00:45 2009-02-25 19:51:44 2019-06-24 01:43:34.809641 Unreviewed closed Testing framework     master wontfix Tests raise UnicodeDecodeError instead of showing the test that failed This problem bit me while trying to adjust the regressionstests for #6873. Instead of reporting that [http://code.djangoproject.com/browser/django/trunk/tests/regressiontests/forms/widgets.py#L641 tests/regressiontests/forms/widgets.py, Line 641] failed it just threw this error: {{{ vm3:/home/dev/django-trunk/tests# ./runtests.py --settings settings forms ====================================================================== ERROR: Doctest: regressiontests.forms.tests.__test__.widgets_tests ---------------------------------------------------------------------- Traceback (most recent call last): File "/usr/lib/python2.4/site-packages/django/test/_doctest.py", line 2176, in runTest failures, tries = runner.run( File "/usr/lib/python2.4/site-packages/django/test/_doctest.py", line 1405, in run return self.__run(test, compileflags, out) File "/usr/lib/python2.4/site-packages/django/test/_doctest.py", line 1318, in __run self.report_failure(out, test, example, got) File "/usr/lib/python2.4/site-packages/django/test/_doctest.py", line 1185, in report_failure out(self._failure_header(test, example) + UnicodeDecodeError: 'ascii' codec can't decode byte 0xc5 in position 240: ordinal not in range(128) }}} Maybe all these Unicode strings in the tests without a small u in front need changing? I know the information in this ticket is not really exhaustive. Just let me know what would help :) nobody jarrow   0 0 0 0 0 0
8248 2008-08-12 03:46:06 2009-02-25 19:51:44 2019-06-24 01:43:57.909324 Accepted closed Core (Other)     master fixed Built-in python function, help(), does not work on models with ForeignKey fields If a model refers to a Site model, the help() function stops working, meaning functions, docstrings, etc don't print. To reproduce: {{{ $ django-admin.py startproject myproj $ ./manage.py shell >>> from django.contrib.sites.models import Site >>> help(Site) }}} This will return correct functions, docstrings, etc... Now create an app: {{{ $ ./manage.py startapp myapp }}} Create a model: {{{ from django.db import models from django.contrib.sites.models import Site class MyModel(models.Model): name = models.CharField(max_length=50) site = models.ForeignKey(Site) }}} Now try to view help for this either MyModel or Site: {{{ $ ./manage.py shell >>> from myapp.models import MyModel >>> from django.contrib.sites.models import Site >>> help(MyModel) >>> help(Site) }}} Both calls will only show something similar to: {{{ Help on class MyModel in module myproj.myapp.models: MyModel = <class 'myproj.myapp.models.MyModel'> (END) }}} Tested on SVN 8204 and 8313 - same results   lingrlongr help ForeignKey foreign key 0 0 0 0 0 0
8297 2008-08-13 22:31:50 2009-02-25 19:51:44 2019-06-24 01:44:29.616740 Unreviewed closed Template system     master wontfix Withblock template tag '''Important note''': This ticket can work only if #8296 gets checked in. Currently there is the convenient `{% with %}` tag to create variables in templates. Unfortunately there is no built-in counterpart for blocks. The attached patch does just that, with the following suggested syntax: {{{ {% withblock as myurl %} {% url path.to.some_view arg1,arg2,name1=value1 %} {% and as var %} {% whatever %} {% in %} Click the link: <a href="{{ myurl }}">link</a>. <p>{{ var }}</p> {% endwithblock %} }}} nobody julien   0 1 0 0 0 0
8300 2008-08-13 23:13:52 2009-02-25 19:51:44 2019-06-24 01:44:31.662241 Unreviewed closed contrib.syndication     master duplicate feedgenerator shouldn't use ascii to decode dates if i use some locale like '''tr_TR.UTF-8''' or any other locale, a date for the rss feed could be '''"10 Ağu"''' instead of '''"10 Aug"'''.. Therefore, I get the following error messages: UnicodeDecodeError at /feeds/latest/[[BR]] 'ascii' codec can't decode byte 0xc4 in position 9: ordinal not in range(128) I think all decoding should be done using utf-8 instead of ascii.. And by the way there's a problem in line 241 of feedgenerator.py file: handler.addQuickElement(u"pubDate", rfc2822_date(item['pubdate']).decode('links')) 'links' here should be something like ascii or especially utf-8.. nobody alperkanat   0 0 0 0 0 0
8306 2008-08-14 05:43:30 2009-02-25 19:51:44 2019-06-24 01:44:35.527517 Accepted closed contrib.admin     master fixed BaseModelAdmin.formfield_for_dbfield() in desperate need of refactor See attached patch, which moves all of the model-field-specific overrides out into a dictionary. This has the side effect of increasing customizability :) nobody ubernostrum   0 1 0 0 0 0
8319 2008-08-14 17:53:54 2009-02-25 20:06:10 2019-06-24 01:44:44.100012 Unreviewed closed contrib.admin     master wontfix limit_choices_to does not limit choices on inlined fields with intermediate tables Limiting the choices for a tabular inlined member with an intermediate class does not limit the choices. In the example below, the select elements in the admin interface include every story, not just stories which have a start date in the past. For inlined tables where there are thousands of records this can bloat admin page sizes beyond usability. In models.py: {{{ class PageContent(models.Model): stories = models.ManyToManyField('Story', limit_choices_to={'start_date__lte': datetime.now()}, through='PageContentStoryMembership') class PageContentStoryMembership(models.Model): page_content = models.ForeignKey(PageContent) story = models.ForeignKey('Story') weight = models.IntegerField(null=False, default=0) }}} In admin.py: {{{ class PageContentStoryMembershipInline(admin.TabularInline): model = PageContentStoryMembership class PageContentAdmin(admin.ModelAdmin): inlines = [PageContentStoryMembershipInline] }}} nobody TrevorFSmith   0 0 0 0 0 0
8321 2008-08-14 18:44:04 2009-02-25 19:51:44 2019-06-24 01:44:45.457591 Accepted closed contrib.auth     master fixed Use Hashcompat in contrib.auth.user nothing fancy, just simply use the new django.utils.hashcompat for the hashing in auth.user nobody magneto hashcompat 0 1 0 0 0 0
8395 2008-08-18 14:41:14 2009-02-25 19:51:44 2019-06-24 01:45:34.004794 Unreviewed closed Testing framework     other branch fixed Mein neuer Superfehler verändert Wenn ich einen Fehler mache, kommt immer nur das Gleiche. anonymous anonymous   0 0 0 0 0 0
8401 2008-08-18 22:27:11 2009-02-25 19:51:44 2019-06-24 01:45:37.779038 Accepted closed Documentation     master fixed Document : 'django.test.simple.run_tests' - forces settings.DEBUG = False There doesn't seem to be a documented reason for forcing the settings.DEBUG value to False. The TEST_RUNNER should just use the value specified in the --settings option of the test management command. If there is a good reason to force the setting, it should be doc'd. Commenting out this line and running this test w/ settings.DEBUG = True seems to work. Here is the code: source:/django/trunk/django/test/simple.py#L123 nobody rishi TEST_RUNNER DEBUG test 0 0 0 0 0 0
8428 2008-08-19 21:20:11 2009-02-25 19:51:44 2019-06-24 01:45:55.391465 Unreviewed closed Uncategorized     master invalid hakrrz@hakrrz.com hakrrz@hakrrz.com nobody hakrrz@hakrrz.com hacker 0 1 0 0 0 0
8440 2008-08-20 07:19:26 2009-02-25 19:51:44 2019-06-24 01:46:52.533594 Unreviewed closed Forms     master invalid Change forms default auto_id='id-%s' Hey all, I don't think that the default auto_id for form fields is compatible with CSS1, since it starts with "id_". A la http://www.w3.org/TR/REC-CSS1#appendix-b: {{{ unicode \\[0-9a-f]{1,4} latin1 [¡-ÿ] escape {unicode}|\\[ -~¡-ÿ] stringchar {escape}|{latin1}|[ !#$%&(-~] nmstrt [a-z]|{latin1}|{escape} nmchar [-a-z0-9]|{latin1}|{escape} ident {nmstrt}{nmchar}* name {nmchar}+ }}} I believe it's a real simple patch (attached), but I haven't tested it rigorously. Cheers, Chris cdleary cdleary@gmail.com   0 1 0 0 0 0
8489 2008-08-22 17:55:40 2009-02-25 20:44:50 2019-06-24 01:47:24.239330 Unreviewed closed Uncategorized     master wontfix ImportError from missing _md5 gets swallowed I encountered this problem on Mac OS X 10.4 using Python 2.5 from !MacPorts and have seen it confusing other people on mailing lists. If I install the Python package from !MacPorts but forget the py25-hashlib package, importing hashlib fails, but the error message for that is not printed because !ImportError is being cought in source:django/trunk/django/db/__init__.py. The user is stuck with a confusing message of "!ImportError: No module named base" or similar (depending on the DB backend). I suggest catching !ImportError in source:django/trunk/django/utils/hashcompat.py and reraising it as !ImproperlyConfigured. nobody jfedor   0 0 0 0 0 0
8494 2008-08-22 23:41:09 2009-02-25 19:51:44 2019-06-24 01:47:27.416277 Unreviewed closed contrib.admin     master wontfix Instantiating ModelForm with request as kwargin ModelAdmin May I propose instantiating the ModelForm with request as kwarg in add_view, change_view in ModelAdmin class. This would allow the form, fields to be customized and validated on a per user basis. -form = ModelForm(request.POST, request.FILES) +form = ModelForm(request.POST, request.FILES, request=request) Perhaps also the FormSet nobody sorl   0 0 0 0 0 0
8507 2008-08-23 23:57:55 2009-02-25 19:51:44 2019-06-24 01:47:35.962123 Unreviewed closed Core (Serialization)     master duplicate dumpdata/loaddata can't handle two of the same contenttypes having different IDs in different databases Currently loaddata and dumpdata are pretty dumb in that they are not able to identify when two objects/rows that have different database ID's are actually one and the same object (or equivalent). For example, when dumping a dataset that has fkeys to the django_content_type table and then loading that data to another database which happens to have exactly the same content types installed but some of which have different database ID values, the outcome is an IntegrityError (or corrupted data). I think users should actually be able to do that without having to concern themselves with low level details such as database IDs. As a potential solution, it could be possible define how two model objects compare two be able to match equivalent objects with different ID's. As a side note, this could actually evolve to something that would also allow for callbacks to determine whether to overwrite a database object with an fixture object or not (for example, based on modification dates). This would simplify synchronizing databases and would not be difficult to implement either. nobody Erik Allik <eallik@gmail.com> dumpdata loaddata 0 0 0 0 0 0
8508 2008-08-24 00:34:44 2009-02-25 20:45:39 2019-06-24 01:47:36.597547 Unreviewed closed Documentation     master wontfix Design philosophies should become more visible in new docs site I think philosophy behind Django is important. In old doc site, It appears in first page (bottom part). I think philosophy explain some of Django goodness, and should be linked in overview, or change location to a more important section. jacob msaelices   0 0 0 0 0 0
8557 2008-08-26 12:59:52 2009-02-25 19:51:44 2019-06-24 01:48:08.526041 Design decision needed closed Template system     master duplicate intpoint filter for contrib.humanize for european users would be really useful an intpoint filter in contrib.humanize, here is the necessary code (similar to intcomma) def intpoint(value): """ Converts an integer to a string containing point every three digits. For example, 3000 becomes '3.000' and 45000 becomes '45.000'. """ orig = force_unicode(value) new = re.sub("^(-?\d+)(\d{3})", '\g<1>.\g<2>', orig) if orig == new: return new else: return intpoint(new) intpoint.is_safe = True register.filter(intpoint) hope this would be in 1.0, thanks drakkan nobody drakkan   0 1 0 0 0 0
8660 2008-08-28 22:47:55 2009-02-25 19:51:44 2019-06-24 01:49:16.434747 Accepted closed contrib.auth     master fixed Calling User.get_profile() should pre-populate the user foreign key on the profile object When you use the User.get_profile() method to fetch a profile object, it doesn't pre-populate profile's user attribute. This results in unnecessary DB queries when you go from User -> `UserProfile` and then later go from `UserProfile` -> `User`. This is actually a fairly common use case because people tend to attach methods that "extend" the user object in UserProfile, since they can't directly extend User. For example, if you create a `full_name()` method on `UserProfile` that returns {{{'%s %s' % (self.user.first_name, self.user.last_name)}}}, then in your templates, you do {{{ {{ User.get_profile.full_name }} }}}, you end up doing two DB queries when only one in necessary. The solution seems simple enough since the profile's User object must be called `user`. In django/contrib/auth/models.py a one liner after fetching the profile should do the trick: {{{ self._profile_cache = model._default_manager.get(user__id__exact=self.id) + self._profile_cache.user = self }}} nobody mmalone cache profile user auth 0 0 0 0 0 0
8672 2008-08-29 09:16:47 2009-02-25 19:51:44 2019-06-24 01:49:24.503903 Design decision needed closed Database layer (models, ORM)     master wontfix ModelForm.save() should implement force_insert and force_update, like Model.save() [8267] added the ability to force an SQL insert (or force an update) via a model's save() method. The same force_insert and force_update flags should be supported in a modelform's save() method. These flags enable better control over some edge cases - e.g. force_insert will prevent overwriting existing data if the same primary key has accidentally been specified. nobody Richard Davies <richard.davies@elastichosts.com>   0 1 0 0 0 0
8678 2008-08-29 11:04:50 2009-02-25 19:51:44 2019-06-24 01:49:28.463409 Unreviewed closed contrib.auth     master invalid errors with custom profile if profile model is placed somewhere else than in root dir django has 'ValueError at /users/profil/ too many values to unpack' in /home/grono3/python/django/contrib/auth/models.py in get_profile, line 292 nobody slowik   0 0 0 0 0 0
8681 2008-08-29 12:34:35 2009-02-25 20:58:46 2019-06-24 01:49:30.334925 Unreviewed closed Core (Other)     master invalid Uncaught exception in django/db/models/base.py: UnboundLocalError In source:django/trunk/django/db/models/base.py as of [8696], lines 197-203: {{{ #!python for field in fields_iter: rel_obj = None if kwargs: if isinstance(field.rel, ManyToOneRel): try: # Assume object instance was passed in. rel_obj = kwargs.pop(field.name) }}} If kwargs[field.name] is None, rel_obj is set to None, val is not set at all, and we get an UnboundLocalError at line 226. Context: the model in question had a OneToOneField whose primary_key was not yet set/was set to None and a save() was attempted. See stacktrace at dpaste: http://dpaste.com/74655/ Either we need to have a better error-message here, for instance mentioning what field is the problem and how it can be fixed, or the code needs to do something sensible. nobody HM <hanne.moa@gmail.com> models, onetoonefield 0 0 0 0 0 0
8686 2008-08-29 15:01:49 2009-02-25 20:59:13 2019-06-24 01:49:33.705966 Unreviewed closed Documentation     master invalid Example of permissions to edit/delete a particular object It would be nice to give an example of permissions to edit/delete/etc. a particular object, since this is a common scenario. nobody anonymous   0 0 0 0 0 0
8720 2008-08-30 22:23:18 2009-02-25 21:20:56 2019-06-24 01:49:55.839097 Unreviewed closed Forms     master invalid MultipleHiddenInput doesn't give list of elements in clean method When cleaning a MultipleHiddenInput field, the data is a unicode string of a python representation of a list, so like this u'[u'123', u'456']' which makes it kind of hard to validate the data. I think it should be a proper list, if i'm not missing something here. nobody stefan+django@lanpartei.de   0 0 0 0 0 0
8727 2008-08-31 13:18:55 2009-02-25 19:51:44 2019-06-24 01:50:00.307922 Ready for checkin closed Documentation     master fixed Documentation link to Italian SSN is broken In the new docs, http://docs.djangoproject.com/en/dev/ref/contrib/localflavor/#italy-it, the link for 'Italian social security number' returns a 404. nobody richardb   0 1 0 0 0 0
8733 2008-08-31 17:42:50 2009-02-25 19:51:44 2019-06-24 01:50:04.084172 Design decision needed closed Template system     master wontfix filesizeformat filter units unclear The {{{filesizeformat}}} filter calculates prefixes in multiplies of 1024. This is ambiguous, since the units "kilobyte", "megabyte" and "gigabyte" are currently commonly used to express both decimal and binary based sizes. For "kilobytes" and "megabytes" the difference is probably unsignificant (1,000 vs. 1,024 and 1,000,000 vs. 1,048,576), but in the case of gigabytes it starts to be substantial. At least these two solutions are possible: 1. use decimal instead of binary and remind developers in the documentation to mention about it to users if necessary: * KB = 1,000 bytes * MB = 1,000,000 bytes * GB = 1,000,000,000 bytes 2. use IEC prefixes: * KiB = 1,024 bytes * MiB = 1,024**2 bytes * GiB = 1,024**3 bytes See also: * http://en.wikipedia.org/wiki/Binary_prefix * http://en.wikipedia.org/wiki/Gigabyte nobody akaihola   0 0 0 0 0 0
8742 2008-09-01 02:56:08 2009-02-25 21:25:55 2019-06-24 01:50:09.951143 Unreviewed closed Uncategorized     master invalid Windows support of FastCGI feature Django FastCGI cannot be used on Windows, and possibly other non-Unix environments. Currently the FastCGI feature of Django (manage.py runfcgi) relies on the Python library 'flup', which relies on Unix-only socket functions (socket.socketpair(), socket.fromfd(), etc.) making it impossible to use the FastCGI feature of Django on non-Unix envs like Windows, and hence, making it impossible to serve Django with non-Apache (non-mod_python) httpds like lighttpd on non-Unix envs. Possible solutions: The function socketpair() is unofficially implemented on Windows by a recipe. (http://code.activestate.com/recipes/525487/) Committing this patch to the flup project is not a hard work. However, the function fromfd() has nothing like that. There is a patch enabling its Windows use (http://bugs.python.org/issue1378) but the patch is not yet applied on the Windows release, even on Python 2.6b2. Rewriting the FastCGI feature with python-fastcgi (http://pypi.python.org/pypi/python-fastcgi) could be a more work than flup, but then the feature can support Windows. Unix environments, especially GNU/Linux, is of course better than Windows to be used as a web server, but there are some situations where Windows and FastCGI have to be used. It would be good to have Django FastCGI available on Windows. nobody anonymous   0 0 0 0 0 0
8761 2008-09-01 13:32:27 2009-02-25 21:33:50 2019-06-24 01:50:22.482159 Unreviewed closed contrib.admin     master wontfix Permissions bug in Admin area If a user is given add/edit/delete permissions to user objects, the user is then able to create other users with greater permissions than itself, even promoting others to superuser status. Furthermore that user could also turn itself super by editing profile. Running off latest SVN version. nobody caphun admin, interface, permissions, users, groups, bug 0 0 0 0 0 0
8772 2008-09-01 21:20:34 2009-02-25 19:51:44 2019-06-24 01:50:29.406913 Unreviewed closed Uncategorized     master wontfix When a get_object_or_404 returns a 404, it'd be nice if it would return which query didn't provide an object (when DEBUG=True) I recently had an error in a query in a context processor. When I tried to go to a certain page, I got the error: "No CollabProject matches the given query". And practically no other information. No trackbacks or anything. No indication of which file the error was in. Just that message and a 404. I kept checking and couldn't find any error in my view. I even confirmed that the view executed to the end. It was only by chance that I discovered the error in the context processor. Isn't there a way to have it such that if the error occurs in a context processor, it can point to the line in the context processor that had the bad query? BTW, by bad query I mean a valid query that doesn't return any objects in the database. I suspect this may be a problem with such a query in a middleware, but did not experiment. nobody Beetle_B   0 0 0 0 0 0
8806 2008-09-02 18:38:01 2009-02-25 19:51:44 2019-06-24 01:50:51.345858 Unreviewed closed contrib.admin     master duplicate ModelAdmin should allow not default manager My use case is this: I have a model with two Managers - one named objects (the default), and another one. I want the admin to use the non-default one (in my case I can't even give it the default one since it doesn't return instances of the model, but of another model it inherits from). So my solution (It doesn't even merit a patch - its just 3 lines changed in django/contrib/admin/options.py): # my code from django.contrib import admin class MyAdmin(admin.ModelAdmin): model = MyModel manager = MyModel.othermanager # unified diff against django/contrib/admin/options.py svn 8851 --- a/django/contrib/admin/options.py +++ b/django/contrib/admin/options.py @@ -166,6 +166,8 @@ class ModelAdmin(BaseModelAdmin): ordering = None inlines = [] + manager = None + # Custom templates (designed to be over-ridden in subclasses) change_form_template = None change_list_template = None @@ -239,7 +241,10 @@ class ModelAdmin(BaseModelAdmin): Returns a QuerySet of all model instances that can be edited by the admin site. This is used by changelist_view. """ - qs = self.model._default_manager.get_query_set() + if self.manager is None: + qs = self.model._default_manager.get_query_set() + else: + qs = self.manager.get_query_set() # TODO: this should be handled by some parameter to the ChangeList. ordering = self.ordering or () # otherwise we might try to *None, which is bad ;) if ordering: nobody alon ModelAdmin,Manager 0 1 0 0 0 0
8850 2008-09-03 17:45:13 2009-02-25 21:43:29 2019-06-24 01:51:20.641235 Unreviewed closed contrib.syndication     1.0 wontfix syndication framework includes an extra newline using default templates The syndication framework default behavior is to load templates named {{{feeds/<slug>_title.html}}} and {{{feeds/<slug>_description.html}}}. The newline at the end of these files is include in the rendered output, which for HTML doesn't really matter but could for XML. So rather than: {{{ <title>Testo<title> }}} a person ends up with {{{ <title>Testo </title> }}} It is easy to fix this behavior by subclassing Feed so I'm not sure if it's a huge deal - maybe worth documenting somehow? nobody hopson   0 0 0 0 0 0
8855 2008-09-03 19:52:23 2009-02-25 19:51:44 2019-06-24 01:51:23.937414 Unreviewed closed contrib.comments     master duplicate Default comment form deficiencies Default comment form, as found in comments framework, suffers from some basic deficiencies: * submit button labels ("Post" and "Preview") are not marked for translation; * the `input` HTML elements (tags) are not closed, effectively prohibiting document validation as XHTML 1.0 Attached patch fixes these two problems and adds minor change in HTTP method declaration for consistency in style.   zgoda   0 1 0 0 0 0
8860 2008-09-04 02:03:56 2009-02-25 19:51:44 2019-06-24 01:51:27.482072 Unreviewed closed Documentation     master invalid Where should form classes and formset classes be defined? The current documentation doesn't say '''where''' form classes and formset classes and so on should be defined. Should they be defined in module models.py or in a separate module forms.py or somewhere else altogether? I think the situation is analogous to admin information which eventually was moved from models.py to admin.py. nobody r.topor@griffith.edu.au forms 0 0 0 0 0 0
8866 2008-09-04 06:22:07 2009-02-25 19:51:44 2019-06-24 01:51:31.502772 Unreviewed closed Documentation     1.0 invalid Built-in Javascript search results' links is missing FILE_SUFFIX The docs generated by running 'make html' in the docs directory has a built-in javascript search facility (`docs/_build/html/search.html`). The search results' links/URLs are incorrect because they're missing the ".html" suffix in the file name. If I edit `search.html` and set FILE_SUFFIX to '.html' in the top javascript section then the search results links work. nobody ronny search 0 0 0 0 0 0
8868 2008-09-04 07:25:28 2009-02-25 19:51:44 2019-06-24 01:51:32.779610 Unreviewed closed contrib.comments     master fixed Templates in comments framework are not marked for translation Strings in new comments framework templates are not marked for translation. Attached patch fixes this issue by marking user-visible strings in templates for translation. nobody zgoda   0 1 0 0 0 0
8869 2008-09-04 07:35:06 2009-02-25 19:51:44 2019-06-24 01:51:33.406446 Unreviewed closed contrib.comments     master fixed Templates in comments framework are not XHTML-compliant The HTML markup used in new comment framework templates is not XHTML-compliant in many places. Attached patch fixes this issue. nobody zgoda   0 1 0 0 0 0
8870 2008-09-04 07:41:22 2009-02-25 19:51:44 2019-06-24 01:51:34.056231 Unreviewed closed contrib.comments     master fixed Templates in comments framework are not compliant with Django style In all templates in comment framework all froms have HTTP method uppercased. This is not compliant with style of other Django components. Attached patch fixes this issue. nobody zgoda   0 1 0 0 0 0
8872 2008-09-04 08:08:39 2009-02-25 19:51:44 2019-06-24 01:51:35.324947 Ready for checkin closed Documentation     1.0 fixed Small typo in commiters.txt There's a very very very small typo in commiters.txt: {{{ diff --git a/docs/internals/committers.txt b/docs/internals/committers.txt index a623d99..42924b3 100644 --- a/docs/internals/committers.txt +++ b/docs/internals/committers.txt @@ -115,7 +115,7 @@ Joseph Kocherhans .. _charango: http://en.wikipedia.org/wiki/Charango `Luke Plant`_ - Like has contributed many excellent improvements, including database-level + Luke has contributed many excellent improvements, including database-level improvements, the CSRF middleware and many unit tests. .. _luke plant: http://lukeplant.me.uk/ }}} nobody telenieko   0 1 0 0 0 0
8881 2008-09-04 20:34:46 2009-02-25 19:51:44 2019-06-24 01:51:40.950805 Unreviewed closed GIS     1.0-beta fixed LayerMapping Error with more than two fields geometry If my models have two or more geometry fields: {{{ class Lugares(models.Model) : nombre = models.CharField(max_length=80) punto = models.MultiPointField(null=True, blank=True, srid=4326) poligono = models.MultiPolygonField(null=True, blank=True, srid=4326) objects =models.GeoManager() lm=LayerMapping(Lugares,'/home/woakas/nuevo.shp', mapping,unique={'poligono':'POLYGON','tipolugar':'Ciudad'}) }}} {{{ LayerMapError Traceback (most recent call last) /home/woakas/mig/Migtrace/trunk/src/<ipython console> in <module>() /usr/lib/python2.5/site-packages/django/contrib/gis/utils/layermapping.py in __init__(self, model, data, mapping, layer, source_srs, encoding, transaction_mode, transform, unique) 186 # geometry column). 187 self.model = model --> 188 self.geo_col = self.geometry_column() 189 190 # Checking the source spatial reference system, and getting /usr/lib/python2.5/site-packages/django/contrib/gis/utils/layermapping.py in geometry_column(self) 516 return GeometryColumns.objects.get(**gc_kwargs) 517 except Exception, msg: --> 518 raise LayerMapError('Geometry column does not exist for model. (did you run syncdb?):\n %s' % msg) 519 520 def make_multi(self, geom_type, model_field): LayerMapError: Geometry column does not exist for model. (did you run syncdb?): get() returned more than one GeometryColumns -- it returned 2! Lookup parameters were {'f_table_name': 'migtrace_lugares'} }}} jbronn woakas@gmail.com gis layermapping 0 0 0 0 0 0
8902 2008-09-05 17:34:25 2009-02-25 19:51:44 2019-06-24 01:51:54.001826 Unreviewed closed Template system     1.0 duplicate tags having problems with filtered variables using arguments with spacing If you want to do something like this: {{{ {% with activity.start_date|date:"l j F" as date1 %} }}} You'll get this error: {{{ Exception Value: u'with' expected format is 'value as name' }}} This is due to this code: {{{ bits = list(token.split_contents()) if len(bits) != 4 or bits[2] != "as": raise TemplateSyntaxError("%r expected format is 'value as name'" % bits[0]) }}} First of all, maybe another bug: split_contents gave me a double "" on a filter as |cut:" ", so I replaced it with contents.split() which worked fine for me. Then, this error: len(bits) !=4 is actually overkill. The tag works like this: 0 -> tagname, 1-> a variable with filter, 2 -> as, 3 -> newvar. Actually you should not check if the ' '-splitted content is 4 long, you should check if [1] passes the compile_filter, which will throw it's own error. I tried to write a regex or iteration that really checked if you did really passed 1 variable + filter(s), but that really isn't trivial, and the compile_filter function's error is actually clear enough. I added a patch + test for the {% with %} tag only at the moment (because that's where I encountered the problem). However, other tags have the problem also. nobody kire template tags 0 1 0 0 0 0
8905 2008-09-05 20:32:54 2009-02-25 19:51:44 2019-06-24 01:51:55.867236 Accepted closed contrib.comments     1.0 fixed Error in default comment preview template In {{{django/contrib/comments/templates/comments/preview.html}}} row 31 name attribute of the submit button is wrong. The name should be 'preview' not 'submit'. This makes preview template to submit the comment every time no matter which button is used. Correct HTML for the preview button: {{{ <input type="submit" name="preview" class="submit-preview" value="Preview"> }}} Also, most of the texts in the default comment templates are not marked as translatable, but that is a matter of another ticket. nobody Uninen comments, templates 0 0 0 0 0 0
8925 2008-09-07 14:04:16 2009-02-25 19:51:44 2019-06-24 01:52:08.427094 Unreviewed closed Documentation     1.0 invalid Confusing text in "Running a development server with mod_python" There seems to be quite strange sentence in the first paragraph of the '''Running a development server with mod_python'''. See the last sentence:''But don't do that on a production server, or we'll revoke your Django privileges.'' This is probably related to rules on a hosting company the docs autor used some time ago and IMHO does not have anything to do here. Consider to remove it or change to neutral meaning - try maybe ''your hosting provider might revoke your privileges'' etc. Thanks nobody tofu   0 0 0 0 0 0
8929 2008-09-07 17:40:46 2009-02-25 19:51:44 2019-06-24 01:52:10.964790 Unreviewed closed Uncategorized     1.0 invalid Reduce the divide between Django and the rest of the Python web world Mark Ramm again - see also #8928 and #8927 nobody simon   0 0 0 0 0 0
8938 2008-09-08 01:11:14 2009-02-25 22:39:44 2019-06-24 01:52:16.632979 Unreviewed closed Database layer (models, ORM)     1.0 invalid A nice API for multi-db support Adrian and Jacob on stage at DjangoCon. nobody simon   0 0 0 0 0 0
8941 2008-09-08 01:14:51 2009-02-25 22:41:48 2019-06-24 01:52:18.491918 Unreviewed closed Uncategorized     1.0 invalid Shared identity across all of the different Django community sites Adrian and Jacob on stage at DjangoCon. ericholscher simon djangocon 0 0 0 0 0 0
8943 2008-09-08 01:30:16 2009-02-25 22:42:11 2019-06-24 01:52:19.741162 Unreviewed closed Uncategorized     1.0 fixed Discuss starting to phase out support for Python 2.3 Adrian and Jacob on stage at DjangoCon. Jacob: "If there's some distro being used by millions of people maybe we won't do this just yet, but we need to start getting ready for Python 2.6 and the eventual migration to Python 3. Guido says we have 5 years". nobody simon djangocon 0 0 0 0 0 0
8944 2008-09-08 01:34:07 2009-02-25 22:44:19 2019-06-24 01:52:20.333890 Unreviewed closed Documentation     1.0 invalid Documentation should go further than just your first application Adrian and Jacob on stage at DjangoCon. Adrian: "maybe we should link to a video of James' DjangoCon talk at the end of the tutorial" nobody simon djangocon 0 0 0 0 0 0
8945 2008-09-08 01:36:36 2009-02-25 22:48:53 2019-06-24 01:52:20.970902 Unreviewed closed Uncategorized     1.0 invalid Better links from the Django docs to community tutorials Adrian and Jacob on stage at DjangoCon. nobody simon djangocon 0 0 0 0 0 0
8951 2008-09-08 01:43:21 2009-02-25 22:51:02 2019-06-24 01:52:24.812800 Unreviewed closed Template system     1.0 invalid Better support for writing more complex template tags Adrian and Jacob on stage at DjangoCon. nobody simon djangocon 0 0 0 0 0 0
8953 2008-09-08 01:58:47 2009-02-25 22:52:04 2019-06-24 01:52:26.049229 Unreviewed closed Uncategorized     1.0 duplicate Timezone support at the model level This should probably rely on dateutil and/or pytz - so you wouldn't be able to use !DateTimeTzField without having those installed. nobody simon djangocon 0 0 0 0 0 0
8959 2008-09-08 07:06:45 2009-02-25 19:51:44 2019-06-24 01:52:29.814602 Accepted closed contrib.comments     master fixed Remove calls to escape in new comments framework templates As autoescaping is in place with current Django, escaping values in templates is not necessary. Attached patch fixes this. adrian zgoda   0 1 0 0 0 0
8963 2008-09-08 09:06:13 2009-02-25 19:51:44 2019-06-24 01:52:32.303465 Accepted closed contrib.comments     master fixed Comments framework should use standard decorators where possible Comments framework uses custom method for assuring proper HTTP method is used in view breaking DRY principle. Attached patch fixes this issuel nobody zgoda   0 1 0 0 0 0
8967 2008-09-08 15:54:50 2009-02-25 19:51:44 2019-06-24 01:52:34.795408 Unreviewed closed Documentation     1.0 fixed Model documentation omits through option in ManyToManyField The [http://docs.djangoproject.com/en/dev/ref/models/fields/#manytomanyfield Model Field Reference] does not mention the new kwarg "through" for ManyToMany field. Before the refactoring, the omission of that option was not so serious because the next section of the same page was [http://www.djangoproject.com/documentation/model-api/#extra-fields-on-many-to-many-relationships Extra fields on many-to-many relationships], but now that section was moved to a different page ([http://docs.djangoproject.com/en/dev/topics/db/models/ Writing Models]), so "through" must be mentioned in the Model Field Reference. nobody ramalho   0 0 0 0 0 0
8991 2008-09-09 14:59:38 2009-02-25 19:51:44 2019-06-24 01:52:49.850382 Accepted closed Documentation     master wontfix Remove "version[added|changed]" from trunk docs Just as a reminder, I'm doing the patch ;) telenieko telenieko   0 0 0 0 0 0
8993 2008-09-09 16:13:22 2009-02-25 22:56:10 2019-06-24 01:52:51.095216 Unreviewed closed Forms     master wontfix Rendering formsets as tables with a row per form In the default as_table method of formsets it states: {{{ # XXX: there is no semantic division between forms here, there # probably should be. It might make sense to render each form as a # table row with each field as a td. }}} The attached patch provides an 'as_table_wide' method, which does this. It calls an 'as_row' method on each form. This 'as_row' method is also supplied in the patch. It is also useful to be able to easily include extra columns in the table, that are not form entries, but which depend on the form. This is especially true for model formsets, where the contents of the extra columns depends on the same model instance as the form, eg for fields of the model that may not change, but which should be displayed. This can be done by providing a form class with its own 'as_row' method, which modifies the standard one. nobody andrew.mcmurry@ifi.uio.no formsets 0 1 0 0 0 0
9003 2008-09-10 02:07:24 2009-02-25 19:51:44 2019-06-24 01:52:57.297839 Unreviewed closed Documentation     master fixed Minor Typo in the "MySQL comparisons" section of the QuerySet API Documentation There are a few minor typos and awkward language in the "MySQL comparisons" sections of the QuerySet API documentation. Attached is a patch with improved language and fixed typos. nobody seanoc   0 1 0 0 0 0
9017 2008-09-10 18:16:49 2009-02-25 19:51:44 2019-06-24 01:53:06.155167 Unreviewed closed Translations     1.0 fixed Translation update for Danish Attached you'll find an update for the Danish translation of Django 1.0. Danish translation should now be complete. nobody finngruwier   0 0 0 0 0 0
9034 2008-09-11 14:48:57 2009-02-25 19:51:44 2019-06-24 01:53:16.918808 Unreviewed closed Documentation     master duplicate Example code in custom-template-tags uses template.resolve_variable should use template.Variable Code example here: http://docs.djangoproject.com/en/dev/howto/custom-template-tags/#howto-custom-template-tags nobody oyvind resolve_variable Variable template custom 0 0 0 0 0 0
9066 2008-09-12 20:40:24 2009-02-25 19:51:44 2019-06-24 01:53:37.195633 Ready for checkin closed contrib.localflavor     master fixed Add Czech localflavor package I am attaching a patch containing some form ields for Czech localflavor: Mainly: CSZipCodeField, CSRegionSelect, CSPhoneNumberField, CSBirthNumberField Some of them also have model fields added. Elvard mathwizard   0 1 0 0 0 0
9087 2008-09-15 11:21:33 2009-02-25 19:51:44 2019-06-24 01:53:50.409595 Unreviewed closed contrib.syndication     1.0 wontfix Change RssFeed mime-type to "application/xml" Currently the RssFeed class returns RSS feeds with "application/rss+xml" as the mime-type. However, "application/rss+xml" isn't a valid registered mime-type at the IANA (http://www.iana.org/assignments/media-types/application/), so I'm proposing to change it to "application/xml" which seems to be widely used among other rss feeds. Nice side effect: Firefox will highlight the XML properly when viewing its source, which makes debugging a little bit easier. nobody arthurk mime-type rss+xml 0 1 0 0 0 0
9109 2008-09-16 19:45:05 2009-02-25 19:51:44 2019-06-24 01:54:05.020245 Unreviewed closed contrib.admin     1.0 duplicate Support for nested Inline objects. Support for nested Inline objects. nobody anonymous Inline objects admin 0 0 0 0 0 0
9127 2008-09-17 18:21:28 2009-02-25 19:51:44 2019-06-24 01:54:16.548216 Unreviewed closed contrib.admin     master invalid admin.autodiscover() fails in certain structures Take the following structure: '''projectfolder -> modules -> app1 admin/ admin.py -> app2 admin/ admin.py settings.py urls.py''' Admin.autodiscover() as far as I know uses imp.find_module('admin', app_path), which seems to result in looking for an __init__.py inside the "admin/" folders of the apps, which I need for custom admin views, instead of directly using "admin.py" from the apps. nobody panni@fragstore.net autodiscover, fails, admin, folder 0 0 0 0 0 0
9135 2008-09-18 17:10:17 2009-02-25 19:51:44 2019-06-24 01:54:21.853698 Unreviewed closed Documentation     master duplicate http://docs.djangoproject.com/en/dev/ref/contrib/admin/#exclude Should say: {{{ class AuthorAdmin(admin.ModelAdmin): exclude = ['birth_date'] }}} Otherwise, django throws a typeError about tuples and lists. nobody anonymous   0 0 0 0 0 0
9137 2008-09-18 20:00:04 2009-02-25 19:51:44 2019-06-24 01:54:23.112829 Unreviewed closed Documentation     1.0 invalid Tutorial 1 has a small mistake def was_published_today(self): return self.pub_date.date() == datetime.date.today() That doesn't seem to work for me, def was_published_today(self): return self.pub_date == datetime.date.today() Does. nobody hvdklauw@gmail.com Tutorial 0 0 0 0 0 0
9142 2008-09-19 05:38:52 2009-02-25 19:51:44 2019-06-24 01:54:26.211979 Unreviewed closed Forms     1.0-alpha-2 invalid Validation shouldn't be coupled with validation... Well, very simple. If i have a ModelForm and i want to change a fields widget, i got to do as follows : {{{ class MyForm(forms.ModelForm): my_field = forms.SomeField(widget=my_widget) class Meta: model = my_model }}} Well, when i do that, part of the form's validation goes away! Let's see a actual example: {{{ class MyModel(models.Model): image = models.ImageField(uploat_to="some/path") class MyForm(forms.ModelForm): image = forms.SomeField(widget=SimpleFileWidget) class Meta: model = MyModel }}} Well, using MyForm now will not validate if image is actually a image. That seems just wrong, to me. Something like this would be nicier: {{{ class MyModel(models.Model): image = models.ImageField(uploat_to="some/path") class MyForm(forms.ModelForm): image = forms.SomeField(widget=SimpleFileWidget, validation=forms.ImageValidation) class Meta: model = MyModel or: class MyForm(forms.ModelForm): image = forms.SomeField(widget=SimpleFileWidget, forms.get_validation(MyModel, "image")) # or something similar. class Meta: model = MyModel }}} nobody italomaia form validation decouple 0 0 0 0 0 0

Next page

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE "tickets_full" (
        id int primary key,
        created datetime,
        changetime datetime,
        last_pulled_from_trac datetime,
        stage text,
        status text,
        component text,
        type text,
        severity text,
        version text,
        resolution text,
        summary text,
        description text,
        owner text,
        reporter text,
        keywords text,
        easy boolean,
        has_patch boolean,
        needs_better_patch boolean,
        needs_tests boolean,
        needs_docs boolean,
        ui_ux boolean