customerio/customerio-python — pull request #6 by orblivion (2013-07-30 23:10:22+00:00)
Title: Adds json without requests module

This is basically a small fix on top of https://github.com/customerio/customerio-python/pull/3

In his pull request, ryanwitt opted for Ruby's querystring array syntax. I'm not sure why, since full json has strictly more utility, so I opted for the full json. In any case, the code that pull request, as of now, does not work, and as of now the code in this one does, at least for me. This code specifically works:

cio.track(customer_id="test_123", name="event_name", lol=['a', 'b', {3:'c'}])

I also took out the ObjectEncoder thing in ryan's pull request, I'm not sure what that was aiming to do. Hopefully it wasn't something that I didn't account for. Though, it looks like it had a name error in it anyway, so I don't know if it ever ran? I commented on that particular commit (made by EButlerV in this case) asking if there was some important reason for it.