PlYaml is the code name for the project to port PyYaml to Perl.

The actual Perl module name will be YAML.pm and will replace the age old YAML.pm that is on CPAN now.

DOWNLOAD: You can check out the latest code from http://svn.yaml.com/repo/trunk/PlYaml/

PlYaml is being sponsored by a TpfGrant. Yay!

Work Log

26Nov6

cmeyer and ingy continue to hack away on the loader classes. xitology gives us a LoaderClassExplanation.

13Nov6

More porting. Implemented YAML::Nodes. Still trying to get t/01-load.t to pass; to load a simple document. This uses a lot of the code even on a very small doc.

10Nov6

Another brick in the wall. Just hacked away at YAML::Parser.

9Nov6

Finally got going on PlYaml again. Sorry about the delay. I had two big vacations with a bike race and a marathon in there. Hopefully I should be back on target. Tonight I paired with an old friend Colin Meyer. I gave him the commit bit and we made progress on the Parser...

17Sep6

The mindless porting of YAML::Scanner is about 50% done. It is tedious work but the good news is that Python ports to Perl very easily.

I also started spiking the loader->constructor->composer->parser->scanner->reader layers of the Load Stack so that I can get the simplest of YAML documents to load(). This will take some time but I've drilled down from the loader to the parser, so progress is being made.

15Sep6

Started writing new documentation for YAML.pm. Writing doc early helps you think about what you're doing and keeps your design honest.

The coolest thing I cam up with today is the way the Loader stack chains together. This has the combine effect of making the code really clean and also making all the classes configurable from the top level. Getting this right was really bugging me, but now I've gotten that out of the way. Yay. Tomorrow is Saturday. A good day to try and spike porting the Loading stack. Wish me luck!

14Sep6

Ported the simple YAML::Events and YAML::Tokens modules today. It seems that in Python you define a ton of classes. This is not so bad because they don't mess up the global namespace. They are scoped within a module, and you import them into other modules. Anyway in Perl I needed to rejigger YAML::Base in order to make these inline packages have a presence in %INC. That way I can use the 'use InlineClass? -base;' syntax. The only downside is flooding %INC with 50 odd YAML classes. It shouldn't matter, but as always in Perl, it will ruffle someone's feathers. Sigh.

Well it would be premature of me to move away from this onslaught of micro-classes just yet. I can refactor later.

Porting is dull work. Sometimes dull work can be interesting though since it frees the mind to think about other things.

I coined the term TestML this week. TestML is the format that all the YAML tests will be encoded in. It is basically Test::Base format. It will be cool to see ports of TestML in all these YAMLy languages.

13Sep6

Talked to Kirill today at some length. After looking at the code and giving thought, it seems that I will probably organize the class structure differently than PyYaml. We'll see...

Made more progress on YAML.pm and YAML::Base. More tests.

12Sep6

Today I started work on JsYaml. In a way it makes sense to work on them in parallel, so I'm thinking about the same things at the same time. See the JsYaml page for blogging about that.

11Sep6

Start things off creating a YAML dist directory with a simple Makefile.PL and lib directory.

Take each of the classes in pyyaml and create a Perl module equivalent. I got the idea to put the original python source into the DATA section. Then I move it up section by section as I port it. I'll leave the python lying around as inline comments.

Write a test to simply check that all the Perl source code compiles.

Preamble

I'm starting this log to keep track of how I approach this problem. The log entries will be in reverse chronological order.

So finally I have my infrastructure set up. The first thing I needed was a working server to host yaml.com. I chose to use yaml.com for this project (with pointers to all the yaml projects) simply because I owned the domain and wasn't using it for anything else.

The infrastructure consists of an svn repository (http://svn.yaml.com/repo/trunk/) and this Trac site.