Commit graph

78 commits

Author SHA1 Message Date
Matthew Dapena-Tretter
87983c5e6d Move force_bytes into lib module 2013-12-14 13:02:21 -05:00
Matthew Dapena-Tretter
c1e16696b1 Don't use a raw string with \u escapes
Apparently, Python 3.2 doesn't process these in raw strings.
See https://mail.python.org/pipermail/python-list/2012-May/624756.html
and https://mail.python.org/pipermail/python-dev/2007-May/073042.html
2013-12-14 12:54:26 -05:00
Venelin Stoykov
fb947b1937 Fix sanitizing cache key under Python 3 2013-12-14 18:56:47 +02:00
Venelin Stoykov
0575011529 Add Python 3 suport and drop support for Python 2.5 2013-08-19 21:27:50 +03:00
Sean Hayes
d647678c2e Added global boolean to prevent autodiscover() from being called more than once. 2013-08-14 22:55:28 -04:00
Matthew Tretter
0d5bfe3751 Define NullHandler for Python <= 2.6
Closes #219
2013-05-20 19:19:13 -04:00
Matthew Tretter
06dd238993 Store cachefile strategy on file; not generator
The file can appeal to the generator for the value, but it shouldn't
require it; it just does that as a convenience.
2013-05-10 00:51:47 -04:00
Matthew Tretter
f173861b53 Fix invalid char range 2013-04-30 09:32:47 -04:00
Matthew Tretter
c704db2da5 Sanitize cache keys for memcached
Closes #208
2013-04-30 09:32:47 -04:00
Matthew Tretter
dff0182310 Remove another old util 2013-02-12 21:40:15 -05:00
Matthew Tretter
f5a078b68f Remove old util 2013-02-12 21:40:15 -05:00
Matthew Tretter
90ae9e8339 Fix get_nonabstract_descendants
Previously, function was only returning the first non-abstract
descendant. (It should also return concrete descendants of concrete
descendants, which it now does.)

Also, converted to generator.
2013-02-10 15:58:22 -05:00
Sean Bell
af6ebcb469 Fixing iteration over objects for abstract models 2013-02-09 03:02:18 -05:00
Matthew Tretter
36313194ac Remove PILKit functionality
This commit removes the functionality now in the PILKit project, and
adds PILKit as a dependency. Import hooks have been used to expose the
processors under "imagekit.processors".
2013-02-07 23:10:05 -05:00
Matthew Tretter
301adc2087 Let's call em cachefiles
Changed my mind about 04aa72c1f9. It's
just a better description, even if different strategies can change the
behavior so it isn't really very cache-like.
2013-02-04 19:52:38 -05:00
Matthew Tretter
92b11f8349 Use imagegenerators module, not imagespecs 2013-02-01 00:30:15 -05:00
Matthew Tretter
bf1685dbfb Generalize get_class util 2013-01-31 22:01:01 -05:00
Matthew Tretter
d6b73b8da7 Renaming/repackaging of generated file related classes 2013-01-31 19:24:08 -05:00
Matthew Tretter
04aa72c1f9 Rename cache things (it isn't cachine)
https://twitter.com/alex_gaynor/statuses/257558176965206016
2013-01-31 10:07:20 -05:00
Matthew Tretter
3931b552a0 Separate source groups and cacheables.
This allows a sensible specialized interface for source groups, but also
for ImageKit to interact with specs using the generalized image
generator interface.
2013-01-29 01:40:00 -05:00
Matthew Tretter
234082e63c Extract generate() util, to make files Django likes 2013-01-23 22:34:29 -05:00
Matthew Tretter
d52b9c8100 Add utility for extracting field info 2013-01-23 21:47:54 -05:00
Matthew Tretter
9188499965 Rework template tag for generators 2012-12-01 20:36:31 -05:00
Matthew Tretter
fb8c411f75 Create new cache warming command
Replaces ikcachevalidate and ikcacheinvalidate, and uses the "sources"
abstraction. Closes #165
2012-10-24 23:41:05 -04:00
Matthew Tretter
3dbb96ea40 Remove unused imports 2012-10-21 17:57:53 -04:00
Matthew Tretter
ca1db05c4e Use named logger 2012-10-17 21:00:32 -04:00
Matthew Tretter
3308c92a71 Remove SpecWrapper class
We don't need it now that we have an ImageSpec class
2012-10-16 22:23:14 -04:00
Matthew Tretter
80b723b510 Move IKContentFile to imagekit.files 2012-10-16 21:31:47 -04:00
Eric Eldredge
c0b79a227d Remove ImageSpecFieldFile in favor of ImageSpecFile 2012-10-15 23:53:05 -04:00
Eric Eldredge
2a33a2ad88 Fix circular import utils > imagecache.backends 2012-10-15 21:17:58 -04:00
Matthew Tretter
fe803f8981 Beginning to move functionality into "sources"
Before this is applied, we're going to have to make it so that the
image cache strategies are passed the source file, not the other file.
2012-10-10 00:18:54 -04:00
Matthew Tretter
d2087aa168 Create ImageSpecs; remove generators 2012-10-04 21:37:20 -04:00
Eric Eldredge
2e5489eb56 Merge branch 'ik-next' into templatetags
Conflicts:
	imagekit/models/fields/__init__.py
	imagekit/utils.py
2012-10-04 15:46:50 -04:00
Matthew Tretter
0fc29ee7cf Extract useful backend utils 2012-09-06 09:09:30 -04:00
Eric Eldredge
c50e6cea3b Merge branch 'develop' into templatetags
Conflicts:
	imagekit/utils.py
2012-09-05 21:46:59 -04:00
Matthew Tretter
c8733c4707 Change how signals are used
Signals are now connected without specifying the class and non-IK
models are filtered out in the receivers. This is necessary because of
a bug with how Django handles abstract models.

Closes #126
2012-07-25 23:04:21 -04:00
Matthew Tretter
c1b4c9bf71 Use cStringIO if available 2012-05-12 15:45:08 -04:00
Jeroen Dekkers
69b590257d Do not leak file descriptor 2012-04-28 16:13:50 +02:00
Matthew Tretter
89eb05668e IKContentFile accepts format hint 2012-04-20 23:30:30 -04:00
Matthew Tretter
b466ff3723 Additional mimetype utils 2012-04-20 23:27:35 -04:00
Matthew Tretter
667e265c94 Refactored AutoConvert into prepare_image
Because of its need to return kwargs for ``Image.save()``, it never
really fit the mold of a processor.
2012-04-20 21:37:43 -04:00
Matthew Tretter
222c9ba22a Docstring for save_image 2012-04-20 21:23:06 -04:00
Matthew Tretter
b6f629d644 Kill PIL's chattiness; fixes #91 2012-04-20 01:55:00 -04:00
Matthew Tretter
6f8a22c5bf Use StringIO instead of temp file 2012-04-20 00:46:33 -04:00
Matthew Tretter
e0c9708e63 Extract reusable save_image function 2012-04-20 00:46:08 -04:00
Matthew Tretter
7d5937ebe6 Rename SpecFile and move it to utils 2012-04-19 21:33:56 -04:00
Matthew Tretter
8044b97a33 Extract suggest_extension util from generator 2012-04-19 21:33:52 -04:00
Matthew Tretter
d275aaa3f7 A little reorganization 2012-02-13 22:12:07 -05:00
Matthew Tretter
8b6ba687e4 Commands for validating and invalidating the cache 2012-02-02 00:19:46 -05:00
Matthew Tretter
c4fc09c688 Fix var name typo 2012-02-02 00:08:22 -05:00