bugGNU Octave - Bugs: bug #35187, the "help" command...

 
 

bug #35187: the "help" command displays truncated help (words missing, etc)

Submitter:  a.dawid <dawid>
Submitted:  Wed 28 Dec 2011 01:52:13 PM UTC
   
 
Category:  None Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Inaccurate Result
Status:  Invalid / Not an Octave Bug Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 3.4.3 Operating System:  * Microsoft Windows
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Wed 29 Feb 2012 11:30:05 PM UTC, comment #29: 

The latest stable release for Windows is octave3.6.0_gcc4.6.2, so I tested that.

Nice! 'help inv' works out of the box. No annoying warnings on startup either.

Mark Messer <mmesser313>
Wed 29 Feb 2012 09:31:03 PM UTC, comment #28: 

I see that Nitsan posted while I was typing. I will download 3.6.1 and try it.

Mark Messer <mmesser313>
Wed 29 Feb 2012 09:18:11 PM UTC, comment #27: 

I wrote to Eli Zaretskii. He reports

- The file (texinfo-4.13a-w32-bin.zip) I downloaded from http://sourceforge.net/projects/ezwinports/files/texinfo-4.13a-w32-bin.zip/download and tested successfully on my computer contains makeinfo.exe 4.13a.

- No source code differences exist between versions 4.13 and 4.13a for makeinfo.exe. (There are differences for other files in the texinfo project.)

- It matters how makeinfo.exe is built. For example, linking against faulty dll's can cause failure.

- The file I downloaded was built and carefully tested by Eli. Other versions most likely saw much less testing.

- Development has stopped on the C version of makeinfo (which we use), but is continuing in Perl.

makeinfo.exe can also be found at http://ftp.gnu.org/gnu/texinfo/. Both texinfo-4.13 and texinfo-4.13a contain it. The source code for both is from 2008. I have not tested these files on my computer.

Octave should use the version of makeinfo.exe built by Eli. I have zipped this file and attached it as makeinfo-4.13a-w32-bin-ezwinports.7z.


(file #25222)

Mark Messer <mmesser313>
Wed 29 Feb 2012 09:06:07 PM UTC, comment #26: 

It seems that makeinfo.exe by itself is not suffucient. It depends uppon at least 3 dlls.

Both Tatsuros and ezwinports depend on:
libintl-8.dll
libiconv-2.dll
libgcc_s_dw2-1.dll
which are usually found in mingw32/bin (and copied to octave/bin) and the reason Mark test has failed with Tatsuros version is probably because Tatsuros has been compiled and linked with newer mingw32 and gcc-4.6.2 while Mark has tested it with Ocatve-3.4.3 with the older mingw32 dlls.
I don't know and have not tested yet the ezwinports version.

The msys version depends on:
msys-iconv-2.dll
msys-intl-8.dll
msys-1.0.dll
which are all part of msys/bin

Another strange observation:

I have noticed that I do get the garbled 'help inv' with Octave3.4.3_gcc4.5.2 but I don't get it with recent Octave3.6.1_gcc4.6.2_20120224 - both using the same msys based makeinfo.exe and dlls !

Has anyone tested this issue with latest Octave3.6.1_gcc4.6.2_20120224 ?

Nitzan

Nitzan Arazi <nitnit>
Wed 29 Feb 2012 04:40:23 PM UTC, comment #25: 

Thanks to Mark for testing.

This isn't a bug with Octave source, but it definitely affects the Window's users of Octave.  If someone could package up a more recent snapshot of makeinfo.exe that would be great.

If such a snapshot becomes available I think it would also be a good idea to make a note in README.MinGW that Octave won't work with previous versions of makeinfo before 4.13a (or whatever the version is called).

Rik <rik5>
Group administrator
Wed 29 Feb 2012 02:15:46 PM UTC, comment #24: 

This failed for me.

I am running 32 bit Windows Vista, and tested against Octave 3.4.3.

I downloaded makeinfo.7z from the link provided by Tatsuro MATSUOKA. I unzipped it and copied the makeinfo.exe to C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\msys\bin. I started Octave and typed this command: help inv

A dialog pops up saying "makeinfo.exe has stopped working". This indicates an unhandled exception. When I dismiss the dialog, Octave returns to the prompt, having displayed no help. Octave continues working.

I replace makeinfo.exe with the original, and type help inv (No need to restart Octave.) Garbled help is displayed.

I replace makeinfo.exe with a recent snapshot from http://sourceforge.net/projects/ezwinports/files/. Good help is displayed.

---
system('makeinfo --version') displays 4.13 for both the original and snapshot version of makeinfo.

It might be worthwhile to ask Eli Zaretskii (eliz@gnu.org) to create a snapshot versioned something like 4.13a.







Mark Messer <mmesser313>
Wed 29 Feb 2012 08:27:58 AM UTC, comment #23: 

makeinfo itself can be download from

http://www.tatsuromatsuoka.com/octave/Eng/Win/makeinfo.7z

Tatsuro MATSUOKA <tmacchant>
Wed 29 Feb 2012 08:10:58 AM UTC, comment #22: 

Can any of you who face the garbled help text problem can try Tatsuro's binary (packed in http://www.tatsuromatsuoka.com/octave/Eng/Win/OctaveLibs.7z) and confirm that it does solve the problem ?

If it does, I will place it in the exec-path of next mingw octave binaries (preceeding the msys version).

Regards
Nitzan

Nitzan Arazi <nitnit>
Sat 25 Feb 2012 05:53:46 PM UTC, comment #21: 

Closing report.  The problem lies outside of Octave in Makeinfo. 

Summary: it seems necessary to use either an old version of Makeinfo or the very latest version of Makeinfo, but to avoid intermediate versions.  This is important for anyone who will be packaging Octave into a binary install -- They need to include an up-to-date version of Makeinfo in the bundle.

Rik <rik5>
Group administrator
Sat 25 Feb 2012 04:00:21 PM UTC, comment #20: 

Is Makeinfo needed to build Octave? The problem was caused by using the latest release of Makeinfo?

The fix is to build with the latest snapshot. If this is being done, the bug can be closed.

Mark Messer <mmesser313>
Sat 25 Feb 2012 02:01:50 AM UTC, comment #19: 

Can this bug report be closed.  It seems that the problem has been traced to makeinfo, an external program, rather than any code within Octave.

Rik <rik5>
Group administrator
Mon 06 Feb 2012 02:31:01 PM UTC, comment #18: 


> I will try a test with the most recent source code.

 
I see that people have already tried this. So you already know that other versions of makeinfo.exe work.

I got a pointer to a texinfo Windows 32 binary built from a snapshot of the latest source code. It is dated Jan 8, 2012. See http://sourceforge.net/projects/ezwinports/files/. The makeinfo.exe in the binary works too.

Note that system("makeinfo --version") reports 

makeinfo (GNU texinfo) 4.13

Copyright (C) 2008 Free Software Foundation, Inc.

So be careful about versioning if you use it.

Mark Messer <mmesser313>
Mon 06 Feb 2012 08:39:06 AM UTC, comment #17: 

I have built makeinfo using source of the texinfo-4.13 with Benjamin's patch using gcc-4.6.2.

http://octave.svn.sourceforge.net/viewvc/octave/trunk/octave-forge/admin/Windows/mingw32/texinfo/texinfo-4.13-3.patch?revision=5498&view=markup

I have upload the archive file in
http://www.tatsuromatsuoka.com/octave/Eng/Win/

makeinfo.7z

Please copy makeinfo.exe to octave bin directory.
For me it seems to work without problem.

Tatsuro MATSUOKA <tmacchant>
Mon 06 Feb 2012 04:02:50 AM UTC, comment #16: 

I have searched my directory tree. I found that I have been used makeinfo.exe in MiKTeX 2.9.


C:\Users\Tatsu>C:\Programs\MiKTeX_2.9\miktex\bin\makeinfo --version
makeinfo (GNU texinfo) 4.7

Copyright (C) 2004 Free Software Foundation, Inc.
There is NO warranty.  You may redistribute this software
under the terms of the GNU General Public License.
For more information about these matters, see the files named COPYING.


This is just information.  At least this makeinfo works for me.

Tatsuro MATSUOKA <tmacchant>
Sun 05 Feb 2012 10:53:09 PM UTC, comment #15: 

ps: I have posted the makeinfo.exe version 4.6 file in the patch section:
https://savannah.gnu.org/patch/index.php?7722

a.dawid <dawid>
Sun 05 Feb 2012 10:37:24 PM UTC, comment #14: 

First of all, thanks Mark for these detailed descriptions and digging!

I think I jut found a work around...

Trying your tests I looked for makeinfo.exe files in my computer and discovered I had a 4.6 version in a very old dj203 install of mine.

I copied it in the octave install folder:
C:\Octave\Octave3.4.3_gcc4.5.2\msys\bin
in place of the makeinfo 4.13 originally provided in Octave and now the help works.

This work around seems to be the simpler way, but I don't know how reliable this change is regarding the other usages of makeinfo.exe made by Octave.

Else I'll try and have a look to see if I can figure out a trend between the various PC and Windows versions I have.

a.dawid <dawid>
Sat 04 Feb 2012 11:13:31 PM UTC, comment #13: 

In both Windows and Linux, makeinfo -- version reports 4.13 when invoked from the shell. In both Windows and Linux, I get this from Octave.
<textarea class="verbatim" readonly="readonly" rows="9" cols="80">
    octave:1&gt; system(&quot;makeinfo --version&quot;)
    makeinfo (GNU texinfo) 4.13
</textarea>

It is very odd that on your system the older version 4.7 makeinfo works better than 4.13, at least for Octave's use.

---
I tried your test, modified to fit my environment, by typing these commands into the terminal window.
<textarea class="verbatim" readonly="readonly" rows="9" cols="80">
    path=C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\msys;C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\mingw32;%path%
    set LANG=us
    set CPPFLAGS=-IC:include -IC:mingw/include
    cd C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2
    start C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\bin\octave --eval &quot;PS1('octave:#%gt;')&quot; --persist
</textarea>

Note that I removed the leading slash from the paths in CPPFLAGS and added a cd command. I tried this again with a backslash in the path. Any way I try it, "help inv" still produces garbled text.

---
makeinfo is part of the GNU texinfo project at http://www.gnu.org/software/texinfo.

Browsing the source code at http://cvs.savannah.gnu.org/viewvc/texinfo/texinfo/, I see the README file for makeinfo says
<textarea class="verbatim" readonly="readonly" rows="9" cols="80">
   As of Texinfo 5.0, this C implementation of makeinfo has been replaced
   by a Perl implementation; see ../texi2html.
</textarea>

On the download page (http://ftp.gnu.org/gnu/texinfo/), the latest release of texinfo/makeinfo/texi2html is version 4.13a, from 2008. I do not see a version 5.0 release.

Even so, the project is being maintained. The most recent entry in the texinfo changelog is 7 days old. The most recent changes to makeinfo and texi2html are 9 months old. According to the texi2html NEWS file dated 1/12/2012,
<textarea class="verbatim" readonly="readonly" rows="9" cols="80">
    * texi2any is a new generic converter that can produce all supported
      output formats, both those from texi2dvi (PDF/DVI) and from makeinfo
      (Info/HTML/etc.).  With this release, texi2any, makeinfo, and
      texi2html are all essentially the same program with different
      defaults.

      The new implementation is in Perl (originally the texi2html program).
      It both replaces and is intended to be (for all practical purposes)
      upward-compatible with the C makeinfo.  It has many new features not
      in the C makeinfo.  For example, cross-manual references are now fully
      supported, and extensive customization of the HTML output is possible.
      See xxx in the manual for more about this reimplementation.
 
      The new program is, unfortunately, noticeably slower at present than
      the C program was.  We hope all the many improvements make the change
      worthwhile nevertheless.
</textarea>

I will try a test with the most recent source code. If that does not work, I will file a bug report to the texinfo project referencing this Octave bug.

Mark Messer <mmesser313>
Sat 04 Feb 2012 11:10:35 AM UTC, comment #12: 

Hmmm.. on another WinXP SP3 PC, both Octave-3.4.3_gcc4.5.2 and Octave-3.6.0_gcc4.6.2 both show clean help text.

Octave 3.4.3_gcc4.5.2 on that box reports:

octave:3> system ("makeinfo --version")
makeinfo (GNU texinfo) 4.7

Copyright (C) 2004 Free Software Foundation, Inc.
There is NO warranty.  You may redistribute this software
under the terms of the GNU General Public License.
For more information about these matters, see the files named COPYING.
ans = 0
octave:4>


...but when opening a command prompt in
<octave3.4.3 install dir>/msys/bin and calling makeinfo I get:


C:\Programs\Octave\Octave3.4.3_gcc4.5.2\msys\bin>makeinfo --version
makeinfo (GNU texinfo) 4.13

Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

C:\Programs\Octave\Octave3.4.3_gcc4.5.2\msys\bin>


(...hmmmm....intruiging....)

while Octave-3.6.0_gcc4.6.2 gives:

octave:1> system ("makeinfo --version")
makeinfo (GNU texinfo) 4.13

Copyright (C) 2008 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.
ans = 0
octave:2>


and shows largely the same output if makeinfo --version is run in a cmd32 window.

I'm sure both Octave versions (3.4.3 and 3.6.0) on that box each have only one makeinfo.exe present (in ./msys/bin/).

One of the differences is that I call Octave-3.6.0 using a bat file and that in Octave-3.4.3 ./bin/octave.exe is called directly.
Furthermore, Nitzan provided a very short octaverc in ./share/octave/3.6.0/m/startup/, where the following stanzas are lacking:


msys_path = fullfile( octave_config_info("prefix"), "MSYS" );
if( exist( msys_path, "dir" ) )
   msys_path = cat(2, msys_path, filesep, "bin", ";", EXEC_PATH );
   EXEC_PATH( msys_path );
endif
clear msys_path

## check for mingw32

mingw_path = fullfile( octave_config_info("prefix"), "MINGW32" );
if( exist(mingw_path, "dir") )
   mingw_path = cat(2, mingw_path, filesep, "bin", ";", EXEC_PATH );
   EXEC_PATH( mingw_path );
endif
clear mingw_path


Perhaps try again with these commands in your octaverc file, and see if adding the mingw32 and msys /bin dirs in this way to your shell path fixes the help text problems.
Or you could start octave using an octave.bat file looking like:


@echo off
set PATH=C:\Programs\octave\3.6.0\msys\bin;C:\Programs\Octave\3.6.0\bin;C:\Programs\Octave\3.6.0\MinGW\bin;%path%

set LANG=us
set CPPFLAGS=-IC:/include -IC:/mingw/include

start C:\Programs\Octave\3.6.0\bin\octave --eval  "PS1('octave:\#> ')"  --persist

(watch out for line wrap)

Philip Nienhuis <philipnienhuis>
Group Member
Fri 03 Feb 2012 08:41:44 PM UTC, comment #11: 


> On my Windows XP SP3 (32bit), Octave-3.4.3_gcc4.5.2 shows garbled text, but Octave-3.6.0_gcc4.6.2 doesn't.

> So I conclude that this has been fixed. Agree?


I would not expect the bug has been fixed.

This is an intermittent bug that has appeared only on Windows computers. The cause is an issue in makeinfo.exe, which seems to have a number of issues. So far as I know, no change has been applied to Octave to work around or fix this bug.

In my Windows Octave 3.4.3 installation, makeinfo --version reports 4.13, copyright 2008. I expect Octave 3.6.0 uses the same makeinfo version.


I am hosting Ubuntu on my computer with VMware. I installed the the Linux version of Octave 3.4.3.  The problem does not appear.

Mark Messer <mmesser313>
Fri 03 Feb 2012 03:56:20 PM UTC, comment #10: 

On my Windows XP SP3 (32bit), Octave-3.4.3_gcc4.5.2 shows garbled text, but Octave-3.6.0_gcc4.6.2 doesn't.

So I conclude that this has been fixed. Agree?

Philip Nienhuis <philipnienhuis>
Group Member
Sat 21 Jan 2012 03:32:21 AM UTC, comment #9: 

Here is a summary of what I know about the cause of garbled help. Some of it duplicates what a dawid found. I have saved input and output in files.

'help inv' causes Octave to call <Octave home>\share\octave\3.4.3\m\help\help.m.

help.m calls get_help_text('inv'), which extracts help text containing TexInfo markup from <Octave home>\lib\octave\3.4.3\oct\i686-pc-mingw32\inv.oct. This is a binary file. But if you display inv.oct in Notepad++, you can see the text starting on "line" 431. The text is extracted cleanly.

help.m calls _makeinfo_(), passing in the text and the output format "plain text".

<Octave home>\share\octave\3.4.3\m\help\__makeinfo__.m. expands some macros in the text, if needed (@SeeAlso in this case). Then it adds a line containing '\input texinfo' to the beginning of the text, and '@bye' to the end. It writes the text to a temporary file. The temporary file is not garbled. I have saved a copy as octave-help-swldx7.

_makeinfo_.m then constructs a shell command to transliterate the markup to the desired output format. makeinfo_program() returns the name of the program to do the transliteration. By default, this is makeinfo, found in the <Octave home>\msys folder. _makeinfo_.m adds options to the shell command for either plain text or html output. Because this case is plain text, the command is
    makeinfo --no-headers --no-warn --force --no-validate C:\Users\MMesser\AppData\Local\Temp\octave-help-swldx7
The command is stored in the cmd variable.

_makeinfo_.m executes the following Octave command, so that Octave will delegate execution of makeinfo to the shell.
    [status, retval] = system (cmd);
The output of makeinfo is garbled.

help.m gets the output from makeinfo_.m and adds a few paragraphs at the beginning and end. This is displayed. I copied the output from help inv from the Octave window and stored it in HelpInvOutputFor-swldx7.txt.

---
Unlike a dawid, I found that makeinfo produces the same garbled output when I type one of these lines at the Octave prompt,
    octave:2> help inv
octave:3> [status, retval] = system('makeinfo --no-headers --no-warn --force --no-validate C:\Users\MMesser\AppData\Local\Temp\octave-help-swldx7')
or this at the DOS prompt
    makeinfo --no-headers --no-warn --force --no-validate C:\Users\MMesser\AppData\Local\Temp\octave-help-swldx7


---
The issue appears to be caused by a bug in makeinfo.exe. Word wrap is not handled correctly.

Typing 'makeinfo --help' at the DOS prompt displays options, including this.
    Options for Info and plain text:
          ...
          --fill-column=NUM       break Info lines at NUM characters (default 72).
This option is not available for html output.

The marked up text is already wrapped at column 72, so word wrap is not needed. But there is no way to disable it. makeinfo indents each line. If this makes the line too long, the last word is wrapped. When this is done, sometimes the last word is lost. Other times it prints at the beginning of the same line, which implies a CR was inserted. The next line is not indented, possibly because makeinfo does not recognize the beginning of a new line.

Adding --fill-column=76 to line 164 of _markinfo_.m reduces word wrapping, and reduces the amount of garbling. Setting --fill-column to 200 or 0 makes problems worse.

Adding --html to line 164 prevents word wrapping. The html output is correct.


---
Linux uses LF line endings. In Windows, CRLF is common.

The marked up help text in inv.oct ends each line with LF. _makeinfo_ adds lines ending with LF.

I am not sure if CR matters. I thought garbling was reduced by adding this line to _makeinfo_.m immediately before writing the temporary file.
  text = strrep (text, "\n", "\r\n")
But this could be just from changing the length of lines. And I have some inconsistent results that I need to figure out before I could draw conclusions.


---
makeinfo is part of GNU texinfo. makeinfo appears to be fragile and buggy. There are comments scattered through the code mentioning a need to work around problems by adding a blank line at the end of a text block, or removing spaces at the beginning of each line.

I have not found such a work around for this.

I did not see a word wrap bug mentioned in the texinfo project bug list. Perhaps we should add it.

'makeinfo --version' reports
    makeinfo (GNU texinfo) 4.13

    Copyright (C) 2008 Free Software Foundation, Inc.
This is the latest version.



(file #24858, file #24859)

Mark Messer <mmesser313>
Fri 13 Jan 2012 11:30:22 AM UTC, comment #8: 

Thanks Mark for confirming the issue.

I looked at the files you mentioned and I see the same as you on the one computer that has the problem (I will check the one that works to compare).

I did not find other file containing the string "Compute the inverse of the square matrix A." either. I also tried to edit the octave.info-3 file but it did not change anything. Actually, the problem is absent in the temporary help-text file that is first created by _makeinfo_ (line 154)

In my case:
  C:\Users\...AppData\Local\Temp\octave-help-zcUYaI'

at least when I look at it with Notepad++...

(and indeed if I add the option --html to the 'makeinfo' command, the text is fine - although surrounded by html markup)

so the corrupted file that you noticed is not the one that is called when one types help.

*

So the problem seems to come from the program:
  Octave3.4.3_gcc4.5.2\mysy\bin\makeinfo.exe

or from some other program called by it...

But since it is an executable file, I don't know how to track this down now.


a.dawid <dawid>
Thu 12 Jan 2012 10:33:22 PM UTC, comment #7: 

This issue has been a problem for me too.

I expect the source for the help is a TexInfo file. This file is transliterated into various formats for distribution with Octave. I think the issue is caused by transliteration errors. Tools on some systems can handle the errors, and others can't.

I installed Octave 3.4.3 on 32 bit Windows Vista, with all packages. I get this when I type help inv.

<textarea class="verbatim" readonly="readonly" rows="20" cols="80">octave:112&gt; help inv
`inv' is a function from the file C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc
4.5.2\lib\octave\3.4.3\oct\i686-pc-mingw32\inv.oct



 -- Loadable Function: X = inv (A)
 -- Loadable Function: [X, RCOND] = inv (A)
     Compute the inverse of the square matrix A.  Return an estimate
     of the reciprocal condition number if requested, otherwise warn of
 ill-conditioned matrix if the reciprocal condition number is
 In general it is best to avoid calculating the inverse
 directly.  For example, it is both faster and more
 `Y = A \of equations (A*x = b) with
 If called with a sparse
 matrix requiring in general X will be a full
 of asignificantly more storage.  Avoid forming the inverse
 See also: ldivide, rdivideble.



Additional help for built-in functions and operators is
available in the on-line version of the manual.  Use the command
`doc &lt;topic&gt;' to search the manual index.

Help and information about Octave is also available on the WWW
at http://www.octave.org and via the -email is unavailable-
mailing list.
</textarea>

I found 4 files under C:\Octave for files containing "Compute the inverse of the square matrix A.  Return an estimate". There may be more. All these files contain descriptions of many functions. 3 of the files look OK, and can correctly display information about inv. The last one matches the messed up 'help inv' display to a degree.

Two good files are under C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\doc\octave. They are html\octave.html\Basic-Matrix-Functions.html and pdf\octave.pdf. The files under this folder can be used for a work around until the issue is fixed. (The table of contents in the PDF file has errors. E.G. The TOC says 18.2 Basic Matrix Functions begins on p 377. In fact, it begins on p 365.)

The other good file is C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\share\octave\3.4.3\etc\doc-cache. It contains text with some strings to help quickly search and parse it.

The bad file is C:\Octave\Octave3.4.3_gcc4.5.2\Octave3.4.3_gcc4.5.2\share\info\octave.info-3. It contains text. Some awkward word wrapping in this file matches missing words in the help display. cr/lf line endings are inconsistent in the file. The inv discussion mentions the backslash operator. One line ends with backslash linefeed. This line in the help display is especially messed up.

Note that the modification dates on all 4 files are the same. The date is before I installed Octave.

Note the HTML file contains a comment that shows some problems exist with transliteration.

&lt;!-- Texinfo @sp should work but in practice produces ugly results for HTML. --&gt;
&lt;!-- A simple blank line produces the correct behavior. --&gt;
&lt;!-- @sp 1 --&gt;

Note the displayed help contains three sections: top (-- 'inv' is a function ...), middle (matches contents of the bad file), and bottom (Additional help for ...). I only see problems with the middle part.

I tried editing the bad file. It did not change the displayed help. Perhaps the displayed help is cached somewhere. If so, I did not find it. Perhaps the help display is based on a file I did not find.


Mark Messer <mmesser313>
Mon 09 Jan 2012 12:19:37 AM UTC, comment #6: 

Maybe Andy's remark is related, but I am not sure.

I tried to track down the source of the issue but got lost at the following:

At some point, the 'help' function calls for the '__makeinfo__' function (cf. 'help.m' line 79), which in turn calls for 'makeinfo' via the command:
[status retval] = system (cmd); (cf. '__makeinfo__' line 174)
where cmd = 'makeinfo --no-headers --no-warn --force --no-validate C:\Users\...\Temp\octave-help-zcUYaI'
(I checked all this by printing comments on the way there...)

The strange thing is the following:
If I print the value 'retval' directly from the '__makeinfo__' function (either by using printf() or just retval) then I have the problem.
However, if I use the command prompt of Octave and type:
cmd = 'makeinfo --no-headers --no-warn --force --no-validate C:\Users\...\Temp\octave-help-zcUYaI'
[status retval] = system (cmd);
and thus print retval, I have the full text, but surrounded by some sort of html markup and header (which appear neither in the output from the '__makeinfo__' function, nor in the 'octave-help-zcUYaI' file which contains only a '\input texinfo' at the beginning an a '@bye' at the end.

So basically there is no consistency in the behavior of makeinfo, and at this point it seems to root deeply in Octave or Windows - at least deeper than I can explore.

Does someone have more insight...?

a.dawid <dawid>
Fri 06 Jan 2012 08:28:55 PM UTC, comment #5: 
Jordi GutiƩrrez Hermoso <jordigh>
Group Member
Fri 06 Jan 2012 08:19:48 PM UTC, comment #4: 

So, on the second computer I tried (Win7) the help works.
But on a third one (WinXP) I encounter the exact same problem.
I tried Different Install procedure/configurations (from the .exe file or from the .7z archive, including or not the libreadline.dll.a or the sourceforge pkg) I also tried the former 3.2.4 version, none of this help.

Any insight?

a.dawid <dawid>
Sat 31 Dec 2011 10:48:56 AM UTC, comment #3: 

Ok. Thanks for looking.
I am running Octave on a Win 7 Pro (32b).
Maybe it is computer dependent or due to some Octave-internal window-size parameters?... I'll try on my other computer to see if it reproduces here too.

a.dawid <dawid>
Sat 31 Dec 2011 09:03:38 AM UTC, comment #2: 

Sorry I cannot reproduce the problem.

For me, help command works fine.
I have carried out the test windows 7 HomePremium 64 bit.



octave:1> help inv
`inv' is a function from the file C:\Octave\Octave3.4.3_gcc4.5.2\lib\octave\3.4.3\oct\i686-pc-mingw32\inv.oct

 -- Loadable Function: X = inv (A)
 -- Loadable Function: [X, RCOND] = inv (A)
     Compute the inverse of the square matrix A.  Return an estimate of
     the reciprocal condition number if requested, otherwise warn of an
     ill-conditioned matrix if the reciprocal condition number is small.

     In general it is best to avoid calculating the inverse of a matrix
     directly.  For example, it is both faster and more accurate to
     solve systems of equations (A*x = b) with `Y = A \ b', rather than
     `Y = inv (A) * b'.

     If called with a sparse matrix, then in general X will be a full
     matrix requiring significantly more storage.  Avoid forming the
     inverse of a sparse matrix if possible.

     See also: ldivide, rdivide



Additional help for built-in functions and operators is
available in the on-line version of the manual.  Use the command
`doc <topic>' to search the manual index.

Help and information about Octave is also available on the WWW
at http://www.octave.org and via the help@octave.org
mailing list.



octave:2> help fsolve
`fsolve' is a function from the file C:\Octave\Octave3.4.3_gcc4.5.2\share\octave\3.4.3\m\optimization\fsolve.m

 -- Function File:  fsolve (FCN, X0, OPTIONS)
 -- Function File: [X, FVEC, INFO, OUTPUT, FJAC] = fsolve (FCN, ...)
     Solve a system of nonlinear equations defined by the function FCN.
     FCN should accept a vector (array) defining the unknown variables,
     and return a vector of left-hand sides of the equations.
     Right-hand sides are defined to be zeros.  In other words, this
     function attempts to determine a vector X such that `FCN (X)'
     gives (approximately) all zeros.  X0 determines a starting guess.
     The shape of X0 is preserved in all calls to FCN, but otherwise it
     is treated as a column vector.  OPTIONS is a structure specifying
     additional options.  Currently, `fsolve' recognizes these options:
     `"FunValCheck"', `"OutputFcn"', `"TolX"', `"TolFun"', `"MaxIter"',
     `"MaxFunEvals"', `"Jacobian"', `"Updating"', `"ComplexEqn"'
     `"TypicalX"', `"AutoScaling"' and `"FinDiffType"'.

     If `"Jacobian"' is `"on"', it specifies that FCN, called with 2
     output arguments, also returns the Jacobian matrix of right-hand
     sides at the requested point.  `"TolX"' specifies the termination
     tolerance in the unknown variables, while `"TolFun"' is a
     tolerance for equations.  Default is `1e-7' for both `"TolX"' and
     `"TolFun"'.

     If `"AutoScaling"' is on, the variables will be automatically
     scaled according to the column norms of the (estimated) Jacobian.
     As a result, TolF becomes scaling-independent.  By default, this
     option is off, because it may sometimes deliver unexpected (though
     mathematically correct) results.

     If `"Updating"' is "on", the function will attempt to use Broyden
     updates to update the Jacobian, in order to reduce the amount of
     Jacobian calculations.  If your user function always calculates
     the Jacobian (regardless of number of output arguments), this
     option provides no advantage and should be set to false.

     `"ComplexEqn"' is `"on"', `fsolve' will attempt to solve complex
     equations in complex variables, assuming that the equations
     possess a complex derivative (i.e., are holomorphic).  If this is
     not what you want, should unpack the real and imaginary parts of
     the system to get a real system.

     For description of the other options, see `optimset'.

     On return, FVAL contains the value of the function FCN evaluated
     at X, and INFO may be one of the following values:

    1
          Converged to a solution point.  Relative residual error is
          less than specified by TolFun.

    2
          Last relative step size was less that TolX.

    3
          Last relative decrease in residual was less than TolF.

    0
          Iteration limit exceeded.

    -3
          The trust region radius became excessively small.

     Note: If you only have a single nonlinear equation of one
     variable, using `fzero' is usually a much better idea.

     See also: fzero, optimset

     Note about user-supplied Jacobians: As an inherent property of the
     algorithm, Jacobian is always requested for a solution vector
     whose residual vector is already known, and it is the last
     accepted successful step.  Often this will be one of the last two
     calls, but not always.  If the savings by reusing intermediate
     results from residual calculation in Jacobian calculation are
     significant, the best strategy is to employ OutputFcn: After a
     vector is evaluated for residuals, if OutputFcn is called with
     that vector, then the intermediate results should be saved for
     future Jacobian evaluation, and should be kept until a Jacobian
     evaluation is requested or until outputfcn is called with a
     different vector, in which case they should be dropped in favor of
     this most recent vector.  A short example how this can be achieved
     follows:

          function [fvec, fjac] = user_func (x, optimvalues, state)
          persistent sav = [], sav0 = [];
          if (nargin == 1)
            ## evaluation call
            if (nargout == 1)
              sav0.x = x; # mark saved vector
              ## calculate fvec, save results to sav0.
            elseif (nargout == 2)
              ## calculate fjac using sav.
            endif
          else
            ## outputfcn call.
            if (all (x == sav0.x))
              sav = sav0;
            endif
            ## maybe output iteration status, etc.
          endif
          endfunction

          ## ....

          fsolve (@user_func, x0, optimset ("OutputFcn", @user_func, ...))


Additional help for built-in functions and operators is
available in the on-line version of the manual.  Use the command
`doc <topic>' to search the manual index.

Help and information about Octave is also available on the WWW
at http://www.octave.org and via the help@octave.org
mailing list.



Tatsuro MATSUOKA <tmacchant>
Fri 30 Dec 2011 10:25:57 AM UTC, comment #1: 

I forgot to mention the version I'm using:
Octave 3.4.3

and I strictly followed the instructions on this page for the installation:
http://sourceforge.net/projects/octave/files/Octave_Windows%20-%20MinGW/Octave%203.4.3%20for%20Windows%20MinGW%20Installer/

a.dawid <dawid>
Wed 28 Dec 2011 01:52:13 PM UTC, original submission:  

I am a new user of Octave and as such, I still rely a lot on the "help" command. However, when I call for it, it usually displays a truncated help text, with words missing or concatenated with some others.

For example, when I call 'help inv', the beginning of the text is fine, but then at some point I get this: "otherwise warn of ill-conditioned matrix if the reciprocal condition number is [words missing]" and the help text continues directly with "In general it is best to avoid [...]"

I have this problem with most of the outputs from the 'help' command - e.g. 'help help' starts with "'helpisplay [...]".

Is this a (known) bug, or a configuration problem...?

Thanks for your help.

a.dawid <dawid>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

Attached Files
file #25222:  makeinfo-4.13a-w32-bin-ezwinports.7z added by mmesser313 (76KiB - application/octet-stream)
file #24858:  octave-help-swldx7 added by mmesser313 (893B - text/plain)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by nitnit (Posted a comment)
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by philipnienhuis (Posted a comment)
  • -email is unavailable- added by mmesser313 (Posted a comment)
  • -email is unavailable- added by jordigh (Posted a comment)
  • -email is unavailable- added by tmacchant (Posted a comment)
  • -email is unavailable- added by dawid (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2012-02-29 mmesser313 Attached File- Added makeinfo-4.13a-w32-bin-ezwinports.7z, #25222
    2012-02-29 rik5 StatusWorks For Me Invalid / Not an Octave Bug
    2012-02-25 rik5 Open/ClosedOpen Closed
    2012-01-21 mmesser313 Attached File- Added octave-help-swldx7, #24858
        Attached File- Added HelpInvOutputFor-swldx7.txt, #24859
    2012-01-09 rik5 Carbon-CopyRemoved 72865 -
    2012-01-04 rik5 StatusNone Works For Me

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code