emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* BUG: Capture task clocking doesn't stop due to narrowing
@ 2019-03-16 20:42 Bernt Hansen
  2021-10-03  8:22 ` [O] " Ihor Radchenko
  0 siblings, 1 reply; 3+ messages in thread
From: Bernt Hansen @ 2019-03-16 20:42 UTC (permalink / raw)
  To: emacs-orgmode

Hi,

I ran into an issue this morning where my capture task continues
clocking on save.  This occurs in both master and maint when not
clocking into a drawer.

ECM follows.


--- test.org -------------------------------------------------------------------
#+TITLE: BUG: Capture with clocking does not stop the clock due to narrowing

*Keys To Reproduce*

1) Capture a new entry
   C-c c w

2) Save entry - clock should stop but doesn't
   C-c C-c

The clock is still running after save but should have been
stopped. The clock was not included in the narrowed buffer in the
capture window.  If we widen the buffer before saving the clock is
stopped normally.

Same results in both maint and master branch.

CLOCK changed to KLOCK in example below to avoid before first headline
error.  The clock line is being picked up even though it is inside an
example block and the clock resolution code is trying to deal with it.

#+begin_example
  ,* Tasks
  ,* Work Log
  ,** DONE Capture bug details
  KLOCK: [2019-03-16 Sat 16:09]
  ,* Personal Log
#+end_example

GNU Emacs 25.1.1 (x86_64-w64-mingw32) of 2016-09-17
Org mode version 9.2.2 (release_9.2.2-312-gce1681 @ c:/D-Drive/bin/org-mode/lisp/)

* Tasks
* Work Log
* Personal Log
--- minimal.emacs --------------------------------------------------------------
(add-to-list 'load-path "C:/D-Drive/bin/org-mode/lisp/")
(add-to-list 'auto-mode-alist '("\\.\\(org\\|org_archive\\)$" . org-mode))
(require 'org)

(global-set-key "\C-cl" 'org-store-link)
(global-set-key "\C-ca" 'org-agenda)
(global-set-key "\C-cb" 'org-iswitchb)
--- test.el --------------------------------------------------------------------
(global-set-key (kbd "C-c c") 'org-capture)

;; Save clock data and state changes and notes in the LOGBOOK drawer
(setq org-clock-into-drawer 4)

(setq org-adapt-indentation nil)

(setq org-capture-templates
      (quote (("t" "Todo" entry (file "~/test.org")
	       "* TODO %?\n\n%x\n" :clock-in t :clock-resume t)
	      ("p" "Personal Log" entry (file+olp "~/test.org" "Personal Log")
	       "* DONE %?\n" :clock-in t :clock-resume t)
	      ("w" "Work Log" entry (file+olp "~/test.org" "Work Log")
	       "* DONE %?\n" :clock-in t :clock-resume t))))
--- windows icon properties to start minimal emacs -----------------------------
C:\D-Drive\bin\emacs-25.1\bin\runemacs.exe -q -l ~/minimal.emacs -l ~/test.el ~/test.org

Regards,
Bernt

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [O] BUG: Capture task clocking doesn't stop due to narrowing
  2019-03-16 20:42 BUG: Capture task clocking doesn't stop due to narrowing Bernt Hansen
@ 2021-10-03  8:22 ` Ihor Radchenko
  2022-10-06  8:04   ` Ihor Radchenko
  0 siblings, 1 reply; 3+ messages in thread
From: Ihor Radchenko @ 2021-10-03  8:22 UTC (permalink / raw)
  To: Bernt Hansen; +Cc: emacs-orgmode

Bernt Hansen <bernt@norang.ca> writes:

> Hi,
>
> I ran into an issue this morning where my capture task continues
> clocking on save.  This occurs in both master and maint when not
> clocking into a drawer.
>
> ECM follows.

Confirmed


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [O] BUG: Capture task clocking doesn't stop due to narrowing
  2021-10-03  8:22 ` [O] " Ihor Radchenko
@ 2022-10-06  8:04   ` Ihor Radchenko
  0 siblings, 0 replies; 3+ messages in thread
From: Ihor Radchenko @ 2022-10-06  8:04 UTC (permalink / raw)
  To: Bernt Hansen; +Cc: emacs-orgmode

Ihor Radchenko <yantar92@gmail.com> writes:

> Bernt Hansen <bernt@norang.ca> writes:
>
>> Hi,
>>
>> I ran into an issue this morning where my capture task continues
>> clocking on save.  This occurs in both master and maint when not
>> clocking into a drawer.
>>
>> ECM follows.
>
> Confirmed

Fixed on main.
https://git.savannah.gnu.org/cgit/emacs/org-mode.git/commit/?id=224708323e0f5682eb3894d58032a593a1a05214

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2022-10-06  8:10 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-16 20:42 BUG: Capture task clocking doesn't stop due to narrowing Bernt Hansen
2021-10-03  8:22 ` [O] " Ihor Radchenko
2022-10-06  8:04   ` Ihor Radchenko

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).