HPI/my
Sean Breckenridge 46198a6447
my.core.serialize: simplejson support, more types (#176)
* my.core.serialize: simplejson support, more types

I added a couple extra checks to the default function,
serializing datetime, dates and dataclasses (incase
orjson isn't installed)

(copied from below)

if orjson couldn't be imported, try simplejson
This is included for compatibility reasons because orjson
is rust-based and compiling on rarer architectures may not work
out of the box

as an example, I've been having issues getting it to install
on my phone (termux/android)

unlike the builtin JSON modue which serializes NamedTuples as lists
(even if you provide a default function), simplejson correctly
serializes namedtuples to dictionaries

this just gives another option to people, simplejson is pure python
so no one should have issues with that. orjson is still way faster,
so still preferable if its easy and theres a precompiled build
for your architecture (which there typically is)

If you're ever running this with simplejson installed and not orjson,
its pretty easy to tell as the JSON styling is different; orjson has
no spaces between tokens, simplejson puts spaces between tokens. e.g.

simplejson: {"a": 5, "b": 10}
orjson: {"a":5,"b":10}
2021-07-08 23:02:56 +01:00
..
body cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
books core: add __NOT_HPI_MODULE__ flag to mark utility files etc 2020-09-30 21:54:09 +02:00
calendar my.calendar.holidays: unhardcode calendar, detect it from the location data 2020-10-09 23:22:00 +02:00
coding my.coding.commits: fix misspelling/add warning 2021-04-07 19:59:27 +01:00
core my.core.serialize: simplejson support, more types (#176) 2021-07-08 23:02:56 +01:00
emfit cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
github my.github: some work in progress on generating consistent ids 2021-04-02 20:09:53 +01:00
google/takeout cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
jawbone cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
kython kyhton.kompress: move to core (with a fallback, used in promnesia) 2020-10-29 03:13:18 +01:00
location core: add hpi query command (#157) 2021-04-06 17:19:58 +01:00
media cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
photos cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
reading polar: backward compatibility for my.reading.polar 2021-05-29 13:26:01 +01:00
rss cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
stackexchange core: add modules_ast for more robust module collection 2020-12-11 07:02:16 +01:00
time/tz core: add hpi query command (#157) 2021-04-06 17:19:58 +01:00
twitter cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
vk cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
arbtt.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
bluemaestro.py bluemaestro: make defensive, yield Exception for measurements 2021-04-22 11:11:39 +01:00
cfg.py core: deprecate my.cfg, instead my.config can (and should be) used directly 2021-02-19 02:39:25 +00:00
common.py core: add __NOT_HPI_MODULE__ flag to mark utility files etc 2020-09-30 21:54:09 +02:00
config.py smscalls: allow multiple backup dirs (#172) 2021-05-14 01:35:36 +01:00
demo.py ok, seems that import_dir is a bit saner 2020-05-18 21:04:38 +01:00
endomondo.py core.pandas: add check for 'error' column + add empty one by default 2021-02-14 16:20:38 +00:00
error.py core: add __NOT_HPI_MODULE__ flag to mark utility files etc 2020-09-30 21:54:09 +02:00
fbmessenger.py my.fbmessenger: use pip package 2020-11-06 23:02:35 +01:00
foursquare.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
goodreads.py my.goodreads: cleanup, rename from my.reading.goodrads & use proper pip dependency 2021-03-26 05:06:53 +00:00
hypothesis.py core/influxdb: add main method to create influx measurement and fill with values 2021-04-27 20:10:10 +01:00
instapaper.py my.instapaper: add stat; add mypy checks on CI 2020-09-29 20:43:34 +02:00
kobo.py pinboard: *breaking backwards compability*, use pinbexport module directy 2021-02-18 20:46:03 +00:00
lastfm.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
materialistic.py minor requirements updates 2021-03-08 00:40:19 +00:00
orgmode.py my.orgmode: add stat function 2021-04-22 11:11:39 +01:00
pdfs.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
pinboard.py pinboard: *breaking backwards compability*, use pinbexport module directy 2021-02-18 20:46:03 +00:00
pocket.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
polar.py polar: move to top level, add page support 2021-05-29 13:26:01 +01:00
py.typed move to subfolder 2019-09-17 21:33:17 +04:00
reddit.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
rescuetime.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
roamresearch.py core: add modules_ast for more robust module collection 2020-12-11 07:02:16 +01:00
rtm.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
runnerup.py cleanup; remove unused imports 2021-04-02 08:38:06 +01:00
smscalls.py smscalls: allow multiple backup dirs (#172) 2021-05-14 01:35:36 +01:00
taplog.py core: add hpi query command (#157) 2021-04-06 17:19:58 +01:00
zotero.py my.zotero: extract top level item's tags 2021-04-13 18:05:49 +01:00