bugGNU Octave - Bugs: bug #48865, provide warning ID to optionally...

 
 

bug #48865: provide warning ID to optionally suppress load path warning messages

Submitter:  Eric Barnhill <ericbarnhill>
Submitted:  Tue 23 Aug 2016 08:36:47 AM UTC
   
 
Category:  Interpreter Severity:  1 - Wish
Priority:  3 - Low Item Group:  Feature Request
Status:  Fixed Assigned to:  None
Originator Name:  Eric Barnhill 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 09 May 2021 06:04:57 PM UTC, comment #6: 

Thank you for testing.

Closing as fixed.


The error about the missing symbol seems unrelated to this change. Could you please open a new bug report? If possible, please attach a small example that reproduces the error.

Markus Mützel <mmuetzel>
Group administrator
Sun 09 May 2021 06:11:57 AM UTC, comment #5: 

Works for me on a patched version of octave-6.2.0 and octave-devel

Some of my tests fail with octave-devel because mkoctfile fails to link an oct-file:
undefined symbol: _ZmlRK16ComplexRowVectorRK13ComplexMatrix

Robert Jenssen <morgawr>
Sat 08 May 2021 11:49:02 AM UTC, comment #4: 

Thanks for your patch.
The "Preview" button probably ate your attachment. That happened to me several times before.

I made some minor changes and pushed it here:
https://hg.savannah.gnu.org/hgweb/octave/rev/1b945016d837

Marking as ready for test.

Markus Mützel <mmuetzel>
Group administrator
Wed 05 May 2021 02:32:54 AM UTC, comment #3: 

File attachment didnt seem to work so bug48865.patch is:


# HG changeset patch
# User Robert Jenssen <robertjenssen@ozemail.com.au>
# Date 1620180956 -36000
#      Wed May 05 12:15:56 2021 +1000
# Node ID 5ff1a104321d1a3bd5cf33ac1e563670bd262a10
# Parent  7460baab17ad02166e9056b808ac5557513917f3
libinterp/corefcn/load-path.cc : add warning ids to update and dir_info

diff -r 7460baab17ad -r 5ff1a104321d libinterp/corefcn/load-path.cc
--- a/libinterp/corefcn/load-path.cc        Tue May 04 14:03:19 2021 -0700
+++ b/libinterp/corefcn/load-path.cc        Wed May 05 12:15:56 2021 +1000
@@ -408,8 +408,9 @@
         bool ok = di.update ();

         if (! ok)
-          warning ("load-path: update failed for '%s', removing from path",
-                   di.dir_name.c_str ());
+          warning_with_id ("Octave:load-path-update-failed",
+            "load-path: update failed for '%s', removing from path",
+            di.dir_name.c_str ());
         else
           add (di, true, "", true);
       }
@@ -1332,7 +1333,9 @@
     if (! fs)
       {
         std::string msg = fs.error ();
-        warning ("load_path: %s: %s", dir_name.c_str (), msg.c_str ());
+        warning_with_id ("Octave:load-path-dir-info-update",
+                  "load_path: %s: %s", dir_name.c_str (), msg.c_str ());
+
         return false;
       }


Robert Jenssen <morgawr>
Wed 05 May 2021 02:26:31 AM UTC, comment #2: 

The attached patch file adds warning ids for load_path::update and load_path::dir_info. This allows me to suppress these warnings.

Robert Jenssen <morgawr>
Tue 11 Feb 2020 01:50:42 AM UTC, comment #1: 

Discovered this old feature request, still valid, and not yet done in Octave's development branch.

Mike Miller <mtmiller>
Group Member
Tue 23 Aug 2016 08:36:47 AM UTC, original submission:  

It is currently not possible to toggle the following warning except by turning all warnings off:

--
warning: load_path: /home/ericbarnhill/Documents/MATLAB/MATLABMRE/full_dicom_sets/MMRE_HC_yk_2014_01_07/Phase: No such file or directory
--

Would it be possible to associate this warning with an ID so that I can toggle it?

Eric Barnhill <ericbarnhill>

 

(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

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by mmuetzel (Posted a comment)
  • -email is unavailable- added by morgawr (Posted a comment)
  • -email is unavailable- added by ericbarnhill (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 10 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2021-05-09 mmuetzel StatusReady For Test Fixed
        Open/ClosedOpen Closed
    2021-05-08 mmuetzel StatusNone Ready For Test
    2020-02-11 mtmiller Dependencies- bugs #56199 is dependent
    2020-02-11 mtmiller CategoryOctave Function Interpreter
        Severity3 - Normal 1 - Wish
        Priority5 - Normal 3 - Low
        Release4.0.3 dev
        Operating SystemGNU/Linux Any
        SummaryProvide warning ID for load path errors provide warning ID to optionally suppress load path warning messages

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code