Itamar Turner-Trauring

Results 420 comments of Itamar Turner-Trauring

If you have a custom JSON encoding class: ```python def test_mytest(self): # Check that encodes using custom JSON encoder (and then decodes with default json.loads): logs = logs_for_pyunit(self, encode=CustomEncoder().encode) #...

Thanks for the PR! See #426 for some questions I have about motivation.

I'm guessing #427 was a proposed solution? Just so I understand the use case better, could you share some sample code demonstrating what you're trying to do?

So far orjson seems a little fast, but not as much as expected. Should also try rapidjson. Another alternative might be a different storage format, e.g. http://zderadicka.eu/comparison-of-json-like-serializations-json-vs-ubjson-vs-messagepack-vs-cbor/ suggests CBOR is...

More thorough benchmarking suggested orjson is definitely faster: https://pythonspeed.com/articles/faster-json-library/

Hi, 1. Half curiosity, half relevant: what are you using Eliot for? 2. Destinations are just a callable that takes a dictionary. 3. stdlib logging `Handler` expect `logging.Record` objects. So...

Logging levels would plausibly be INFO by default, ERROR for a failed action message or a traceback.

As next steps I would suggest: 1. If the above is enough information (and if you need more info, happy to explain it more detail), implement something for internal use,...

I'd be interested in seeing the code, yes, and understanding how general purpose it is. E.g. would it work for any ElasticSearch backend? I would recommend BTW reusing/wrapping the JSON...

Thanks for the bug report! Seems like supporting `pytest` is the thing to do, one way or another.