From: brodiej@SEA-9901331265.i-did-not-set--mail-host-address--so-tickle-me
To: emacs-orgmode@gnu.org
Subject: Bug: Babel :results raw doesn't replace results. [8.3.4 (8.3.4-72-gddd58f-elpa @ c:/Users/brodiej/AppData/Roaming/.emacs.d/elpa/org-20160530/)]
Date: Mon, 19 Sep 2016 09:35:36 -0700
Message-ID: <tcbvsvaxru9t3.fsf@SEA-9901331265.i-did-not-set--mail-host-address--so-tickle-me>
--text follows this line--

I'm creating a literate program using org-babel with python. If I change
the output of a source block to 'raw' the results are not replaced on
each run, they are appended. This is quite annoying, because it means
manual editing everytime I need to re-run my program.  If I try to set
the flags 'replace' 'prepend' etc. they have no effect:

#+name: Example1
#+begin_src python :session :results raw :exports none
  'dogs and cats'
#+end_src

#+RESULTS: Example1
dogs and cats
dogs and cats
dogs and cats
dogs and cats
dogs and cats


Emacs  : GNU Emacs 25.0.92.1 (x86_64-w64-mingw32)
 of 2016-03-03
Package: Org-mode version 8.3.4 (8.3.4-72-gddd58f-elpa @ c:/Users/brodiej/AppData/Roaming/.emacs.d/elpa/org-20160530/)

current state:
==============
(setq
 org-id-locations-file "c:/Users/brodiej/AppData/Roaming/.emacs.d/.cache/.org-id-locations"
 org-export-backends '(ascii html icalendar latex odt confluence)
 org-latex-default-figure-position "H"
 org-export-babel-evaluate nil
 org-tab-first-hook '(org-hide-block-toggle-maybe org-babel-hide-result-toggle-maybe
                      org-babel-header-arg-expand)
 org-latex-default-packages-alist '(("AUTO" "inputenc" t) ("T1" "fontenc" nil)
                                    ("" "fixltx2e" nil) ("" "graphicx" t) ("" "grffile" t)
                                    ("" "longtable" nil) ("" "wrapfig" nil) ("" "rotating" nil)
                                    ("normalem" "ulem" t) ("" "amsmath" t) ("" "textcomp" t)
                                    ("" "amssymb" t) ("" "capt-of" nil) ("" "hyperref" nil))
 org-clock-persist-file "c:/Users/brodiej/AppData/Roaming/.emacs.d/.cache/org-clock-save.el"
 org-speed-command-hook '(org-speed-command-default-hook org-babel-speed-command-hook)
 org-occur-hook '(org-first-headline-recenter)
 org-metaup-hook '(org-babel-load-in-session-maybe)
 org-html-format-drawer-function '(lambda (name contents) contents)
 org-log-done 'time
 org-latex-format-inlinetask-function 'org-latex-format-inlinetask-default-function
 org-confirm-shell-link-function 'yes-or-no-p
 org-ascii-format-inlinetask-function 'org-ascii-format-inlinetask-default
 org-link-translation-function 'toc-org-unhrefify
 org-present-mode-hook '(spacemacs//org-present-start)
 org-agenda-restore-windows-after-quit t
 org-agenda-custom-commands '(("n" "Agenda and all TODOs"
                               ((agenda "" nil) (todo "NEXT" nil) (alltodo "" nil)) nil)
                              )
 org-latex-format-headline-function 'org-latex-format-headline-default-function
 org-default-notes-file "notes.org"
 org-latex-image-default-width ".6\\linewidth"
 org-startup-indented t
 org-after-todo-state-change-hook '(org-clock-out-if-current)
 org-latex-format-drawer-function '(lambda (name contents) contents)
 org-odt-format-headline-function 'org-odt-format-headline-default-function
 org-src-mode-hook '(org-src-babel-configure-edit-buffer org-src-mode-configure-edit-buffer)
 org-agenda-before-write-hook '(org-agenda-add-entry-text)
 org-babel-pre-tangle-hook '(save-buffer)
 org-mode-hook '(#[nil "\300\301\302\303\304$\207"
                   [org-add-hook change-major-mode-hook org-show-block-all append local] 5]
                 #[nil "\300\301\302\303\304$\207"
                   [org-add-hook change-major-mode-hook org-babel-show-result-all append local] 5]
                 org-babel-result-hide-spec org-babel-hide-all-hashes toc-org-enable
                 org-bullets-mode flyspell-mode spacemacs/add-org-surrounds evil-org-mode
                 org-eldoc-load)
 org-latex-prefer-user-labels t
 org-archive-hook '(org-attach-archive-delete-maybe)
 org-level-color-stars-only t
 org-ascii-format-drawer-function '(lambda (name contents width) contents)
 org-odt-format-inlinetask-function 'org-odt-format-inlinetask-default-function
 org-ctrl-c-ctrl-c-hook '(org-babel-hash-at-point org-babel-execute-safely-maybe)
 org-cycle-hook '(org-cycle-hide-archived-subtrees org-cycle-hide-drawers
                  org-cycle-show-empty-lines org-optimize-window-after-visibility-change)
 org-present-mode-quit-hook '(spacemacs//org-present-end)
 org-export-async-init-file "c:/Users/brodiej/AppData/Roaming/.emacs.d/layers/org/org-async-init.el"
 org-todo-keywords '((sequence "TODO(t)" "NEXT(n)" "STARTED" "WAITING(w)" "|" "DONE(d)"
                      "CANCELED(c)")
                     )
 org-babel-tangle-lang-exts '(("python" . "py") ("emacs-lisp" . "el") ("elisp" . "el"))
 org-confirm-elisp-link-function 'yes-or-no-p
 org-startup-with-inline-images t
 org-metadown-hook '(org-babel-pop-to-session-maybe)
 org-odt-format-drawer-function '(lambda (name contents) contents)
 org-ditaa-jar-path "C:\\Users\\brodiej\\AppData\\Roaming\\.emacs.d\\ditaa\\ditaa.jar"
 org-html-format-headline-function 'org-html-format-headline-default-function
 org-babel-load-languages '((python . t) (ditaa . t))
 org-html-format-inlinetask-function 'org-html-format-inlinetask-default-function
 org-fontify-whole-heading-line t
 org-agenda-files '("c:/docs/planner/brodie_planning.org")
 org-clock-out-hook '(org-clock-remove-empty-clock-drawer)
 org-confirm-babel-evaluate nil
 org-src-fontify-natively t
 )