bugGNU Octave - Bugs: bug #48925, problem with m-files in private...

 
 

bug #48925: problem with m-files in private directory

Submitter:  Avinoam Kalma <avinoam>
Submitted:  Sat 27 Aug 2016 07:04:57 PM UTC
   
 
Category:  Interpreter Severity:  2 - Minor
Priority:  3 - Low Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Avinoam 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

Sun 10 Mar 2019 06:41:52 PM UTC, comment #11: 

No response, asumming this has been fixed in the latest release.  Closing report.

Rik <rik5>
Group administrator
Sun 03 Mar 2019 07:31:27 AM UTC, comment #10: 

@Avinoam: Is this still a problem?  Seems to work on Linux  now.

Rik <rik5>
Group administrator
Sun 20 Jan 2019 06:28:04 PM UTC, comment #9: 

Re-tagging as 5.0.1

Avinoam Kalma <avinoam>
Group Member
Wed 16 Nov 2016 08:52:42 PM UTC, comment #8: 

Re-tagging as 4.2.0

Avinoam Kalma <avinoam>
Group Member
Thu 15 Sep 2016 09:23:21 PM UTC, comment #7: 

I can confirm this on Linux as well.  The problem seems to be that although PATH has the current directory ('.') on it, files which are returned are being filtered out because they match the name of another PATH entry with "/private" appended to it.

As a workaround, instead of changing directory into the private dir, just add the correct dir to your path.


addpath ('D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun\private')
which compare_plot_demos



Rik <rik5>
Group administrator
Wed 14 Sep 2016 02:47:18 PM UTC, comment #6: 

The problem is that there is a compare_plot_demos.m file in that library.
This bug still exists in 4.2.0-rc1

Avinoam Kalma <avinoam>
Group Member
Wed 14 Sep 2016 01:49:53 PM UTC, comment #5: 


>> pwd
ans = D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun
>> cd private
>> pwd
ans = D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun\private


So it is working as expected, correct? Maybe this has been fixed in 4.2.0-rc1.

Now just make sure that there is a compare_plot_demos.m file in


D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun\private


and it should work.

Bernardo Sulzbach <mafagafogigante>
Tue 13 Sep 2016 08:47:22 PM UTC, comment #4: 

The results:


>> pwd
ans = D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun
>> cd private
>> pwd
ans = D:\Octave\Octave-4.2.0-rc1\share\octave\4.2.0-rc1\m\testfun\private
>> compare_plot_demos
error: 'compare_plot_demos' undefined near line 1 column 1


Avinoam Kalma <avinoam>
Group Member
Tue 13 Sep 2016 09:45:18 AM UTC, comment #3: 

Would you care to post the result of the following (I don't have a Windows box to test it myself):


pwd
cd private
pwd


Bernardo Sulzbach <mafagafogigante>
Sat 27 Aug 2016 07:10:52 PM UTC, comment #2: 

Sorry for the noise: a full corrected report:

For example: Octave starts in directory
D:\Octave\Octave-4.1.0+\share\octave\4.1.0+\m\testfun. If I use "cd private" Octave does not recognize the m-files in the private directory:

In 4.0.3:


>> cd private
>> compare_plot_demos
error: no such file,
'D:\Octave\Octave-4.1.0+\share\octave\4.1.0+\m\testfun\private\private\dump_demos.m'
error: called from compare_plot_demos at line 80 column 3



in 4.0.1+ (cs 52c205a0ad88
52c205a0ad88):


>> cd private
>> compare_plot_demos
error: 'compare_plot_demos' undefined near line 1 column 1


It looks like octave is searching in for the files in the folder private\private. Note that the error in 4.0.1 is much less informative.

If Octave starts in the private directory, everything is OK.

Tested with MXE-Octave on Win-10 machine.


Avinoam Kalma <avinoam>
Group Member
Sat 27 Aug 2016 07:06:11 PM UTC, comment #1: 

Correction: Octave starts in directory D:\Octave\Octave-4.1.0+\share\octave\4.1.0+\m\testfun

Avinoam Kalma <avinoam>
Group Member
Sat 27 Aug 2016 07:04:57 PM UTC, original submission:  


For example: Octave starts in directory D:\Octave\Octave-4.1.0+\share\octave\4.1.0+\m\plot\util\private. If I use "cd private" Octave does not recognize the m-files in the private directory:

In 4.0.3:


>> cd private
>> compare_plot_demos
error: no such file, 'D:\Octave\Octave-4.1.0+\share\octave\4.1.0+\m\testfun\private\private\dump_demos.m'
error: called from compare_plot_demos at line 80 column 3


in 4.0.1+ (cs 52c205a0ad88):


>> cd private
>> compare_plot_demos
error: 'compare_plot_demos' undefined near line 1 column 1
-verbatim+

It looks like octave is searching in for the files in the folder private\private. Note that the error in 4.0.1 is much less informative.

If Octave starts in the private directory, everything is OK.

Tested with MXE-Octave on Win-10 machine.

Avinoam Kalma <avinoam>
Group Member

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by mafagafogigante (Posted a comment)
  • -email is unavailable- added by avinoam (Submitted the item)
  • -email is unavailable- added by avinoam
  •  

    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 11 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2019-03-10 rik5 StatusConfirmed Fixed
        Open/ClosedOpen Closed
    2019-02-26 mtmiller Release5.0.1 dev
    2019-01-20 avinoam Release4.2.0 5.0.1
    2016-11-16 avinoam Release4.2.0-rc1 4.2.0
    2016-09-15 rik5 Severity3 - Normal 2 - Minor
        Priority5 - Normal 3 - Low
        StatusNone Confirmed
        Operating SystemMicrosoft Windows Any
    2016-09-13 avinoam Release4.0.3 4.2.0-rc1
    2016-08-27 avinoam Carbon-Copy- Added -email is unavailable-

    Back to the top

    Powered by Savane 3.13-f8d8.
    Corresponding source code