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" writes: > Hi Chris, > > Thanks for catching this. I've just pushed up a patch which should fix > the issue. > > Best -- Eric > > Christopher Allan Webber writes: > >> Hm. I've found a bug with this patch: >> >> #+begin_src python >> return [['foo

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 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]] > #+end_src

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-27 Thread Eric Schulte
Hi, OK, I've applied this patch. Christopher Allan Webber 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 is perfectly > pyth

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" writes: > Hi Christopher, > > I'm certainly

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 here---start---

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

2010-06-26 Thread Christopher Allan Webber
Hey Eric, Thanks for the super helpful reply! Out of curiosity, is it likely that we will ever get hline support in Python and etc? I've been pondering how it might be done, and maybe it could be like this, using a '|-' string instead of a list for the row: [['a', 'b', 'c'], '|-', ['d', 'e', 'f

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 you

[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 #