bugGNU TeXmacs - Bugs: bug #4241, maxima crashes

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #4241: maxima crashes

Submitted by:  Ralf Treinen <treinen>
Submitted on:  Wed 09 Jul 2003 01:46:58 AM UTC  
 
Category: PluginsPriority: 5 - Normal
Item Group: NoneStatus: Fixed
Privacy: PublicAssigned to: None
Originator Name: Open/Closed: Closed
Release: 1.0.1.16Release: None
Fixed Release: NoneFixed Release: 
Keywords: 

(Jump to the original submission Jump to the original submission)

Tue 05 Jul 2005 08:30:46 AM UTC, comment #9:

Indeed, no problem since then.

Pascal

Pascal Romon <romon>
Mon 04 Jul 2005 08:51:11 PM UTC, comment #8:

For me this issue is solved since 1.0.5.5. Maybe it was resolved with earlier versions but I checked only now that it works even without my patch.

I'm leaving the bugreport open for the moment to see if users report this bug again.

-Ralf.

Ralf Treinen <treinen>
Project Member
Mon 05 Jan 2004 03:52:44 AM UTC, comment #7:

Sorry for the double post...incomplete...

I believe that TexMacs uses 'slocate' function to determine location of maxima help files.

In slackware 9.0, an empty directory /var/lib/slocate is set up during install but the function is not turned on until you run the command:

slocate -u

which creates a searchable, secure, database of all the files on the system from the root directory up. See manpage slocate(1).

The scope of the database can be modified by using -U <directories to include> vice the -u arguments to slocate.

The database on my system is about 35 MB, pretty large. If you only use slocate for fixing this Maxima TexMacs bug, you could use

slocate -U /<maxima_toc.html directory>

to minimize the size of the slocate.db

Cheers!

W. C. Vinyard <wcvinyard>
Mon 05 Jan 2004 03:42:15 AM UTC, comment #6:

I had the same problem after installing Maxima-5.9.0 and TexMacs.

After reading this bug report, I did

slocate -u

which created slocate.db in

/var/lib/slocate/

This solved the problem.

W. C. Vinyard <wcvinyard>
Thu 13 Nov 2003 02:33:39 PM UTC, comment #5:

Thanks for the indication. However I'm stille puzzled. I've edited the first file (init-maxima.scm) and now the maxima session launches without crashing. But I can't locate the second file
texmacs-1.0.1.24/src/System/Boot/init_texmacs.cpp
and do the (necessary ?) modifications.

Besides, when running maxima within TeXmacs, I can't get it to yield any result (though maxima itself runs properly in a separate window). I'm a newbye here but typing 2+2; <RETURN> (or <ENTER>) doesn't do a thing. And it takes an awful looooooooong time to do it.

Any hint,

thanks

Pascal Romon <romon>
Wed 12 Nov 2003 07:02:21 PM UTC, comment #4:

Unfortunately, texmacs has the tendency to use various
techniques in order to dynamically determine the location
of auxiliary files, insted of using compile-time options.

The patch that I use for the debian package is appended.
Maybe that can help you to fix it for you, but it definitely
would be better to fix the localisation code once for
good.

--- texmacs-1.0.1.21.orig/plugins/maxima/progs/init-maxima.scm
+++ texmacs-1.0.1.21/plugins/maxima/progs/init-maxima.scm
@@ -17,15 +17,10 @@
(lazy-input-converter (maxima-input) maxima)
(menu-extend texmacs-session-help-icons
(if (and (in-maxima?)
- (url-exists? "$TM_MAXIMA_HOME/info/maxima_toc.html"))
+ (url-exists? "/usr/share/doc/maxima-doc/html/maxima_toc.html"))
|
((balloon (icon "tm_help.xpm") "Maxima manual")
- (load-help-buffer "$TM_MAXIMA_HOME/info/maxima_toc.html")))
- (if (and (in-maxima?)
- (url-exists? "$TM_MAXIMA_HOME/doc/html/maxima_toc.html"))
- |
- ((balloon (icon "tm_help.xpm") "Maxima manual")
- (load-help-buffer "$TM_MAXIMA_HOME/doc/html/maxima_toc.html")))))
+ (load-help-buffer "/usr/share/doc/maxima-doc/html/maxima_toc.html")))))

(define (maxima-serialize lan t)
(import-from (texmacs plugin plugin-cmd))
--- texmacs-1.0.1.24.orig/src/System/Boot/init_texmacs.cpp
+++ texmacs-1.0.1.24/src/System/Boot/init_texmacs.cpp
@@ -263,26 +263,6 @@
if (dir != "") set_env ("M2HOME", dir);
}

- // Check for Maxima
- if (get_env ("TM_MAXIMA_HOME") == "") {
- if (exists_in_path ("maxima")) {
- string where= concretize (resolve_in_path ("maxima"));
- string s = var_eval_system ("grep 'MAXIMA_DIRECTORY=' " * where);
- string dir = s (search_forwards ("=", s) + 1, N(s));
- if ((dir == "") &&
- exists ("/usr/share/maxima/5.9.0/doc/html/maxima_toc.html"))
- dir= "/usr/share/maxima/5.9.0";
- if (dir == "") {
- string where= var_eval_system ("locate maxima_toc.html");
- if (ends (where, "/doc/html/maxima_toc.html"))
- dir= where (0, N(where)- 25);
- if (ends (where, "/info/maxima_toc.html"))
- dir= where (0, N(where)- 21);
- }
- if (dir != "") set_env ("TM_MAXIMA_HOME", dir);
- }
- }
-
// Check for Reduce
if (get_env ("reduce") == "")
if (exists_in_path ("reduce")) {

Ralf Treinen <treinen>
Project Member
Wed 12 Nov 2003 02:13:40 PM UTC, comment #3:

I see (with relief ?) that I am not the only one with that bug. To be precise TeXmacs prints onscreen the following error message:
/sw/lib/maxima/5.9.0/maxima-run-lisp: Sorry, option -run not supported for LISPTYPE=oad

and in the xterm window:
Fatal error: bad url in 'complete'
See file : url.cpp

Is this really a mislocation problem with maxima_toc.html ?
If yes, what do you mean by "hardwiring it" ? Do you put a maxima_toc.html file somewhere ?

Thanks

Pascal Romon <romon>
Thu 18 Sep 2003 09:07:04 PM UTC, comment #2:

I confirm that mislocation of maxima_toc.html is indeed the
reason why texmacs crashes when trying to start maxima.
The code in the maxima plugins which is supposed to check
accessibility of the file does not work, I don't understand
why.

For the debian package I just hardwired the location where
the maxima_toc.html file would be installed.

Ralf Treinen <treinen>
Project Member
Sat 06 Sep 2003 10:16:34 PM UTC, comment #1:

I found the reason for this from some mailing list archive: the crash happens if Texmacs can't find file maxima_toc.html. When the file doesn't exist, 'locate' (or whatever the current version of Texmacs uses for finding files) returns an empty string and Texmacs chokes when trying to treat it as a URL.

The best way to fix this would be to make the Maxima plugin test the existence of the help file and write an error message to the sheet on failure instead of blindly trying to open the non-existent file.

elonen
Wed 09 Jul 2003 01:46:58 AM UTC, original submission:

Invoking maxima from the menu (Text -> Session -> Maxima)
crashes:

Fatal error: bad url: base=/home/rt, u={} in 'complete'
See file : url.cpp

(I have patched the "complete" function in url.cpp to display the base and u parameters in case of a fatal error).

This is a debian sid system, texmacs is installed with
the default settings (though the same error occurs with
the debian package of texmacs). Maxima is version
5.9.0

Ralf Treinen <treinen>
Project Member

 

No files currently attached

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -unavailable- added by mdbenito (Updated the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 3 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Mon 05 Mar 2012 03:11:48 PM UTCmdbenitoStatusNone=>Fixed
      Open/ClosedOpen=>Closed
    Tue 20 Apr 2004 11:35:06 AM UTCddaaCategoryNone=>Plugins

    Back to the top


    Powered by Savane 3.1-cleanup1