John H Palmieri wrote: > Here's a proposal: the banner could look like this (looks best in > fixed-width font -- the first line and the last two lines are > centered): > > ---------------------------------------------------------------------- > | Sage version 4.1.1, release date 2009-08-14 | > | | > | * Type "notebook()" for the notebook interface. | > | * Type "sage_help()" for help. | > | * Type "quit" (or ctrl-D) to quit. | > | | > | Sage is distributed under the GNU General Public License; | > | type "license()" for more information. | > ---------------------------------------------------------------------- > > The function 'sage_help' is new, and prints a message like this: > > > For help on a Sage function, module, etc., type its name followed by a > question mark, as in "animate?" or "sage.calculus.calculus?". Sage > comes with extensive documentation: type "sage_doc." followed by the > TAB key to see a list of the documents available, and type > "sage_doc.tutorial()" to open the Sage tutorial (for example) in a web > browser. From the Sage notebook, you can also access these documents > by clicking the "Help" button at the upper right. You can browse > these documents on-line by visiting http://sagemath.org/doc/. > > > This doesn't address the original question of getting the system > information there. I think something very brief about this would be > fine: the first few lines could be > > ---------------------------------------------------------------------- > | Sage version 4.1.1, release date 2009-08-14 | > | Mac OS X 10.5, 64-bit Intel, built on 2009-08-20 | > | | > > I don't want to overload the banner, but this way, if people included > this in bug reports, we could perhaps identify binary distributions > vs. source distributions, and we'd have some system information. I > agree with other posters that more detailed system information should > be available, but I don't know a natural way to include it in the > banner. Something like "When Sage crashes, email us the output from > the command '...' " is not good PR. > > John
If one printed the hostname and the hostname on which Sage was built, then it would be possible to determine with a reasonable degree of certainty whether Sage was built on that machine or not. I think that is better than using the date. It might be sensible to print information about the machine it was built on only if it different from the machine Sage was running on. On Solaris, the best way to check for sure would be to use the 'hostid' as that is unique to a particular machine. (On SPARC its determined from the hardware, on x86 it is generated randomly when Solaris x86 is installed). I think knowing what version of gcc they used (if they used gcc) would be particularly helpful. It is quite easy to get too, as GCC defines some macros. GCC 4.2.1 will define __GNUC__ to 4, __GNUC_MINOR__ to 2, and __GNUC_PATCHLEVEL__ to 1. On Solaris at least: $ prtconf | grep "Memory size:" Memory size: 32544 Megabytes gives the memory. I don't mind having a go at writing some C code to get basic system information, but I'm not going to try to do it in python myself. If such a package could be built very early on in the build of Sage, it would be possible to use it in some tests for other packages. Those packages could for example find out what linker is being used, which could be particularly useful on Solaris. I'd suggest a program that takes an argument and returns what you want. i.e. $ system_information --ram 32544 MB $ system_information --processor UltraSPARC-IV+ $ system_information --compiler gcc 4.4.1 --~--~---------~--~----~------------~-------~--~----~ To post to this group, send an email to sage-devel@googlegroups.com To unsubscribe from this group, send an email to sage-devel-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://www.sagemath.org -~----------~----~----~----~------~----~------~--~---