bugGNU Octave - Bugs: bug #50396, documentation tab in GUI empty

 
 

bug #50396: documentation tab in GUI empty

Submitter:  A.R. Burgers <arb>
Submitted:  Fri 24 Feb 2017 10:40:15 PM UTC
   
 
Category:  Documentation Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Regression
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Tue 02 May 2017 09:51:41 PM UTC, comment #8: 

Verified fix.  Closing report.

Rik <rik5>
Group administrator
Tue 02 May 2017 09:49:58 PM UTC, comment #7: 

I pushed this changeset:

http://hg.savannah.gnu.org/hgweb/octave/rev/b605146ed2ed

Does it fix the problem for you? The change is to initialize the global variables in the application object instead of the interpreter object. That way, Vinfo_file is available for the GUI initialization.

There are about 50 global variables like Vinfo_file. Many are given default values by the call to install_defaults. Eventually, I'd like to move variables like this to be members of the application or interpreter object, whichever is more appropriate for each of them.

John W. Eaton <jwe>
Group administrator
Mon 27 Feb 2017 04:29:02 PM UTC, comment #6: 

The patch in comment #5 will do for a workaround on Windows, but Linux and Mac users still have a problem.  They can temporarily use the fix in comment #2 that I suggested.  Long term, this needs to be fixed properly so it works reliably everywhere.

Rik <rik5>
Group administrator
Mon 27 Feb 2017 12:48:20 PM UTC, comment #5: 

Another quick fix, based on Rik's comment #2, would be the attached patch for octave.vbs (in mxe-octave)
That patch seems to work quite fine for me.

(file #39836)

Philip Nienhuis <philipnienhuis>
Group Member
Sun 26 Feb 2017 09:46:18 PM UTC, comment #4: 

As a quick hack to verify the race condition I added a "sleep (5);" function call to the constructor in webinfo.cc.  Unfortunately, this just delayed the launch of the GUI by 5 seconds, and then the same printf ordering showing the GUI starting before the Octave interpreter thread.

Rik <rik5>
Group administrator
Sat 25 Feb 2017 08:48:04 PM UTC, comment #3: 

I added some print statements and from what I can determine this is an order of execution issue (race condition).  The GUI browser for the documentation uses the global variable Vinfo_file which contains the full-path name of the file to use.  The code for this is in libgui/src/qtinfo/webinfo.cc.  The Octave interpreter sets this global variable in set_info_file_name() which in turn is called by the general initialization function install_defaults().

The problem seems to be the multi-threaded nature of the GUI with one thread for the actual GUI and another thread for the Octave interpreter.  When I run the GUI the print statements reveal that the GUI is initializing itself and grabbing the value of Vinfo_file before the Octave interpreter has called install_defaults().  This is likely to be a generic problem because there are other global variables that the GUI uses which reside in the Octave interpreter.

I've added jwe to the CC list since he understands the start-up sequence, including the fork and exec model, better than I do.

Rik <rik5>
Group administrator
Sat 25 Feb 2017 03:22:41 AM UTC, comment #2: 

The problem is that the GUI, not the CLI, is getting a blank name for the info file.  As a workaround, you can supply the filename on the command line.


octave --info-file=<octave_dir>/share/info/octave.info



Rik <rik5>
Group administrator
Fri 24 Feb 2017 11:46:53 PM UTC, comment #1: 

Confirmed.  The files are there but the GUI does not acknowledge them.  By contrast, if I start octave with --no-gui and use the CLI then the info files are available.  The correct location is used--I checked by using the info_file() command.

Rik <rik5>
Group administrator
Fri 24 Feb 2017 10:40:15 PM UTC, original submission:  

When I install current dev versions, and go the documentation tab in the GUI, the documentation tab show this message:


The info file or compressed versions do not exist


In my 4.2.0 installation the documentation tab works as expected.

A.R. Burgers <arb>

 

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

Attach Files:
   
   
Comment:
   

Attached Files
file #39836:  bug50396_mxe_doc.patch added by philipnienhuis (520B - application/octet-stream)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by jwe (Posted a comment)
  • -email is unavailable- added by rik5
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by arb (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
    2017-05-02 rik5 StatusReady For Test Fixed
        Open/ClosedOpen Closed
    2017-05-02 jwe StatusConfirmed Ready For Test
    2017-02-27 philipnienhuis Attached File- Added bug50396_mxe_doc.patch, #39836
    2017-02-25 rik5 Carbon-Copy- Added jwe
    2017-02-24 rik5 Item GroupInstallation Failure Regression
        StatusNone Confirmed

    Back to the top

    Powered by Savane 3.13-4448.
    Corresponding source code