From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Rares Vernica Newsgroups: gmane.emacs.bugs Subject: bug#23890: 25.0.94; Org-mode Table does not copy time interval correctly Date: Sun, 3 Jul 2016 22:30:08 -0700 Message-ID: NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=001a11415f502ff3a40536c8a1a5 X-Trace: ger.gmane.org 1467610300 8000 80.91.229.3 (4 Jul 2016 05:31:40 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Mon, 4 Jul 2016 05:31:40 +0000 (UTC) To: 23890@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Mon Jul 04 07:31:30 2016 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1bJwTT-0007he-Ct for geb-bug-gnu-emacs@m.gmane.org; Mon, 04 Jul 2016 07:31:15 +0200 Original-Received: from localhost ([::1]:45283 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwTS-00035E-6Z for geb-bug-gnu-emacs@m.gmane.org; Mon, 04 Jul 2016 01:31:14 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43112) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwTJ-00034r-EI for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:31:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bJwTG-0007jo-Fr for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:31:04 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:52385) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwTG-0007jk-Ck for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:31:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1bJwTG-0002CD-40 for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:31:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Rares Vernica Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Mon, 04 Jul 2016 05:31:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 23890 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.14676102288400 (code B ref -1); Mon, 04 Jul 2016 05:31:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 4 Jul 2016 05:30:28 +0000 Original-Received: from localhost ([127.0.0.1]:36489 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJwSh-0002BQ-EB for submit@debbugs.gnu.org; Mon, 04 Jul 2016 01:30:27 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:52040) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1bJwSf-0002BC-ET for submit@debbugs.gnu.org; Mon, 04 Jul 2016 01:30:26 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bJwSY-0007a0-3L for submit@debbugs.gnu.org; Mon, 04 Jul 2016 01:30:20 -0400 Original-Received: from lists.gnu.org ([2001:4830:134:3::11]:39155) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwSX-0007Zu-W0 for submit@debbugs.gnu.org; Mon, 04 Jul 2016 01:30:18 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43010) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwSU-00034D-Sh for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:30:16 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1bJwSR-0007Zg-II for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:30:13 -0400 Original-Received: from mail-qt0-x229.google.com ([2607:f8b0:400d:c0d::229]:34958) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1bJwSR-0007ZH-Bq for bug-gnu-emacs@gnu.org; Mon, 04 Jul 2016 01:30:11 -0400 Original-Received: by mail-qt0-x229.google.com with SMTP id f89so83143925qtd.2 for ; Sun, 03 Jul 2016 22:30:09 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:from:date:message-id:subject:to; bh=BTXEEL9pb1el9TRC1+0DzwmpPxWXGwhzY1NxapvkqIU=; b=VdITSXNqoeShaNRqtEZVAUMQfKotcz2v86H4ZCLXlN03hj//1eh5JgZ1tTHs1vBKWQ kqZmCi/v9PXrk+NTG/dbY8WX2Bs3TaOYbB2lYE2eXv5/vZUtOBGHJJpfC9n9PhHMILq2 yLtzHhR6dOq7MXxqdXGfXwTQ6K/x7rVoceA/183sZ8H9IYHFTL4NYtkPDksGRkLkMf8M IGr56eJRCflVoLf+1rDa2xSf3Hbikdu/en0k76OE0S25+VQEoRyloqKn+mzXEXeeiLqS i9Kopi8Exvra1uF5ZGE6ttqlXX2mc1+7SrYNJjPINGeGrq8nbPFtOPhXZwLblYgqOx0G z/yQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=BTXEEL9pb1el9TRC1+0DzwmpPxWXGwhzY1NxapvkqIU=; b=Jmg/0tdA4Ihmk4EDBSBWFjw0nkJy7iPeLp8xHvA6loTazqjWiMQMsgJ7KfrR8AZNHL JDJu9QR0DiBXW98tYaGIMkYAkZSELrGDMIbrVYx7RM88/99PvYTgE3W8wyLGqQXq5yCX AdRJvZ78gahejXeA82Z32bDRJHAsSqsVsjgf8WtSxzTvew11U0nsNRbOycog+Bg7vW1a MbiK9ywICynBA4tTDoQQgTvpAY7CuRJU79ioclownDGDNXByp8aas2h7nRymEk0ZL1nf 6XJ4MZThAvM8dc9/yx8RiePu0TZ3wS04cnX8Nv4g+43eQmZ/6TjYBkj+2XIzzpLmutVi BsZQ== X-Gm-Message-State: ALyK8tJH0RiRJlca3NMCTxC/Z204AwiZp0GaaCgiBhyIDpw1HwHhJeabjN9GbXiAwzmwtTjcT7f7vGySg+nOPg== X-Received: by 10.200.44.78 with SMTP id e14mr15671690qta.77.1467610209174; Sun, 03 Jul 2016 22:30:09 -0700 (PDT) Original-Received: by 10.200.44.54 with HTTP; Sun, 3 Jul 2016 22:30:08 -0700 (PDT) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:120384 Archived-At: --001a11415f502ff3a40536c8a1a5 Content-Type: multipart/alternative; boundary=001a11415f502ff39f0536c8a1a3 --001a11415f502ff39f0536c8a1a3 Content-Type: text/plain; charset=UTF-8 In the following table: | [2016-07-03 Sun]--[2016-07-04 Mon] | 1d | d | | [2016-07-03 Sun]--[2016-07-05 Tue] | 2d | 2 d | #+TBLFM: $3=$2 The second column is computed by pressing C-u C-c C-y. This sequence calculates the time difference between the time-stamps in the previous column and inserts the difference in the current column. This is fine. Now, for the third column, I insert the formula listed at the bottom of the table. Once applied, the result of the formula for the fist row is just "d" instead of "1d". So, it seems that the value is not copied correctly. This seems to work fine if the time-stamp range is greater than one day. Also, for the second row, the value is copied correctly but there is an extra " " inserted between the number and the "d" letter. This might not be desirable. Appending "D" at the end of the formula, yields the same result: | [2016-07-03 Sun]--[2016-07-04 Mon] | 1d | d | | [2016-07-03 Sun]--[2016-07-05 Tue] | 2d | 2 d | #+TBLFM: $3=$2;D I also tried appending "T" at the end of the formula: | [2016-07-03 Sun]--[2016-07-04 Mon] | 1d | 00:00:01 | | [2016-07-03 Sun]--[2016-07-05 Tue] | 2d | 00:00:02 | #+TBLFM: $3=$2;T The numeric value is copied correctly but the days are now changed to seconds. I attached a dribble file which allows you to reproduce the first row in the first table. <#part type="application/octet-stream" filename="~/org-copy-bug.dribble" disposition=attachment> <#/part> In GNU Emacs 25.0.94.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.20.4) of 2016-05-18 built on buildhw-10.phx2.fedoraproject.org Windowing system distributor 'Fedora Project', version 11.0.11803000 System Description: Fedora release 24 (Twenty Four) Configured using: 'configure --build=x86_64-redhat-linux-gnu --host=x86_64-redhat-linux-gnu --program-prefix= --disable-dependency-tracking --prefix=/usr --exec-prefix=/usr --bindir=/usr/bin --sbindir=/usr/sbin --sysconfdir=/etc --datadir=/usr/share --includedir=/usr/include --libdir=/usr/lib64 --libexecdir=/usr/libexec --localstatedir=/var --sharedstatedir=/var/lib --mandir=/usr/share/man --infodir=/usr/share/info --with-dbus --with-gif --with-jpeg --with-png --with-rsvg --with-tiff --with-xft --with-xpm --with-x-toolkit=gtk3 --with-gpm=no --with-xwidgets build_alias=x86_64-redhat-linux-gnu host_alias=x86_64-redhat-linux-gnu 'CFLAGS=-DMAIL_USE_LOCKF -O2 -g -pipe -Wall -Werror=format-security -Wp,-D_FORTIFY_SOURCE=2 -fexceptions -fstack-protector-strong --param=ssp-buffer-size=4 -grecord-gcc-switches -specs=/usr/lib/rpm/redhat/redhat-hardened-cc1 -m64 -mtune=generic' LDFLAGS=-Wl,-z,relro PKG_CONFIG_PATH=:/usr/lib64/pkgconfig:/usr/share/pkgconfig' Configured features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GCONF GSETTINGS NOTIFY ACL LIBSELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 XWIDGETS Important settings: value of $LANG: en_US.utf8 value of $XMODIFIERS: @im=ibus locale-coding-system: utf-8-unix Major mode: Lisp Interaction Minor modes in effect: tooltip-mode: t global-eldoc-mode: t electric-indent-mode: t mouse-wheel-mode: t tool-bar-mode: t menu-bar-mode: t file-name-shadow-mode: t global-font-lock-mode: t font-lock-mode: t blink-cursor-mode: t auto-composition-mode: t auto-encryption-mode: t auto-compression-mode: t line-number-mode: t transient-mark-mode: t Recent messages: For information about GNU Emacs and the GNU system, type C-h C-a. Making completion list... Load-path shadows: None found. Features: (shadow sort mail-extr emacsbug message dired format-spec rfc822 mml mml-sec password-cache epg epg-config gnus-util mm-decode mm-bodies mm-encode mail-parse rfc2231 mailabbrev gmm-utils mailheader sendmail rfc2047 rfc2045 ietf-drums mm-util help-fns help-mode easymenu cl-loaddefs pcase cl-lib mail-prsvr mail-utils time-date mule-util tooltip eldoc electric uniquify ediff-hook vc-hooks lisp-float-type mwheel x-win term/common-win x-dnd tool-bar dnd fontset image regexp-opt fringe tabulated-list newcomment elisp-mode lisp-mode prog-mode register page menu-bar rfn-eshadow timer select scroll-bar mouse jit-lock font-lock syntax facemenu font-core frame cl-generic cham georgian utf-8-lang misc-lang vietnamese tibetan thai tai-viet lao korean japanese eucjp-ms cp51932 hebrew greek romanian slovak czech european ethiopic indian cyrillic chinese charscript case-table epa-hook jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nadvice loaddefs button faces cus-face macroexp files text-properties overlay sha1 md5 base64 format env code-pages mule custom widget hashtable-print-readable backquote dbusbind inotify dynamic-setting system-font-setting font-render-setting xwidget-internal move-toolbar gtk x-toolkit x multi-tty make-network-process emacs) Memory information: ((conses 16 86524 7003) (symbols 48 19784 0) (miscs 40 39 146) (strings 32 14348 4717) (string-bytes 1 410110) (vectors 16 11716) (vector-slots 8 428442 4776) (floats 8 165 61) (intervals 56 264 0) (buffers 976 12) (heap 1024 26216 1084)) --001a11415f502ff39f0536c8a1a3 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

In the following table:

| [2016-07-03 Sun]--[20= 16-07-04 Mon] | 1d | d=C2=A0=C2=A0 |
| [2016-07-03 Sun]--[2016-07-05 Tue= ] | 2d | 2 d |
#+TBLFM: $3=3D$2

The second column is computed by = pressing C-u C-c C-y. This sequence
calculates the time difference betwe= en the time-stamps in the previous
column and inserts the difference in = the current column. This is fine.

Now, for the third column, I inser= t the formula listed at the bottom of
the table. Once applied, the resul= t of the formula for the fist row is
just "d" instead of "= ;1d". So, it seems that the value is not copied
correctly.

T= his seems to work fine if the time-stamp range is greater than one
day. = Also, for the second row, the value is copied correctly but there
is an = extra " " inserted between the number and the "d" lette= r. This
might not be desirable.

Appending "D" at the en= d of the formula, yields the same result:

| [2016-07-03 Sun]--[2016-= 07-04 Mon] | 1d | d=C2=A0=C2=A0 |
| [2016-07-03 Sun]--[2016-07-05 Tue] |= 2d | 2 d |
#+TBLFM: $3=3D$2;D

I also tried appending "T&quo= t; at the end of the formula:

| [2016-07-03 Sun]--[2016-07-04 Mon] |= 1d | 00:00:01 |
| [2016-07-03 Sun]--[2016-07-05 Tue] | 2d | 00:00:02 |<= br>#+TBLFM: $3=3D$2;T

The numeric value is copied correctly but the = days are now changed to seconds.

I attached a dribble file which all= ows you to reproduce the first row in
the first table.

<#part = type=3D"application/octet-stream" filename=3D"~/org-copy-bug= .dribble" disposition=3Dattachment>
<#/part>


In GNU Emacs 25.0.94.1 (x86_64-redhat-linux-gnu, GTK+ Version 3.20.4)
= =C2=A0of 2016-05-18 built on buildhw-10.phx2.fedoraproject.org
Windowing system distributo= r 'Fedora Project', version 11.0.11803000
System Description:=C2= =A0=C2=A0=C2=A0 Fedora release 24 (Twenty Four)

Configured using:=C2=A0'configure --build=3Dx86_64-redhat-linux-gnu
=C2=A0--host=3Dx= 86_64-redhat-linux-gnu --program-prefix=3D
=C2=A0--disable-dependency-tr= acking --prefix=3D/usr --exec-prefix=3D/usr
=C2=A0--bindir=3D/usr/bin --= sbindir=3D/usr/sbin --sysconfdir=3D/etc
=C2=A0--datadir=3D/usr/share --i= ncludedir=3D/usr/include --libdir=3D/usr/lib64
=C2=A0--libexecdir=3D/usr= /libexec --localstatedir=3D/var
=C2=A0--sharedstatedir=3D/var/lib --mand= ir=3D/usr/share/man
=C2=A0--infodir=3D/usr/share/info --with-dbus --with= -gif --with-jpeg --with-png
=C2=A0--with-rsvg --with-tiff --with-xft --w= ith-xpm --with-x-toolkit=3Dgtk3
=C2=A0--with-gpm=3Dno --with-xwidgets bu= ild_alias=3Dx86_64-redhat-linux-gnu
=C2=A0host_alias=3Dx86_64-redhat-lin= ux-gnu 'CFLAGS=3D-DMAIL_USE_LOCKF -O2 -g
=C2=A0-pipe -Wall -Werror= =3Dformat-security -Wp,-D_FORTIFY_SOURCE=3D2
=C2=A0-fexceptions -fstack-= protector-strong --param=3Dssp-buffer-size=3D4
=C2=A0-grecord-gcc-switch= es -specs=3D/usr/lib/rpm/redhat/redhat-hardened-cc1
=C2=A0-m64 -mtune=3D= generic' LDFLAGS=3D-Wl,-z,relro
=C2=A0PKG_CONFIG_PATH=3D:/usr/lib64/= pkgconfig:/usr/share/pkgconfig'

Configured features:
XPM JPEG= TIFF GIF PNG RSVG IMAGEMAGICK SOUND DBUS GCONF GSETTINGS NOTIFY
ACL LIB= SELINUX GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB
TOOLKIT_SCROLL_= BARS GTK3 X11 XWIDGETS

Important settings:
=C2=A0 value of $LANG:= en_US.utf8
=C2=A0 value of $XMODIFIERS: @im=3Dibus
=C2=A0 locale-cod= ing-system: utf-8-unix

Major mode: Lisp Interaction

Minor mod= es in effect:
=C2=A0 tooltip-mode: t
=C2=A0 global-eldoc-mode: t
= =C2=A0 electric-indent-mode: t
=C2=A0 mouse-wheel-mode: t
=C2=A0 tool= -bar-mode: t
=C2=A0 menu-bar-mode: t
=C2=A0 file-name-shadow-mode: t<= br>=C2=A0 global-font-lock-mode: t
=C2=A0 font-lock-mode: t
=C2=A0 bl= ink-cursor-mode: t
=C2=A0 auto-composition-mode: t
=C2=A0 auto-encryp= tion-mode: t
=C2=A0 auto-compression-mode: t
=C2=A0 line-number-mode:= t
=C2=A0 transient-mark-mode: t

Recent messages:
For informat= ion about GNU Emacs and the GNU system, type C-h C-a.
Making completion = list...

Load-path shadows:
None found.

Features:
(shado= w sort mail-extr emacsbug message dired format-spec rfc822 mml
mml-sec p= assword-cache epg epg-config gnus-util mm-decode mm-bodies
mm-encode mai= l-parse rfc2231 mailabbrev gmm-utils mailheader sendmail
rfc2047 rfc2045= ietf-drums mm-util help-fns help-mode easymenu
cl-loaddefs pcase cl-lib= mail-prsvr mail-utils time-date mule-util
tooltip eldoc electric uniqui= fy ediff-hook vc-hooks lisp-float-type
mwheel x-win term/common-win x-dn= d tool-bar dnd fontset image regexp-opt
fringe tabulated-list newcomment= elisp-mode lisp-mode prog-mode register
page menu-bar rfn-eshadow timer= select scroll-bar mouse jit-lock
font-lock syntax facemenu font-core fr= ame cl-generic cham georgian
utf-8-lang misc-lang vietnamese tibetan tha= i tai-viet lao korean
japanese eucjp-ms cp51932 hebrew greek romanian sl= ovak czech european
ethiopic indian cyrillic chinese charscript case-tab= le epa-hook
jka-cmpr-hook help simple abbrev minibuffer cl-preloaded nad= vice
loaddefs button faces cus-face macroexp files text-properties overl= ay
sha1 md5 base64 format env code-pages mule custom widget
hashtable= -print-readable backquote dbusbind inotify dynamic-setting
system-font-s= etting font-render-setting xwidget-internal move-toolbar
gtk x-toolkit x= multi-tty make-network-process emacs)

Memory information:
((cons= es 16 86524 7003)
=C2=A0(symbols 48 19784 0)
=C2=A0(miscs 40 39 146)<= br>=C2=A0(strings 32 14348 4717)
=C2=A0(string-bytes 1 410110)
=C2=A0= (vectors 16 11716)
=C2=A0(vector-slots 8 428442 4776)
=C2=A0(floats 8= 165 61)
=C2=A0(intervals 56 264 0)
=C2=A0(buffers 976 12)
=C2=A0(= heap 1024 26216 1084))

--001a11415f502ff39f0536c8a1a3-- --001a11415f502ff3a40536c8a1a5 Content-Type: application/octet-stream; name="org-copy-bug.dribble" Content-Disposition: attachment; filename="org-copy-bug.dribble" Content-Transfer-Encoding: base64 X-Attachment-Id: f_iq7l80v30 IDB4ODAwMDA3OG9yZy1tb2RlPHJldHVybj58IAMhPHJldHVybj4tLQMhWzIwMTYtMDctMDRdPHJl dHVybj4gfCAVAxk8cmlnaHQ+PHJpZ2h0PjxyaWdodD48cmlnaHQ+ID0kMjx0YWI+GAM= --001a11415f502ff3a40536c8a1a5--