google-code-export / django-syncr

Automatically exported from code.google.com/p/django-syncr
0 stars 0 forks source link

Flickr model, admin, and datetime.timedelta import broken in r47 #32

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
I've created a patch against svn r47 which contains the following fixes:

* PhotoAdmin referenced 'tag_list' field. Should be 'tags'.

* FlickrSyncr.syncRecentPhotos calls datetime.timedelta, but imports datetime 
from datetime 
module which has no timedelta method.

* Added new BigIntegerField and changed 'flickr_id' for the Photo model to be 
of the new type. 
This eliminates the "high score" bug in Django's PositiveIntegerField when 
using some database 
engines. PostgreSQL can't store high 'flickr_id' values in an IntegerField. 
see: 
http://answers.yahoo.com/question/index?qid=20070625175121AAOguTQ

* Added auto-created primary key to Photo model and changed all other code to 
reference 
'flickr_id' where 'pk' was formerly used. If 'flickr_id' is a BigIntegerField, 
django-tagging breaks 
because it expects a primary key that will fit in a normal 'integer' column.

All of these issues were pretty much "no-go" situations for the Flickr app in 
my setup. Someone 
(me?) should really write some tests to prevent this kind of craziness. What do 
you think?

Apply patch with 'patch -p0 -i syncr_flickr.diff' in trunk working directory.

Original issue reported on code.google.com by xdiss...@gmail.com on 19 Dec 2008 at 4:08

Attachments:

GoogleCodeExporter commented 9 years ago
Thanks much for the patch, seems to have fixed a fair bit of things for me:)

Original comment by zeph...@gmail.com on 28 Dec 2008 at 11:34

GoogleCodeExporter commented 9 years ago
Forgot to add this patch into the repository when you submitted it. Have 
patched it
in now and credited you in the changelog. THANK YOU!

Original comment by jesse.l...@gmail.com on 28 Dec 2008 at 8:37