6ad9b5f7bd
Ported utils.remove_private_keys() from Pillar
2016-07-05 16:30:34 +02:00
2a86abe66e
Datetimes are now returned as timezone-aware.
...
Timezone is hardcoded as UTC for now, as Pillar always returns UTC times.
2016-06-29 16:49:19 +02:00
a98986a261
Added pillarsdk.utils.is_valid_id(some_id) function.
...
This allows Pillar-Web to check for ID validity before sending IDs
from the URL to Pillar.
2016-06-29 13:05:04 +02:00
d60a1878e7
Skip missing keys in convert_datetime
2016-04-26 17:33:36 +02:00
9a51c82d9a
Added util function for filename sanitation
2016-03-22 14:32:34 +01:00
dac5d638da
Added support for saving Pillar resources as JSON.
2016-03-22 12:42:31 +01:00
886e3c7eaf
Sort parameters on the URL to allow caching.
...
Python randomizes dict item order with a random seed, which changes every
time Python/Blender is run. As a result, Pillar GET parameters on the URL
would change, making them uncachable. Sorting the parameters solves this.
2016-03-18 16:37:16 +01:00
42fd0aebd9
Added doc string for remove_none_attributes
2016-03-16 16:08:02 +01:00
b690755b84
Made utils.merge_dict None-safe, and removed lots of "thing or {}"
2016-03-11 10:24:19 +01:00
bdecff27d4
Added downloading thumbnails to file
2016-03-09 14:00:59 +01:00
ec11e82f32
PEP8 formatting
2016-03-09 12:40:19 +01:00
ed0630aa7c
Added parameter type checking for utils.join_url
...
This made things a bit easier to debug, while re.sub() raises less
descriptive errors.
2016-03-09 12:40:13 +01:00
87ebdb0b2f
Removed six from requirements, as Blender isn't shipped with it.
2016-03-08 16:01:22 +01:00
418b15caf4
Added dict → JSON and unicode → UTF8 conversion for URL parameters.
2016-03-08 13:52:51 +01:00
bc1a146ef2
New remove_none_attributes utility
...
Returns a new dict with all None values removed.
2016-03-05 23:18:40 +01:00
49685cfcb2
Fix for typo
2015-11-01 22:54:59 +01:00
c1ff4ba9bb
Introducing convert_datetime function
...
Starting from an JSON object, find and replace the _create and _updated
keys with actual datetime objects.
2015-10-20 13:03:34 +02:00
991cc27e30
Renaming to Pillar SDK.
2015-08-31 19:25:01 +02:00