Re: [O] ob-python newline & indentation behavior

2017-11-26 Thread Jack Kamm
tart another thread to discuss this? Jack On Tue, Nov 21, 2017 at 8:28 AM, Jack Kamm <jackk...@gmail.com> wrote: > Yes, I'm starting to see now how difficult it is to properly support > ":session :results value". I would vote to remove it from ob-python... > > I thin

Re: [O] ob-python newline & indentation behavior

2017-11-26 Thread Jack Kamm
> [1] https://github.com/gregsexton/ob-ipython > > Best, > Ista > > On Tue, Nov 21, 2017 at 3:28 AM, Jack Kamm <jackk...@gmail.com> wrote: > > Yes, I'm starting to see now how difficult it is to properly support > > ":session :results value". I would

Re: [O] Git repository error

2017-12-18 Thread Jack Kamm
Josiah Schwab writes: I'm having the same issue as Josiah, are others able to pull from the git repo? Jack > Hello, > > For about the past day, I've been getting this error upon running 'make > update' from my local Org repository: > > fatal: read error: Connection reset

[O] ob-python newline & indentation behavior

2017-11-18 Thread Jack Kamm
cs-orgmode/2015-03/msg00505.html The patch follows the python.el behavior of using a temporary file and executing that from the shell. Could this patch, or something similar, be incorporated into org-mode, to fix this behavior? Thanks, Jack Kamm

Re: [O] ob-python newline & indentation behavior

2017-11-20 Thread Jack Kamm
Hi Kyle, In response to this: I can't think of a good solution, though. Stepping back a bit, I think > it's unfortunate that python blocks handle ":results value" differently > depending on whether the block is hooked up to a session or not. For > non-sessions, you have to use return. Using

Re: [O] ob-python newline & indentation behavior

2017-11-21 Thread Jack Kamm
:results value" unchanged for now. Sorry for sending this twice Kyle, forgot to reply all. On 21 Nov 2017 4:04 am, "Kyle Meyer" <k...@kyleam.com> wrote: > Jack Kamm <jackk...@gmail.com> writes: > > > In response to this: > > > >> I can't think

Re: [O] ob-python newline & indentation behavior

2017-11-18 Thread Jack Kamm
block to the tmpfile, unless it is indented. I've never contributed before so would appreciate any comments on this patch, and how to get it accepted. Cheers, Jack. >From a5d553ece9f6ee35cd1e273e554a21a19e80ec3c Mon Sep 17 00:00:00 2001 From: Jack Kamm <jackk...@gmail.com> Date: Sat, 18 No

Re: [O] ob-python newline & indentation behavior

2017-11-18 Thread Jack Kamm
ight Here is the new version of the patch: >From f009da37d3b7e2730abb8cbb10f4d07b3d456dd8 Mon Sep 17 00:00:00 2001 From: Jack Kamm <jackk...@gmail.com> Date: Sun, 19 Nov 2017 07:13:56 + Subject: [PATCH] Squashed commit of the following: commit d1fe88a9f61a8e7082f08b7c190a29737bb655d5 A

[O] recent ESS commit breaks org-babel-R session output capture

2018-07-02 Thread Jack Kamm
Hello all, An ESS commit last week broke org-babel-R session output capture. In particular, the following no longer works: #+BEGIN_SRC R :session :results output print("hello") #+END_SRC The code runs but org-babel fails to capture the output and place it in the buffer. I think the

[O] Asynchronous session evaluation

2019-06-01 Thread Jack Kamm
ing just a subset of languages initially, then gradually increasing the number of supported languages over time. >From f1c198a85666507164e9a97a7e0758f1d5dcf126 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Sat, 1 Jun 2019 12:26:13 -0700 Subject: [PATCH] Add asynchronous Babel c

Re: [O] Asynchronous session evaluation

2019-08-17 Thread Jack Kamm
Hello, Nicolas Goaziou writes: > This sound interesting. I hope this is not going to bit-rot while we're > waiting for feedback. Since my last e-mail, I ported this code to a separate package here: https://github.com/jackkamm/ob-session-async I've been slowly ironing out various kinks, and

Re: [O] Asynchronous session evaluation

2019-08-24 Thread Jack Kamm
In case any org-babel R users are interested, this package is now basically ready to use, and I've added a Readme on how to use it: https://github.com/jackkamm/ob-session-async I plan to add more languages, and to eventually contribute this functionality back to org-mode when it's ready.

Re: [O] org-agenda-todo obliterates my windows

2019-08-29 Thread Jack Kamm
> Is there any way to just open my org-agenda-todo items in the /current/ > window, or even just any window that already happens to be open, without > modifying, splitting, or above all deleting any others? Does customizing the variable org-agenda-window-setup (e.g. by setting it to

Re: Publish to PDF on Linux: An impossible task?

2019-11-11 Thread Jack Kamm
John Hendy writes: > By "LaTeX" I mean "that which is necessary to have a functioning latex > system." If by lower-level you mean the ecosystem itself vs. compiling > errors, completely agree. Clearly some core components are missing. > For example, the texmf.cnf file is provided by the arch

Re: [O] Cannot display local images with orgmode under macOS

2019-11-17 Thread Jack Kamm
Hello, I want to report that this bug is not specific to macOS, and also affects Linux. Specifically, I am running Archlinux-packaged emacs 26.3, and am encountering this same issue. Ever since commit 48da60f47a77f4b99b4160fa620f258896ff4da3, org-mode no longer displays inline images for me. I

Re: [O] Cannot display local images with orgmode under macOS

2019-11-17 Thread Jack Kamm
ork, maybe because imagemagick tries to create a 0-width image. The attached patch reverts to the old behavior of only using imagemagick when width is non-nil, fixing the bug introduced by 48da60f47. >From cebf2b4001015dabc74364ac2a5bf2ed64c07ab0 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Sun

Re: restore window configuration after org-edit-src-exit

2019-12-17 Thread Jack Kamm
I'd like to add a vote for the old behavior. I only recently noticed the new behavior, and agree with Richard that it's inconvenient. I think many of us missed this change because it wasn't in 9.2. In particular, I'd propose to make the old behavior the default, and hide the new behavior behind

Re: restore window configuration after org-edit-src-exit

2019-12-17 Thread Jack Kamm
Sorry for the noise, but I just had another thought: Rather than adding a new option, how about we make the behavior dependent on the value of org-src-window-setup? Basically, when org-src-window-setup is current-window, it never makes sense to restore the original layout. But when

Re: Displaying remote images

2019-12-07 Thread Jack Kamm
After test-driving this patch for a bit, the main issue I foresee is that this can potentially hang Emacs if loading a lot of images over a slow SSH connection. This was also discussed in the previous thread from 2014. I plan to mitigate this with an option to enable/disable/cache the remote

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-10-27 Thread Jack Kamm
Your code block looks fine to me. The typical R code block headers I use is as follows: :session :results output graphics :file path/to/file.png :exports results :eval never-export One thing I've noticed, if I have an existing graphics device open, it can mess up plots when executing an

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-10-27 Thread Jack Kamm
John Hendy writes: > On Sun, Oct 27, 2019 at 11:31 PM Jack Kamm wrote: >> >> Your code block looks fine to me. The typical R code block headers I use is >> as follows: > > Did you try to reproduce my example, by chance? I've just now tried executing/exporti

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-10-28 Thread Jack Kamm
> This is with emacs -Q and loading the minimal config from the initial > email. Any ideas on where I might look next? Sorry, I don't have many ideas here. Have you checked that ggplot works fine in a regular R session? I tried again with emacs -Q and the minimal config below and it still

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-10-29 Thread Jack Kamm
> Closing the loop. I can confirm that my example works on this commit > (one before the relevant change) (thanks, Chuck!). > > commit ed9bdfd220b75233e5bae2ef39164d14624060fa (HEAD) > Merge: 0954d4c25 0ae2e656d > Author: Marco Wahl > Date: Fri Oct 5 00:54:19 2018 +0200 > > Completely stumped

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-10-28 Thread Jack Kamm
> 2) why does this [still] work for Jack? (Jack, what's M-x org-version for > you?) I tested on my laptop and desktop, both work for me, they are running the following 2 versions of org: Org mode version 9.2.4 (9.2.4-13-g9a543b-elpaplus @ /home/jack/.emacs.d/elpa/org-plus-contrib-20190729/)

Re: Refresher on including R/ggplot2 output via latex/pdf?

2019-11-30 Thread Jack Kamm
> 2) why does this [still] work for Jack? (Jack, what's M-x org-version for > you?) This thread is old, but I finally realized why we were having discrepant results. It's because I was installing org-plus-contrib from org-mode ELPA via package.el, which pulls from "maint" branch. Since I've

Re: Opening org Agenda whenever opening GNUs:

2019-11-25 Thread Jack Kamm
> I'd like to be able to have it split vertically, since it otherwise > obscures my view. How can I do that? I haven't tested this, but I think the following would accomplish what you want: (defun my-instant-agenda () (let ((org-agenda-window-setup 'current-window)) (select-window

Re: Displaying remote images

2019-11-28 Thread Jack Kamm
Hi Brian, > Emacs and OrgMode do many great things; but, the focus has always been, at > it's core, the most powerful editor and stateless organizing software--it's > not a browser of dynamically generated Internet pics--Emacs W3 was created > to do that, and it hasn't been updated in

Re: Displaying remote images

2019-11-28 Thread Jack Kamm
e Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Thu, 28 Nov 2019 17:45:56 -0800 Subject: [PATCH] org: display remote images --- lisp/org.el | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 90f222c8b..dc7bcc7aa 100644 --- a/lisp/org

Displaying remote images

2019-11-28 Thread Jack Kamm
When trying to display a remote image file in an org-mode buffer, I only see a blank square instead of the image. This is a longstanding problem, and there was an attempt to patch it in 2014, but the patch was never accepted: https://lists.gnu.org/archive/html/emacs-orgmode/2014-11/msg00583.html

Re: restore window configuration after org-edit-src-exit

2019-12-22 Thread Jack Kamm
Hi, > I think any value that modifies the current layout ought to restore it: > - `split-window-below' > - `split-window-right' > - `reorganize-frame' > > OTOH, values that use the current layout should not restore it > afterwards: > - `current-window' > - `other-window' > - `other-frame' > >

Re: Powershell scripting with org-babel

2020-02-10 Thread Jack Kamm
Hi Klaus, MS Window writes: > There is no explanation there I should put the configuration. The org-babel > documentation is too brief for me as beginner to understand. First, save that file somewhere. Then, in your emacs config, add the directory containing ob-powershell.el to the

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-23 Thread Jack Kamm
Hi Stefan, Stefan Nobis writes: > What about a third collection option 'none' and make this the default? A variant on this idea, would be to instead have the third collection option be 'default', which would stand for a language-specific default. For example, ":results default" could be

Re: correct remote path handling

2020-02-25 Thread Jack Kamm
Hi Felipe, Felipe Lema writes: > I bumped into a problem running src blocks using a remote (tramp) :dir. I've > looked into it and found that the problem is that a temporary file is passed > as a remote path to the remote process (temp file should be local to remote > process). Thanks for

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-29 Thread Jack Kamm
Hi Bastien, Bastien writes: > thanks for your thoughtful inputs. I've now removed the option. I think it's good you removed the option. However, it looks like the behavior now is to return the output, instead of the exit code, when ":results value". According to my reading of this thread,

Re: correct remote path handling

2020-02-29 Thread Jack Kamm
Hi Felipe, It looks like you've made some quite substantial changes to ob-shell. I think it would be a good idea to split this up into 2 patches, and to start a new thread for the ob-shell patch. I'm not as familiar with ob-shell, and it's also had some work lately. So it'd be good to get some

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-29 Thread Jack Kamm
Sorry, I was confused about this: > According to my reading of this thread, most of the commenters were in > agreement that we should keep the original behavior and return the exit > code, as we do in 9.3. Actually, it looks like ":results value" does return the exit code. I just got confused

Re: Bug or not a bug? dot expansion in ob-shell

2020-03-01 Thread Jack Kamm
As someone who doesn't really use ob-shell, I've made too much noise in this thread, and am intending this to be my last comment here... I think it's a bad idea that ":results value", and not specifying ":results", give different behavior. In my own Org-babel files, I usually have a header line

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-29 Thread Jack Kamm
Hi Tom, Tom Gillespie writes: > First a disclosure, I would be very unhappy if option 1 were selected, > it would require me to make a whole bunch of changes and try to find > an option to revert to the current default behavior. Wasn't option 1 already the default behavior, until the changes

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-29 Thread Jack Kamm
Hi Tom, Tom Gillespie writes: > As with many things in emacs, I sometimes feel like I'm loosing my > mind, or loosing track of just exactly what variables are set You're not losing your mind. After some further testing I find that you're right, and my understanding of the situation was

Re: ob-python.el: questions about output

2020-02-23 Thread Jack Kamm
Hi RC, R C writes: > 1. Is it possible to have both types of output displayed from a single src > block to avoid having to duplicate the src block, using :exports results > for one and :exports both for the other? No, there's no option to output both ":results output" and ":results value". If

Re: ob-python.el: questions about output

2020-02-23 Thread Jack Kamm
Sorry, my email had a typo: > #+begin_src python :session session1 :results output > x > #+end_src That should be ":results value".

Re: ob-python.el: questions about output

2020-02-24 Thread Jack Kamm
Hi RC, R C writes: > My python src blocks often have both graphical output as well as the > results of some numerical calculation displayed using print statements. > > When exported I would like the line: return 'img/ex1.png' not to be > included in the listing of the src block. > > Also, the

Re: ob-python.el: questions about output

2020-02-24 Thread Jack Kamm
Hi Eric, "Fraga, Eric" writes: > Longer term, better would be an implementation of :prologue and > :epilogue options for python src blocks like we have for Maxima. It > would probably make sense to provide these options for most if not all > src blocks? This sounds interesting. Do you know of

Re: [PATCH] Fix several issues with python session value blocks

2020-01-26 Thread Jack Kamm
> thanks for your patch - Kyle is on it, but IIRC we do not have a > maintainer for the ob-python.el file. > > Would you like to take this in charge? Or someone else? Sure, I would be interested in this, if it's helpful. I need an account for code.orgmode.org, and whatever commit permissions

Re: [PATCH] Fix several issues with python session value blocks

2020-01-22 Thread Jack Kamm
Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 20 Jan 2020 17:40:22 -0800 Subject: [PATCH] ob-python: Fix several issues with :session :results value * lisp/ob-python.el (org-babel-python-evaluate-session): Fix a few related issues with :session :results value blocks, including broken if-e

Re: emacs build command for org-files

2020-01-27 Thread Jack Kamm
John Kitchin writes: > If there was a lispy version of make that made this possible, I would > use it. This is an aside, but GNU Make can use Guile Scheme as an embedded extension language: https://www.gnu.org/software/make/manual/html_node/Guile-Integration.html I don't think this solves any

Re: Bug: R src blocks fail to produce link to graphics file [9.3 org-plus-contrib-20200127]

2020-01-27 Thread Jack Kamm
> #+begin_src R :results graphics :file test.jpg > plot (1:10) > #+end_src It should now be ":results graphics file". This behavior changed in Org 9.3, see https://orgmode.org/Changes.html (:file header argument no longer assume "file" :results).

Re: Bug: R src blocks fail to produce link to graphics file [9.3 org-plus-contrib-20200127]

2020-01-27 Thread Jack Kamm
> Is the rationale explained anywhere? After a bit of poking around, it looks > like using the `:file` flag without a `file` argument to results doesn't do > anything (no file is created), nor does the reverse. That is, unless you use > both the `file` argument and the `:file` option, nothing

Re: customizing Org for legibility

2020-02-01 Thread Jack Kamm
> One thing I don't understand: It seems that GUI and terminal modes are > completely different. Rather than constrain GUI defaults to terminal > limitations, it makes sense to gracefully degrade them when a terminal > is detected. I assume that terminal users don't care about variable > pitch.

Re: [PATCH] Fix several issues with python session value blocks

2020-02-03 Thread Jack Kamm
Kyle Meyer writes: >> I'd like to do the honors of making my first push to the repo :) So >> please let me know if you're fine with me to proceed. > All good from my end :> Thanks -- I've pushed to master :D

Re: [PATCH] Fix several issues with python session value blocks

2020-02-03 Thread Jack Kamm
k, so that the error would appear in the REPL (which was the general behavior for shell, R, and Julia errors). >From 572ca9fd8c89720acd8d7d2ace8bb3c0be3d288e Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 20 Jan 2020 17:40:22 -0800 Subject: [PATCH] ob-python: Fix several issues with :s

Re: org-babel-load-file support elisp

2020-02-03 Thread Jack Kamm
Tim Cross writes: > All other language specifiers comply to the pattern of source block > languages being the language major mode name without the '-mode', but > there is no elisp-mode. Sorry to be pedantic, but I think shell source blocks are another exception here. They can use various

Re: A few changes to test in master

2020-02-03 Thread Jack Kamm
Bastien writes: > - M-x org-table-electric-header-mode RET will display the first row > of the table at point in the header line when the first row is not > visible anymore. This is great, it's a huge quality-of-life improvement for working with long tables. Below are some issues I noticed

Re: org-babel strange html print in R

2020-02-07 Thread Jack Kamm
Dominique Dumont writes: > On my system, org-mode 3.6.1 provides the expected table. My system produces the expected table as well (org 9.3.2, R 3.6.2). --Jack

Re: A few changes to test in master

2020-02-07 Thread Jack Kamm
Hi Bastien, Bastien writes: >> The variable `org-table-header-line-p' doesn't seem to have any effect >> for me, I find that I need to call "M-x org-table-header-line-mode" even >> when it's set. > > Should be fixed now. Confirmed, it works correctly for me now. >> Also, "M-x

Re: A few changes to test in master

2020-02-07 Thread Jack Kamm
olors in >> the default face? > > Sure - would you like to suggest a patch for this? Sure, see the patch below. >From 2922d104b3508b1269c17ad0a28103bd912e308b Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Fri, 7 Feb 2020 18:04:59 -0800 Subject: [PATCH] org-faces.el: Add foreground col

Re: org-babel strange html print in R

2020-02-07 Thread Jack Kamm
Hi Jeremie, > Thanks for the info. > Unfortunately I couldn't identify the issue > I updated R and org (org 9.3.2, R 3.6.2). > but I'm still getting [the error] Sorry, I missed the initial property line where you set the ":session" header argument. When I set the ":session" header argument, I

Re: Displaying remote images

2020-01-24 Thread Jack Kamm
ater, and if the RAWFILE argument is set, then they'd either see the raw file, or get a message asking to revisit the file normally. >> +(`skip-warn (message >> + (concat "Set `org-display-remote-inline-images'" >> + " t

Re: [PATCH] Fix several issues with python session value blocks

2020-02-04 Thread Jack Kamm
Hi Bastien, Bastien writes: > Thanks a lot! Nitpicking, there is this new warning: > > In toplevel form: > ob-python.el:309:1: Warning: Unused lexical variable ‘last-indent’ > > Can you fix it? Oops, sorry for letting that slip through, and

[PATCH] (Tiny) Tweak Python session null return value

2020-02-17 Thread Jack Kamm
ty) result instead of "None". [0] https://lists.gnu.org/archive/html/emacs-orgmode/2020-01/msg00190.html Best, Jack >From 0b44c3f1c7454e7948cd34eb02995924046b6976 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 17 Feb 2020 08:11:49 -0800 Subject: [PATCH] ob-python: Sessi

Re: [PATCH] (Tiny) Tweak Python session null return value

2020-02-17 Thread Jack Kamm
Hi Bastien, > I've seen you update the NEWS entry, which is good: is there a way to > present the enhancements in the "* New features" section? If you feel > like it, please advertize the enhancements there too. Given John's feedback, I now think it's better to put off this change to 9.5, if at

Re: [PATCH] (Tiny) Tweak Python session null return value

2020-02-17 Thread Jack Kamm
Hi John, John Kitchin writes: > I think None is correct. If you don't specify a return value in Python, > then a function returns None. I would expect that to happen in a Python > block too. Hmm, OK, thanks for your intuition, it's useful feedback. Working this out loud, I was considering the

Re: Bug: R src blocks fail to produce link to graphics file [9.3 org-plus-contrib-20200127]

2020-02-17 Thread Jack Kamm
Hi Tyler, >> The documentation for ob-R is now incorrect: >> >> https://orgmode.org/worg/org-contrib/babel/languages/ob-doc-R.html > > Yes, also that page could use some other updates, e.g. there are some > dead links in there. Just saw that you updated the docs a few days ago. Thanks for

Re: [PATCH] (Tiny) Tweak Python session null return value

2020-02-17 Thread Jack Kamm
Hi John, John Kitchin writes: > I can see why you would want to see True/False there, but to get the value, > you need to specifically return what you want because AFAIK the body is > wrapped in a function that is evaluated to get the value, it is not simply > the last thing that gets

Re: [PATCH] Fix ob-python.el initiate session error with py-shell

2020-02-19 Thread Jack Kamm
Hi stardiviner, "numbch...@gmail.com" writes: > Yes, Jack, as Bastien said, you can format my commit, because my home > network is broken, I'm using Mobile Phone's 4G network to get online. Can't > get update immediately. OK, I've edited the commit message of your patch, and I also fixed the

Re: Make ob-python.el support ":results pp" pretty print result

2020-02-20 Thread Jack Kamm
Hi stardiviner, stardiviner writes: > I found ob-python does not support ":results pp" pretty print result. And > Python > has a module "pprint". What about add support this? Well, there is code in ob-python.el that uses the pprint module when ":results pp", but I must admit I've never used

Re: [PATCH] Fix ob-python.el initiate session error with py-shell

2020-02-20 Thread Jack Kamm
Hi, Bastien writes: > Also, for included ob-*, the idea would be to use the mode that are > bundled with Emacs core. For Python, it would mean that ob-python.el > should support python.el, not python-mode.el. I agree that ob-python.el should only rely on functionality from python.el, and

Re: org-babel strange html print in R

2020-02-11 Thread Jack Kamm
Hi, stardiviner writes: > You should try ~:results value html~. Here is what I got correctly: Yes, this seems like the best solution for this case. On the other hand, it would be desirable if ":results output" didn't mangle the output, due to trying to clean up prompts. There is probably some

Re: Bug or not a bug? dot expansion in ob-shell

2020-02-21 Thread Jack Kamm
Hi, Nick Dokos writes: >> That said, we have three solutions: >> >> 1. Stick to a strict reading of Org and bash manuals: the absence of a >>:results header means "return the value, i.e. the exit status". >> >> 2. Deviate from this strict reading, introduce an exception for *all* >>

Re: Make ob-python.el support ":results pp" pretty print result

2020-02-22 Thread Jack Kamm
Hi stardiviner, stardiviner writes: > I found ob-python does not support ":results pp" pretty print result. And > Python > has a module "pprint". What about add support this? ":results pp" works for me, here's an example: > #+begin_src python :results pp > return globals() > #+end_src > >

Re: org-babel strange html print in R

2020-02-11 Thread Jack Kamm
Hi, Jeremie Juste writes: > :results value html in the following code generates an error for me. > (Org mode version 9.2.3,R version 3.6.2). > but :results value output the "html" in an org-table format Hmm, I can confirm that ":session :results value html" is working for me, same as for

Re: [PATCH] Fix ob-python.el initiate session error with py-shell

2020-02-18 Thread Jack Kamm
Hi stardiviner, > This minor patch should fixed ~py-shell~ initiate Python session issue. It looks like this patch only affects users of python-mode.el. Since I don't use python-mode.el, I cannot test it. But the patch looks fine. Please add a commit message and changelog entry, and I'll merge

Re: [PATCH] Fix ob-python.el initiate session error with py-shell

2020-02-18 Thread Jack Kamm
Hi stardiviner, Sorry for the noise, I have some additional comments below: When I run "make compile", I get the following message: In org-babel-python-initiate-session-by-key: ob-python.el:211:12:Warning: py-shell called with 9 arguments, but accepts only 0-1 I think this is because the

Re: [PATCH] restore window configuration after org-edit-src-exit

2020-01-09 Thread Jack Kamm
store the window configuration after editing. I'll start a new thread/RFC/patch for this later this month, when I have a bit more time. >From 8d1cf7500d69823bc4869248bbe251758d3dcdda Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 23 Dec 2019 08:55:55 -0800 Subject: [PATCH] org-src: restore win

Re: Keyboard macros and export dispatcher

2020-01-09 Thread Jack Kamm
Hello, John Hendy writes: > I had no problem doing the following: > > - C-x ( > - C-e C-s l p C-n > - C-x ) > - go to first of my results headlines > - C-u 51 C-x e > > It sounds like you already tried this... are you using `C-x (` or are > you defining the macros via elisp? I'm doing the

Keyboard macros and export dispatcher

2020-01-09 Thread Jack Kamm
Hello, I have an org-mode file, and am exporting one of its subtrees to a beamer presentation. I would like to use a keyboard macro for this, because re-exporting the presentation requires a lot of keypresses: - Jump to the appropriate heading - Start the dispatcher - Toggle subtree export (C-s)

Re: Keyboard macros and export dispatcher

2020-01-09 Thread Jack Kamm
Hello, Kyle Meyer writes: > As an alternative, can't you type `C-u C-c C-e` (i.e. call > org-export-dispatch with a prefix argument)? Thank you for the suggestion -- this accomplishes exactly what I want! Next time, I'll remember to RTFM before asking for help :P Cheers, Jack

[RFC PATCH] Changes to pop-up source buffers

2020-01-18 Thread Jack Kamm
17 00:00:00 2001 From: Jack Kamm Date: Sat, 18 Jan 2020 07:55:48 -0800 Subject: [PATCH] org-src: use display-buffer, quit-restore-window for source buffers --- etc/ORG-NEWS| 14 --- lisp/org-src.el | 65 +++-- 2 files changed, 42 inserti

Re: [RFC PATCH] Changes to pop-up source buffers

2020-01-18 Thread Jack Kamm
Hi Sam, > for me, trying to get commands or functions that call pop-to-buffer to > behave as i need them to, which is to say, for them to use the full > (and same) window for accessibility reasons,* has been so unfixable in > the past that i had to give up. Thank you for raising this, I wasn't

Re: Displaying remote images

2020-01-19 Thread Jack Kamm
to cache the remote images by visiting them in Emacs buffers. The default behavior is not to display remote images, but to issue a message that references the option that controls remote image display. Best, Jack >From 88c37616fc7b910deec34f3013af36ceca8cde9b Mon Sep 17 00:00:00 2001 From: J

Re: [RFC PATCH] Changes to pop-up source buffers

2020-01-19 Thread Jack Kamm
I'm not sure why. >From a9cb8889df25697ff73e7c1e72987dac01875c8a Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Sun, 19 Jan 2020 08:28:36 -0800 Subject: [PATCH] org-src: Add option 'plain to org-src-window-setup * lisp/org-src.el (org-src-window-setup): Add option 'plain for org-src-window-setup, that

Re: [PATCH] restore window configuration after org-edit-src-exit

2020-01-14 Thread Jack Kamm
By the way -- I just got my copyright papers officially updated for my current job -- so we don't need to worry about line counts and whatnot anymore :) Best, John "Jack" Kamm

Re: [RFC PATCH] Changes to pop-up source buffers

2020-01-21 Thread Jack Kamm
ported. Oh well. I tested again, with "emacs -q" this time, and got the behavior you reported. So it must be something with my config. >From 0db0adc4f20d8c664976b89cbe033f5579e1fdc5 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Tue, 21 Jan 2020 20:39:14 -0800 Subject: [PATCH]

[PATCH] Fix several issues with python session value blocks

2020-01-20 Thread Jack Kamm
ssion :results value value = "failure" if False: pass else: value = "success" value #+end_src This block should return "success", but previously it returned "failure": #+begin_src python :session :results value _ = "failure" "s

Re: restore window configuration after org-edit-src-exit

2019-12-23 Thread Jack Kamm
> OK. Would you want to implement it? Yes, but I'm still in the process of updating my copyright papers for my current job. My job said they won't be able to sign the copyright disclaimer until the new year, so I expect this to be sorted out later in January some time. However, the change here

[PATCH] restore window configuration after org-edit-src-exit

2019-12-23 Thread Jack Kamm
/archive/html/emacs-orgmode/2018-11/msg00253.html >From 03a2b9433f1ad15ac21a49e7f0c6c5390e9e4375 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 23 Dec 2019 08:55:55 -0800 Subject: [PATCH] org-src: restore windows for some values of org-src-window-setup --- etc/ORG-NEWS| 3 +++ lisp/

Re: Bug: HTML not formatted correctly from R source code block [9.3.6 (9.3.6-23-g01ee25-elpaplus @ /home/opdfa/.emacs.d/elpa/org-plus-contrib-20200309/)]

2020-03-10 Thread Jack Kamm
Hi Steve, Steven Delean writes: > HTML table produced from a source code block (using R code) does not display > because html code is not formatted correctly in the exported html output. I believe this is the same issue as reported here:

Re: Bug: ob-python mangles multiline :var values [9.3.6 (release_9.3.6-397-ga089600)]

2020-05-24 Thread Jack Kamm
Hello, Thanks for reporting. I've just fixed this issue in master (commit 6149b6cb6). The problem was that ob-python adds tab indentation to the code body before putting it inside a main() function, which adds spurious indentation to multiline strings passed through :var. I fixed the issue by

Re: Improving Org Mode for VSCode - Thinking Aloud

2020-05-24 Thread Jack Kamm
It would be very good indeed for org-babel if it could be ported to other editors. One of the biggest drawbacks of org-babel notebooks is that I can't collaborate with my colleagues on them, since I can't expect them to use Emacs. Aside from VSCode, I think RStudio would be an excellent target

Re: [PATCH] ob-python.el: Fix issue with sessions on remote machines

2020-09-05 Thread Jack Kamm
Hi Bastien, > - A local maintainer is expected to reply to requests and bug reports > regarding the local functionalities he oversees. > > - A local maintainer can commit changes directly to the file(s) he > maintains (either submitted changes or his own). > > - Core maintainers have the

Re: [PATCH] ob-python.el: Fix issue with sessions on remote machines

2020-09-04 Thread Jack Kamm
Hi Bastien, > Would you be okay to add yourself as the ob-python.el maintainer? Sure, I've added myself as maintainer to the header of ob-python.el. > I suggest we have a policy that "Org maintainer(s)" have the last > words on everything in Org's core, but that individual maintainers, > when

Re: Help debugging R source code block output problem with :session

2020-09-07 Thread Jack Kamm
Hi Chuck, > I can confirm that this works on my setup in each of the scenarios in which > `default-directory' got set correctly in the session buffer. > > At some point, my default-directory got reset to drop the tramp prefix > "/scp:/user@host:" in one session after faithfully running the src

Re: Help debugging R source code block output problem with :session

2020-09-07 Thread Jack Kamm
; locally and then ssh in, it's still possible to have default-directory set, but it requires some configuration [1]. Or you could use "M-x cd" to set it as well. [1] https://emacs.stackexchange.com/questions/5589/automatically-update-default-directory-when-pwd-changes-in-shell-mode-and-t

Re: [PATCH] org-add-planning-info: respect caller's given time [9.3.7 (release_9.3.7-716-g3d4876 @ /home/n/.emacs.d/straight/build/org/)]

2020-09-09 Thread Jack Kamm
Kyle Meyer writes: > With Org's master (f17d301e1), the second one hangs for me with Emacs > 26.3. Quickly stepping through org-babel-python--send-string, it > appears to get stuck in the accept-process-output call. > > Using an Emacs built from master, there's no hang on my end either. If >

Re: [PATCH] org-add-planning-info: respect caller's given time [9.3.7 (release_9.3.7-716-g3d4876 @ /home/n/.emacs.d/straight/build/org/)]

2020-09-08 Thread Jack Kamm
Kyle Meyer writes: > That's on a Debian system with the python executable pointing to Python > 2.7.16. If I set org-babel-python-command to python3 (3.7.3) at the top > of test-ob-python.el, I see the same thing. I haven't dug any farther > yet. Jack, presumably you don't see the stall on

Re: Help debugging R source code block output problem with :session

2020-09-08 Thread Jack Kamm
"Berry, Charles" writes: > Also, I wonder if the `:results value' case can be handled in a similar > manner, viz. > > - (let ((tmp-file (org-babel-temp-file "R-"))) > + (let ((tmp-file (with-current-buffer session (org-babel-temp-file "R-" Yes, if we did that then tmp-file would have a

Re: Help debugging R source code block output problem with :session

2020-09-08 Thread Jack Kamm
Hi Chuck, > this is already present in `org-babel-R-evaluate-session' in the call to > `org-babel-comint-eval-invisibly-and-wait-for-file'' just a couple of lines > further down in the `(cl-case result-type (value ...))' branch. > > The other use of `tmp-file' in that block is the one that

Re: Help debugging R source code block output problem with :session

2020-09-07 Thread Jack Kamm
mples as unit tests. Cheers, Jack >From 76d0eaa31506ce8a2f81f64eae43161db5721317 Mon Sep 17 00:00:00 2001 From: Jack Kamm Date: Mon, 7 Sep 2020 00:41:52 -0700 Subject: [PATCH] ob-R: Fix session output with substrings matching prompts * lisp/ob-R.el (ess-send-string): Declare external function

Re: Help debugging R source code block output problem with :session

2020-09-07 Thread Jack Kamm
I just realized my patch had an issue where it freezes if there is an error in the source block. I'm attaching a second patch, to be applied on top of the first one, that fixes the issue. diff --git a/lisp/ob-R.el b/lisp/ob-R.el index b37e3965a..5ddf0ebd1 100644 --- a/lisp/ob-R.el +++

Re: [RFC] ob-reticulate: R+Python interface from Babel

2020-10-11 Thread Jack Kamm
Hi all, I've put ob-reticulate.el on github so it can be more easily used: https://github.com/jackkamm/ob-reticulate I plan to submit it to MELPA or GNU ELPA over the coming weeks as well. Cheers, Jack

  1   2   3   >