Misaka 1.0.2

09 Apr 2012

Time for a new release. After spending almost all my free days on getting things to work it's done now. The changes include fixes for Unicode, Python 3, Windows/Visual Studio, error reporting and a nice set of unit tests.

The documentation does not use Sphinx anymore. I've written a small utility myself to generate the documentation and it's much simpler. :)

Get the files from PyPi or Github and read stuff (documentation) here!

Status Report #1

20 Jan 2012

In a week or two most of the work at school will be done and I'll be able to work more on my projects again. And after this semester I'll start with my (academic) minor, Digital Arts. I'm sure it won't take up all my time.

It's not hard to work on something and forget about the other thing you're working on. And some scribbles in my notebook aren't going to prevent that. So I'll put a status report on my blog so I won't forget about it. It also kinda forces me to be less lazy, because I post this in a public place. And forces me to do stuff.

Thrift

I'm working on a Thrift client for Tornado. It took a bit longer to get started than expected, but I've figured out how it works (mostly) now and started to document the binary protocol.

After the documentation is done I'll start with making a client that communicates with the Thrift server in the tutorial code. Once that's done and once I figured out how everything should be structured I'll start with a IDL compiler.

I haven't thought out that last one yet, but after looking through the Python code that Thrift generates I saw that it wasn't easy to make it work for Tornado. So I guess I'll have to make something that generates Tornado friendly code. Luckily the IDL doesn't look to complex.

Misaka

All functionality of 1.0.0 is done, but it hasn't been tested completely and the documentation needs to be updated. There's probably also need for a separate Python 2 and 3 package, because the C code that Cython generates is different for 2.X and 3.X.

Momoko

I think it's time for 0.4.1 soon. There are not a lot of changes, but recovery from closed connections is a nice one. I'm going to look into a minor issue regarding error handling and then 0.4.1 will be released.

FluxBB/php-utf8

There are some tickets assignment to me and I'll have to update a number of things in php-utf8.

Franz converted all unit tests to PHPUnit and I added namespaces to everything. I'll now have to reformat all code according to the code formatting guidelines (I like neatly formatted code). And while I'm at it I'll have to check the code too.

I'm also thinking of making all of php-utf8's documentation in Sphinx. It works perfectly for Python-based projects. So why not for PHP-based projects?

Momoko 0.4.0

15 Dec 2011

A new release of Momoko! This time it's 0.4.0. It took a while, but it's done now. Here are the changes:

Grab it from PyPi or from Github!

Misaka 1.0.0 Beta 1

08 Dec 2011

It's been a while. Like a few months. And I've been working on duplicating Redcarpet's functionality. I think everything should work now, but I still need to test everything properly and that's why I'm releasing a beta. And the API documentation is also lacking, but the the code itself is understandable enough.

My understanding of C is still limited, but thanks to Redcarpet's source code I figured out how to implement everything. Not everything is in C. The largest part is actually done in Cython. Which is a great tool. I've also included the C code that's generated by Cython, so you don't have to install Cython to compile Misaka. Only when you want to regenerate the C code (in that case you use setup_cython.py).

Besides the big API change, Misaka now also accepts Unicode strings, but the side effect is that it's faster in Python 3. And Python 2 is a lot slower in the benchmark, but you won't really notice it (if you're not parsing a large document 10,000 times).

Here's a small example (the old API is also available).

from misaka import Markdown, HtmlRenderer, SmartyPants

class BleepRenderer(HtmlRenderer, SmartyPants):
    pass

md = Markdown(BleepRenderer())
print(md.render('Some "stuff" here'))
# <p>Some &ldquo;stuff&rdquo; here</p>

The classes are located in misaka.pyx and all the callbacks you can implement in your own renderer are listed in wrapper.c. That's quite unfriendly documentation at the moment, but I'm planning to change that.

For now just fetch the code from the Github repository. If something is not working, please report it.

Have fun.

Momoko 0.3.0

07 Aug 2011

Today I present a new release of Momoko, version 0.3.0. It's been a while ago since I released 0.2.0 (three months ago). I'll blame on school and my vacation. ;)

The following changes have been made:

The nicest addition is that you can now query the database without using callbacks. This is possible by using adisp. Here are some examples:

cursor = yield self.db.execute('SELECT 42, 12, 40, 11;')

cursors = yield self.db.batch({
    'query1': ['SELECT 42, 12, %s, %s;', (23, 56)],
    'query2': 'SELECT 1, 2, 3, 4, 5;',
    'query3': 'SELECT 465767, 4567, 3454;'
})

cursors = yield self.db.chain((
    ['SELECT 42, 12, %s, 11;', (23,)],
    'SELECT 1, 2, 3, 4, 5;'
))

As you can see there is a yield keyword. You also need to put an extra decorator on your get/post/somethingelse function, momoko.process. That's all.

View the updated documentation on momoko.61924.nl and download the new release from PyPi.

Have fun.

See older posts at the archive →