Re: [O] 6 failing tests on master branch

2017-06-09 Thread Kaushal Modi
On Fri, Jun 9, 2017 at 4:05 PM Nicolas Goaziou 
wrote:

> Hello,
>
> Kaushal Modi  writes:
>
> > Here's a patch rebased off maint (as it's just test and manual change
> with
> > edits to a backward compatible Tramp syntax).
>
> LGTM.
>
> Thank you.
>

Thanks, pushed to maint, merged to master.
-- 

Kaushal Modi


Re: [O] 6 failing tests on master branch

2017-06-09 Thread Nicolas Goaziou
Hello,

Kaushal Modi  writes:

> Here's a patch rebased off maint (as it's just test and manual change with
> edits to a backward compatible Tramp syntax).

LGTM.

Thank you.

Regards,

-- 
Nicolas Goaziou0x80A93738



Re: [O] 6 failing tests on master branch

2017-06-09 Thread Kaushal Modi
On Fri, Jun 9, 2017 at 12:27 PM Nicolas Goaziou 
wrote:

> AFAIU, the function doesn't need to change, but the manual needs to be
> updated since, in (info "(org) External links") there is:
>
>  /myself@some.where:papers/last.pdfsame as above
>
> which is no longer a valid syntax.
>

Here's a patch rebased off maint (as it's just test and manual change with
edits to a backward compatible Tramp syntax).

There were some alignment issues in that External links section. So I have
fixed that too.
-- 

Kaushal Modi


0001-Update-remote-file-syntax-for-Tramp.patch
Description: Binary data


Re: [O] 6 failing tests on master branch

2017-06-09 Thread Nicolas Goaziou
Hello,

Kaushal Modi  writes:

> Does org-export-file-uri need to change? Because now
>
> (org-export-file-uri "/ssh:myself@some.where:papers/last.pdf")
>
> returns
>
> "file://ssh:myself@some.where:papers/last.pdf"

AFAIU, the function doesn't need to change, but the manual needs to be
updated since, in (info "(org) External links") there is:

 /myself@some.where:papers/last.pdfsame as above

which is no longer a valid syntax.

Regards,

-- 
Nicolas Goaziou0x80A93738



Re: [O] 6 failing tests on master branch

2017-06-09 Thread Kaushal Modi
On Fri, Jun 9, 2017 at 12:02 PM Michael Albinus 
wrote:

> Kaushal Modi  writes:
>
> The stronger Tramp file name syntax requires now a method. Something
> like "/ssh:myself@some.where:papers/last.pdf". This is backward
> compatible with Emacs 25, 24, etc pp.
>

Thanks for the quick reply!

@Nicholas

Does org-export-file-uri need to change? Because now

(org-export-file-uri "/ssh:myself@some.where:papers/last.pdf")

returns

"file://ssh:myself@some.where:papers/last.pdf"
-- 

Kaushal Modi


Re: [O] 6 failing tests on master branch

2017-06-09 Thread Michael Albinus
Kaushal Modi  writes:

> This seems to be related to a tramp file notation change on emacs
> master. I don't use tramp, but I heard about it on emacs-devel.

Indeed.

> Here is a test expression:
>
> (find-file-name-handler "/myself@some.where:papers/last.pdf"
> 'file-remote-p)
>
> On emacs 25.2, that returns tramp-file-name-handler.
> On emacs master, that returns nil.
>
> @Michael How should the above find-file-name-handler arg change to
> support that test file path?

The stronger Tramp file name syntax requires now a method. Something
like "/ssh:myself@some.where:papers/last.pdf". This is backward
compatible with Emacs 25, 24, etc pp.

> Thanks.

Best regards, Michael.



Re: [O] 6 failing tests on master branch

2017-06-09 Thread Kaushal Modi
On Fri, Jun 9, 2017 at 10:26 AM Kaushal Modi  wrote:

> This one should be easy to debug since
>>
>>   (org-export-file-uri "/myself@some.where:papers/last.pdf")
>>
>> is easy to reproduce. Could you investigate where the spurious "/" comes
>> from?
>>
>
> Will do.
>

This seems to be related to a tramp file notation change on emacs master. I
don't use tramp, but I heard about it on emacs-devel.

Here is a test expression:

(find-file-name-handler "/myself@some.where:papers/last.pdf"
'file-remote-p)

On emacs 25.2, that returns tramp-file-name-handler.
On emacs master, that returns nil.

So, on emacs 25.2, in org-export-file-uri, the (org-file-remote-p filename)
case evaluates to true. Whereas, on emacs master, the execution falls into
the default (t ..) case.

.. and thus the spurious "/".

Copying the tramp dev Michael Albinus on this for help.
@Michael How should the above find-file-name-handler arg change to support
that test file path?

Thanks.
-- 

Kaushal Modi


Re: [O] 6 failing tests on master branch

2017-06-09 Thread Kaushal Modi
On Thu, Jun 8, 2017 at 5:10 PM Nicolas Goaziou 
wrote:

> > I remember reading that someone else too saw the fortran errors.. Is it
> > because I don't have fortran on my system?
>
> No, I don't think so. OTOH, I have no idea about where this comes from.
>

Did little digging, TIL that the gfortran binary is part of GCC.. as
gfortran binary. So I do have fortran, but I never use it.

Also found out why fortran tests were failing for me.. by default the gcc
version on my system (RHEL 6.6) is 4.4.7. Using GCC 6.1.0 passes the full
"make test" on emacs 25.2.

For example, this is one of the ob-fortran examples that was failing:

* matrix
  :PROPERTIES:
  :ID:   3f73ab19-d25a-428d-8c26-e8c6aa933976
  :END:
Real matrix as input
#+name: fortran-input-matrix1
| 0.0 | 42.0 |
| 0.0 |  0.0 |
| 0.0 |  0.0 |

#+name: fortran-input-matrix2
| 0.0 | 0.0 | 0.0 |
| 0.0 | 0.0 | 42.0 |

#+begin_src fortran :var s=fortran-input-matrix1 :results silent
write (*, '(i2)'), nint(s(1,2))
#+end_src

#+begin_src fortran :var s=fortran-input-matrix2 :results silent
write (*, '(i2)'), nint(s(2,3))
#+end_src

Doing C-c C-c on the first source block gives this error with gcc 4.4.7:

/tmp/babel-6872M6V/fortran-src-6872rcR.F90:4.27:

real, parameter :: s(3,2) = transpose( reshape( (/(/0.0, 42.0/), (/0.0,
0.0/),
   1
Error: transformational intrinsic 'transpose' at (1) is not permitted in an
initialization expression
/bin/sh: /tmp/babel-6872M6V/fortran-bin-68724mX: Permission denied

That expression is apparently legal in newer fortran, is my guess.


> > About the other 3 errors:
>
> Since our buildbot doesn't report any problem, this seems specific to
> Emacs master.
>

Thanks. I confirm that make test on org master passes with emacs 25.2.

> Test test-org-export/file-uri condition:
> > (ert-test-failed
> >  ((should
> >(equal "file://myself@some.where:papers/last.pdf"
> >   (org-export-file-uri "/myself@some.where
> :papers/last.pdf")))
> >   :form
> >   (equal "file://myself@some.where:papers/last.pdf"
> > "file:///myself@some.where:papers/last.pdf")
> >   :value nil :explanation
> >   (arrays-of-different-length 40 41
> > "file://myself@some.where:papers/last.pdf"
> > "file:///myself@some.where:papers/last.pdf" first-mismatch-at 7)))
>
> This one should be easy to debug since
>
>   (org-export-file-uri "/myself@some.where:papers/last.pdf")
>
> is easy to reproduce. Could you investigate where the spurious "/" comes
> from?
>

Will do.


> >FAILED  646/734  test-org/custom-properties
> >FAILED  668/734  test-org/forward-paragraph
>
> These one are related to invisible text. I don't what is going to change
> in this area in next Emacs release.
>

I'll have to leave this for a future debug.. Someone else wants to help out
with this?


> You can run, e.g.,
>
>   BTEST_RE="foo" make test
>

Thanks!
-- 

Kaushal Modi


Re: [O] 6 failing tests on master branch

2017-06-08 Thread Nicolas Goaziou
Hello,

Kaushal Modi  writes:

> 6 unexpected results:
>FAILED  ob-fortran/list-matrix-from-table1
>FAILED  ob-fortran/list-matrix-from-table2
>FAILED  ob-fortran/list-var-from-table
>FAILED  test-org-export/file-uri
>FAILED  test-org/custom-properties
>FAILED  test-org/forward-paragraph
>
> I remember reading that someone else too saw the fortran errors.. Is it
> because I don't have fortran on my system?

No, I don't think so. OTOH, I have no idea about where this comes from.

> About the other 3 errors:

Since our buildbot doesn't report any problem, this seems specific to
Emacs master.

> Test test-org-export/file-uri condition:
> (ert-test-failed
>  ((should
>(equal "file://myself@some.where:papers/last.pdf"
>   (org-export-file-uri "/myself@some.where:papers/last.pdf")))
>   :form
>   (equal "file://myself@some.where:papers/last.pdf"
> "file:///myself@some.where:papers/last.pdf")
>   :value nil :explanation
>   (arrays-of-different-length 40 41
> "file://myself@some.where:papers/last.pdf"
> "file:///myself@some.where:papers/last.pdf" first-mismatch-at 7)))

This one should be easy to debug since 

  (org-export-file-uri "/myself@some.where:papers/last.pdf")

is easy to reproduce. Could you investigate where the spurious "/" comes
from?

> Test test-org/custom-properties condition:
> (ert-test-failed
>  ((should
>(let
>(...)
>  (org-test-with-temp-text "* H
> :PROPERTIES:
> :FOO: val
> :END:
> " ... ...)))
>   :form
>   (let
>   ((org-custom-properties ...))
> (org-test-with-temp-text "* H
> :PROPERTIES:
> :FOO: val
> :END:
> "
>  (org-toggle-custom-properties-visibility)
>  (org-invisible-p2)))
>   :value nil))
>FAILED  646/734  test-org/custom-properties
>
> (ert-test-failed
>  ((should
>(org-test-with-temp-text "#+BEGIN_CENTER
> P1
>
> P2
> #+END_CENTER
> P3"
> (org-hide-block-toggle)
> (org-forward-paragraph)
> (looking-at "P3")))
>   :form
>   (let
>   ((inside-text ...)
>(org-mode-hook nil))
> (with-temp-buffer
>   (org-mode)
>   (let ... ...)
>   (org-hide-block-toggle)
>   (org-forward-paragraph)
>   (looking-at "P3")))
>   :value nil))
>FAILED  668/734  test-org/forward-paragraph

These one are related to invisible text. I don't what is going to change
in this area in next Emacs release.

> I have an unrelated make test question too.
>
> If I add a test, say test-org/foo, in order to make learning ert and org
> test writing faster, it is possible to run just that one test-org/foo and
> not the whole suite?

You can run, e.g.,

  BTEST_RE="foo" make test


Regards,

-- 
Nicolas Goaziou



[O] 6 failing tests on master branch

2017-06-08 Thread Kaushal Modi
Hello,

I ran make test today using the latest version of org master branch (and
latest of emacs master), and I see 6 failures:

6 unexpected results:
   FAILED  ob-fortran/list-matrix-from-table1
   FAILED  ob-fortran/list-matrix-from-table2
   FAILED  ob-fortran/list-var-from-table
   FAILED  test-org-export/file-uri
   FAILED  test-org/custom-properties
   FAILED  test-org/forward-paragraph

I remember reading that someone else too saw the fortran errors.. Is it
because I don't have fortran on my system?

About the other 3 errors:

Test test-org-export/file-uri condition:
(ert-test-failed
 ((should
   (equal "file://myself@some.where:papers/last.pdf"
  (org-export-file-uri "/myself@some.where:papers/last.pdf")))
  :form
  (equal "file://myself@some.where:papers/last.pdf"
"file:///myself@some.where:papers/last.pdf")
  :value nil :explanation
  (arrays-of-different-length 40 41
"file://myself@some.where:papers/last.pdf"
"file:///myself@some.where:papers/last.pdf" first-mismatch-at 7)))
   FAILED  406/734  test-org-export/file-uri

Test test-org/custom-properties condition:
(ert-test-failed
 ((should
   (let
   (...)
 (org-test-with-temp-text "* H
:PROPERTIES:
:FOO: val
:END:
" ... ...)))
  :form
  (let
  ((org-custom-properties ...))
(org-test-with-temp-text "* H
:PROPERTIES:
:FOO: val
:END:
"
 (org-toggle-custom-properties-visibility)
 (org-invisible-p2)))
  :value nil))
   FAILED  646/734  test-org/custom-properties

(ert-test-failed
 ((should
   (org-test-with-temp-text "#+BEGIN_CENTER
P1

P2
#+END_CENTER
P3"
(org-hide-block-toggle)
(org-forward-paragraph)
(looking-at "P3")))
  :form
  (let
  ((inside-text ...)
   (org-mode-hook nil))
(with-temp-buffer
  (org-mode)
  (let ... ...)
  (org-hide-block-toggle)
  (org-forward-paragraph)
  (looking-at "P3")))
  :value nil))
   FAILED  668/734  test-org/forward-paragraph

---

I have an unrelated make test question too.

If I add a test, say test-org/foo, in order to make learning ert and org
test writing faster, it is possible to run just that one test-org/foo and
not the whole suite?
-- 

Kaushal Modi