bugGNU Octave - Bugs: bug #65461, Can't install MVApack package

 
 

bug #65461: Can't install MVApack package

Submitter:  None
Submitted:  Thu 14 Mar 2024 08:37:23 AM UTC
   
 
Category:  Octave Package Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Installation Failure
Status:  Need Info Assigned to:  None
Originator Name:  Julien G Originator Email:  -email is unavailable-
Open/Closed:  * Open Release:  * 8.4.0
Operating System:  * Microsoft Windows Fixed Release:  None
Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Fri 15 Mar 2024 09:14:08 AM UTC, comment #4: 

Thank you for your answers.

The problem really came from the version of Octave. However, I, now, get a fatal error : octave/oct.h: No such file or directory.

Throughout my research, I didn't get why and how could this error appear knowing that i'm running my command on Octave directly ?
I have a whole of bunch of error appearing but I feel like it all comes down from this fatal error (but i may be wrong)

All the errors appearing :

lib/input.cpp: In function 'ScanOPs scans_from_file(const Path&, Int32)':
lib/input.cpp:109:21: error: invalid initialization of reference of type 'const String&' {aka 'const std::__cxx11::basic
_string<char>&'} from expression of type 'const Path' {aka 'const std::filesystem::__cxx11::path'}
  109 |     if(!file_exists(path)) {
      |                     ^~~~
In file included from include/datastructures.h:8,
                 from lib/input.cpp:7:
include/util.h:39:14: note: in passing argument 1 of 'bool file_exists(const String&)'
   39 | file_exists( String const& );
      |              ^~~~~~~~~~~~~
lib/input.cpp:113:49: error: invalid initialization of reference of type 'const String&' {aka 'const std::__cxx11::basic
_string<char>&'} from expression of type 'const Path' {aka 'const std::filesystem::__cxx11::path'}
  113 |     const String ext = lowercase(file_extension(path));
      |                                                 ^~~~
In file included from include/datastructures.h:8,
                 from lib/input.cpp:7:
include/util.h:45:16: note: in passing argument 1 of 'String file_extension(const String&)'
   45 | file_extension(String const &);
      |                ^~~~~~~~~~~~~~
lib/input.cpp:124:63: error: invalid initialization of reference of type 'const String&' {aka 'const std::__cxx11::basic
_string<char>&'} from expression of type 'const Path' {aka 'const std::filesystem::__cxx11::path'}
  124 |         std::cout<<"Unknown file extension: "<<file_extension(path)<<" for file " <<path<<"\n";
      |                                                               ^~~~
In file included from include/datastructures.h:8,
                 from lib/input.cpp:7:
include/util.h:45:16: note: in passing argument 1 of 'String file_extension(const String&)'
   45 | file_extension(String const &);
      |                ^~~~~~~~~~~~~~
In file included from lib/octave-connect.cpp:4:
include/octave-connect.h:11:10: fatal error: octave/oct.h: No such file or directory
   11 | #include <octave/oct.h>
      |          ^~~~~~~~~~~~~~
compilation terminated.
lib/peak.cc:3:10: fatal error: octave/oct.h: No such file or directory
    3 | #include <octave/oct.h>
      |          ^~~~~~~~~~~~~~

Anonymous
Fri 15 Mar 2024 08:03:46 AM UTC, comment #3: 

`pkg` expects that packages eventually define a `pre_install.m` function that accepts one arguments see

https://docs.octave.org/v4.4.0/Creating-Packages.html#Creating-Packages

Before Octave 7 it was possible to define `function pre_install ()` without any argument, and the the argument passed by pkg would be silently ignored. Since Octave 7 one has to explicitly ignore the argument, e.g. `function pre_install (~)` or an error will occur.

Pantxo Diribarne <pantxo>
Group Member
Thu 14 Mar 2024 03:03:52 PM UTC, comment #2: 

in the meantime, from the error message your reported, I suspect the issue is on the package side.

"function called with too many inputs" is an error message introduced after version 7.1 with this change: https://hg.savannah.gnu.org/hgweb/octave/rev/b0b80efecea1

See https://octave.org/NEWS-7.html
"Calling a user-defined function with too many inputs or outputs is now an error. The interpreter makes this check automatically."

It means that you called a function with more inputs than that function was designed to take.  What's unclear is what the "pre-install" function is trying to do. It could be that an octave function definition changed and the package is still trying to call it the old way, or it could mean that a package function is making an internal function call with excess arguments and that was allowed to slide in old versions.

In any case, we're guessing without access to the code or participation of the package maintainers.

Nicholas Jankowski <nrjank>
Group Member
Thu 14 Mar 2024 01:00:20 PM UTC, comment #1: 

from a google search it looks like you are referring to a package hosted at the University of Nebraska-Lincoln?
https://mvapack.unl.edu/

it looks like the code to examine is behind a registration wall requiring an academic login.  this will make it hard if not impossible for us to help you troubleshoot the issue. They do mention the code is fully GNU GPLv3 compliant, which (I am not a lawyer) should mean you are free to also share the code. If that can be facilitated, we might be able to see what the issue is.

In the meantime, can you check to see if an older version of octave was able to install the package?  the link to all windows versions including old versions is at the bottom of the Octave download page at https://octave.org/download#ms-windows

Nicholas Jankowski <nrjank>
Group Member
Thu 14 Mar 2024 08:37:23 AM UTC, original submission:  

Hi,

I'm trying to install the mvapack package and while installing it as shown in the mvapack documentation I get this error:

>> pkg install "mvapack-20231102.tar.gz"

error: pre_install: function called with too many inputs
error: called from
    pre_install
    install>prepare_installation at line 377 column 7
    install at line 201 column 7
    pkg at line 619 column 9

I already contacted the Mvapack support and they tlod me that It was probably more of an Octave problem than a problem on their side.

Do you have any idea what the issue is ?

Thank you for your answer,
Julien.

Anonymous

 

(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 pantxo (Posted a comment)
  • -email is unavailable- added by nrjank (Posted a comment)
  • -email is unavailable- added by None (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 2 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2024-03-14 nrjank CategoryOctave Function Octave Package
        StatusNone Need Info

    Back to the top

    Powered by Savane 3.13-cf05.
    Corresponding source code