#28 Describe function gives a 404 error

closed-rejected
Sam Steingold
None
5
2008-11-23
2008-11-05
Joe Smith
No

As described in https://bugs.edge.launchpad.net/ubuntu/+source/clisp/+bug/151249

The describe function will first check http://www.lisp.org/HyperSpec/Data/Map_Sym.txt and then http://www.lisp.org/HyperSpec/Data/Symbol-Table.text for a lookup. Redundancy is great, except this leads to a 404 error with the first one at Map_Sym.txt. I ran a grep over the source, and found the code in src/clhs.lisp. I don't think that we should check a page that will always give us a 404 error every time. If this isn't in the right format, or there's something you'd like me to change, please let me know. Thanks guys!

Testcase:
(DESCRIBE 'FORMAT)

Expected:
Return lookup info

Actual:
Gives a 404 from the first page, then checks the second for results.

Index: clhs.lisp

RCS file: /cvsroot/clisp/clisp/src/clhs.lisp,v
retrieving revision 1.56
diff -u -r1.56 clhs.lisp
--- clhs.lisp 24 Sep 2008 16:45:56 -0000 1.56
+++ clhs.lisp 5 Nov 2008 22:37:26 -0000
@@ -257,8 +257,8 @@
(let ((clhs-root (clhs-root)))
(when (and clhs-root (string/= clhs-map-source clhs-root))
(setq clhs-map-source clhs-root)
- (with-open-stream (s (or (open-url (string-concat clhs-root "Data/Map_Sym.txt") :if-does-not-exist nil)
- (open-url (string-concat clhs-root "Data/Symbol-Table.text") :if-does-not-exist nil)))
+ (with-open-stream (s (or (open-url (string-concat clhs-root "Data/Symbol-Table.text") :if-does-not-exist nil)
+ nil))
(unless s
(warn (TEXT "~S returns invalid value ~S, fix it, ~S, ~S, or ~S")
'clhs-root clhs-root '(getenv "CLHSROOT")

Discussion

  • Joe Smith
    Joe Smith
    2008-11-05

    Fix src/clhs.lisp to only check a working webpage

     
    Attachments
  • Joe Smith
    Joe Smith
    2008-11-05

    sds - Or I can read the comments and realize you've already determined this is correct behavior.

    You've (obviously) got final say, but I'm just curious if that page is coming back, or if there's another reason to keep continue to visit that page first.

     
  • Joe Smith
    Joe Smith
    2008-11-05

    Oh, awesome.

    In clhs.lisp, it looks like it's checking www.lisp.org as opposed to lispworks.com, which is what's giving the error, maybe changing that would work?

     
  • Sam Steingold
    Sam Steingold
    2008-11-05

    clhs.lisp checks whatever clhs-root returns.
    you can set that in many places, see the manual.
    as a clisp package maintainer, you might want to check out the --hyperspec option of the top-level configure script.

     
  • Sam Steingold
    Sam Steingold
    2008-11-05

    • assigned_to: nobody --> sds
    • status: open --> pending-rejected
     
  • Sam Steingold
    Sam Steingold
    2008-11-06

    you got me confused.
    first, please do not touch makemake.
    just pass --hyperspec=... to the top-level configure.
    second, what are you trying to do now?
    everything works fine.
    if you are worried that an clhs location might go away,
    this should not be a problem to the users - they just set *clhs-root-default* in ~/.clisprc.

     
  • Sam Steingold
    Sam Steingold
    2008-11-06

    I am checking 2 files. one is wrong. one is correct. I don't know which.

     
  • Joe Smith
    Joe Smith
    2008-11-06

    Alright, I gotcha, I see where it's going now. Thanks for explaining it.

     
  • This Tracker item was closed automatically by the system. It was
    previously set to a Pending status, and the original submitter
    did not respond within 14 days (the time period specified by
    the administrator of this Tracker).

     
    • status: pending-rejected --> closed-rejected