Skip to content
Commits on Sep 6, 2011
Commits on Sep 5, 2011
  1. Fixed memory leak in encoder.c ProcessObject

    committed
    Unicode buffer was not being freed after use
  2. Fix many memory leaks relating to reference counts

    committed
    Also fix functions which were returning true/false/none types but not incrementing the refcount
  3. refactor _internal_stream_load to use Decoder class

    committed
    add check to decoder init function to check stream has read() method
  4. Fix Decref issue

    committed
    Refactor py_yajldecoder_decode
Commits on Sep 4, 2011
  1. Fix python 3 support

    committed
  2. Add ability to iterate over a stream of multiple items:

    committed
    To iterate over json items written to the stdin of a python process:
    
    import yajl
    import sys
    
    for i in yajl.Decoder(allow_multiple_values=True,stream=sys.stdin):
        print i
    
    Python3 support is broken in this build.
Commits on Sep 3, 2011
  1. Removed print statement from issue_11.py

    committed
    Updated runtests.sh to run issue_11 test under python3
  2. Compiled with clang c compiler, fixed the following warnings:

    committed
    clang -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I. -Iincludes/ -Iyajl/src -I/usr/include/python2.6 -c yajl.c -o build/temp.linux-x86_64-2.6/yajl.o -Wall -DMOD_VERSION="0.3.6-38862b0"
    yajl.c:411:15: warning: incompatible pointer types initializing 'PyCFunction' (aka 'PyObject *(*)(PyObject *, PyObject *)') with
          an expression of type 'PyCFunctionWithKeywords' (aka 'PyObject *(*)(PyObject *, PyObject *, PyObject *)')
        {"dumps", (PyCFunctionWithKeywords)(py_dumps), METH_VARARGS | METH_KEYWORDS,
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    yajl.c:427:14: warning: incompatible pointer types initializing 'PyCFunction' (aka 'PyObject *(*)(PyObject *, PyObject *)') with
          an expression of type 'PyCFunctionWithKeywords' (aka 'PyObject *(*)(PyObject *, PyObject *, PyObject *)')
        {"dump", (PyCFunctionWithKeywords)(py_dump), METH_VARARGS | METH_KEYWORDS,
                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    yajl.c:331:18: warning: unused function 'py_iterload' [-Wunused-function]
    static PyObject *py_iterload(PYARGS)
                     ^
    3 warnings generated.
    
    clang -fno-strict-aliasing -DNDEBUG -g -fwrapv -O2 -Wall -Wstrict-prototypes -fPIC -I. -Iincludes/ -Iyajl/src -I/usr/include/python2.6 -c encoder.c -o build/temp.linux-x86_64-2.6/encoder.o -Wall -DMOD_VERSION="0.3.6-38862b0"
    encoder.c:316:9: warning: expression result unused [-Wunused-value]
            PyObject_INIT_VAR(op, &PyString_Type, size);
            ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    In file included from encoder.c:32:
    In file included from /usr/include/python2.6/Python.h:81:
    /usr/include/python2.6/objimpl.h:159:29: note: instantiated from:
        ( Py_SIZE(op) = (size), PyObject_INIT((op), (typeobj)) )
                                ^
    encoder.c:316:9: note: instantiated from:
            PyObject_INIT_VAR(op, &PyString_Type, size);
            ^                 ~~
    encoder.c:316:27: note: instantiated from:
            PyObject_INIT_VAR(op, &PyString_Type, size);
                              ^~
    1 warning generated.
  3. Add reset() method to decoder

    committed
    Remove actions from _internal_decode that reset the parser state
Commits on Aug 21, 2011
  1. calling len() against the decoder object returns the number of decode…

    committed
    …d objects in the internal buffer.
  2. Move towards decoding multiple items

    committed
    * Store decoded objects in a list
Commits on Aug 20, 2011
  1. Incorporate python3 undefined symbol fix from:

    committed
    rickeyski@cf3c29d
    
    Move IssueTwentySevenTest dict into python2 to prevent python3 test from bailing on loading the test suite
    
    Update IssueTwentySevenTest to only run on python2. (probably want to run this on python3 too).
  2. * Free prarser on error

    committed
    * updated build instructions
Commits on Aug 17, 2011
  1. moved yajil to 2.0.2

    committed
Commits on Apr 27, 2011
  1. @teepark
  2. @teepark

    handle the case of a unicode argument to loads() differently

    teepark committed
    unfortunately this just needs to be inlined, a separate utf8_z_hash
    function won't work. the reason being that PyString_AsStringAndSize
    gives access to the string object's internal buffer rather than copying,
    and that string object was being decrefed away at the end of the
    function, but the buffer we got out of it still needed to be usable.
  3. @teepark
  4. @teepark
Commits on Oct 19, 2010
  1. @rtyler

    make yajl.(De|En)coder subclassable. Add default methode to Encoder and

    Igor committed with rtyler
    modify ProcessObject to mimick simplejson's JSONEncoder behaviour when
    encountering unknown types
Commits on Sep 12, 2010
  1. add tests for tuples and generator encoding

    Igor committed
  2. change ProcessObject to treat lists, tuple and generators as iterator…

    Igor committed
    …s when serializing
Commits on Aug 18, 2010
  1. @rtyler

    Bump to the latest yajl

    rtyler committed
    Change-Id: I75624cd1f1d73f686c2c200406fcd574692c421f
Commits on May 2, 2010
  1. @teepark @rtyler

    Prevent SIGSEGV when encoding objects that refer to themselves

    teepark committed with rtyler
    Also, there were a few places missing checks for yajl_gen_in_error_status
    
    http://github.com/rtyler/py-yajl/issues#issue/18
    
    Signed-off-by: R. Tyler Ballance <tyler@monkeypox.org>
Commits on Apr 11, 2010
  1. @rtyler

    Skip IssueThirteenTest on Python 2.4/2.5

    rtyler committed
    Change-Id: I9cffc2e3876cb27a99acba9786e1a9ddf030cf5d
  2. @rtyler

    Add `yajl.monkeypatch` to smuggle yajl into sys.modules['json']

    rtyler committed
    http://github.com/rtyler/py-yajl/issues#issue/13
    
    Change-Id: I46924a0a2379c37a2cfc07def071ce59a22761d0
  3. @rtyler

    Add a __version__ attribute onto the module

    rtyler committed
    When building a module from inside the git tree, the version
    will also be "tagged" with the latest commit hash
    
    Change-Id: Ic4b3d4072afcfccbb7bcbe09afc49f950d25e535
  4. @rtyler

    When dealing with PyLong objects, pull them out as long long's and us…

    rtyler committed
    …e yajl_gen_number()
    
    On 32-bit machines, a PyLong_AsLong() call on a 64-bit number will fail,
    to remedy this we pull out the `long long` and use that to generate a buffer
    to pass into yajl_gen_number() which will handle it appropriately
    
    http://github.com/rtyler/py-yajl/issues#issue/16
    
    Change-Id: Iec800f6e765e14041d7a264e3fdecdbb15cc986d
  5. @rtyler

    If ProcessObject() gives us a bad status, check to see if we have a P…

    rtyler committed
    …ython exception to raise
    
    In the case of an OverflowError (see: issue #16), we want to raise *that*
    exception instead of raising our own TypeError
    
    Change-Id: I5b0cf5903b4cabe87df14137aa5d6c944ab3a270
Something went wrong with that request. Please try again.