Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-28 Thread Christopher Allan Webber
Hm. I've found a bug with this patch: #+begin_src python return [['foo', 'bar', 'baz'], [a, b, None of the above], ['1', 2, 3]] #+end_src #+results: | foo | bar | baz| | a | b | hline of the above | | 1 | 2 | 3 | This also replaces the word None

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-28 Thread Eric Schulte
Hi Chris, Thanks for catching this. I've just pushed up a patch which should fix the issue. Best -- Eric Christopher Allan Webber cweb...@dustycloud.org writes: Hm. I've found a bug with this patch: #+begin_src python return [['foo', 'bar', 'baz'], [a, b, None of the above], ['1', 2, 3]]

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-28 Thread Christopher Allan Webber
Works perfect now... Thanks! :D Eric Schulte schulte.e...@gmail.com writes: Hi Chris, Thanks for catching this. I've just pushed up a patch which should fix the issue. Best -- Eric Christopher Allan Webber cweb...@dustycloud.org writes: Hm. I've found a bug with this patch:

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-27 Thread Eric Schulte
Hi, OK, I've applied this patch. Christopher Allan Webber cweb...@dustycloud.org writes: Eric, Looks good to me! It's abusing the None type's meaning a little, but I think it's acceptable enough. (If you think of hlines as rows that are not rows, you can trick yourself into thinking it

[Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-26 Thread Christopher Allan Webber
Hello all, I was going through the tutorial and testing the :hlines yes feature as described in the info manual. Unfortunately, the example given no longer seems to work for python: #+tblname: many-cols | a | b | c | |---+---+---| | d | e | f | |---+---+---| | g | h | i | #+source: echo-table

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-26 Thread Eric Schulte
Hi Christopher, Thanks for pointing this out, this is an error in the documentation, which I will update. The code you posted should generate the error you have received. Currently the only language which can handle hlines is emacs-lisp, all other languages will result in errors like the one

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-26 Thread Eric Schulte
Hi Christopher, I'm certainly no Python expert, but I implemented your idea of converting hlines to and from None's (patch below [1]), and it seems to work (under some definition of work). See the following example with the new behavior. --8---cut

Re: [Orgmode] Org-babel `:hlines yes` no longer working for python

2010-06-26 Thread Christopher Allan Webber
Eric, Looks good to me! It's abusing the None type's meaning a little, but I think it's acceptable enough. (If you think of hlines as rows that are not rows, you can trick yourself into thinking it is perfectly pythonic :)) - cwebb Eric Schulte schulte.e...@gmail.com writes: Hi