[ prog / sol / mona ]

prog


How can I run my own instance of this

201 2020-05-27 05:18

>>200
Unfortunately, 90% of MIT/GNU Scheme's users are MIT professors, CS students and MIT/GNU Scheme developers. Most bug reports are filed by the former group.

Also, I'm having a bit of trouble getting SchemeBBS to work. HTML files don't seem to get successfully generated from sexp files.

schemebbs % ls data
ls: cannot access 'data': No such file or directory
schemebbs % ./create-boards.sh foo
schemebbs % tree data
data
├── html/
│   └── foo/
│       └── index
└── sexp/
    └── foo/
        └── index

schemebbs % curl localhost:8080/foo
<!DOCTYPE HTML PUBLIC "ISO/IEC 15445:2000//DTD HyperText Markup Language//EN">
[truncated]
<P class="footer">bbs.scm + <A href="https://www.gnu.org/software/mit-scheme/">MIT Scheme</A> + <A href="https://mitpress.mit.edu/sites/default/files/sicp/index.html">SICP</A> + Satori Mode</P></BODY></HTML>

schemebbs % curl -X POST localhost:8080/foo/post -d 'titulus=test&epistula=test'
curl: (52) Empty reply from server
schemebbs % tree data
data
├── html/
│   └── foo/
└── sexp/
    └── foo/
        ├── 1
        ├── index
        └── list

schemebbs % curl localhost:8080/foo
curl: (52) Empty reply from server

The last curl call causes SchemeBBS to log the following a bunch of times:

-> evaluating handler: #[compound-procedure 17]
Error code 0x4 (system-call).
Procedure was: [PRIMITIVE NEW-FILE-OPEN-INPUT-CHANNEL]
# of arguments: 2
Return code: internal-apply
202 2020-05-27 06:36

>>201
You need to patch the file http-syntax.scm (and recompile mit-scheme). To quote the repo:

The file runtime/http-syntax.scm follows the RFC 2616 which requires that the value of the Location header be an absolute URI. The standard has been replaced (see RFC 7231 section 7.1.2.) and a relative URI is now allowed.

Recoding the redirection after posting would mean SchemeBBS not being domain agnostic. I know patching makes the install cumbersome, I'll try to get both patches incorporated in MIT Scheme 10, http-syntax and httpio (now http-io) because those two libraries have bugs and haven't changed (I just checked).

If you don't want to recompile MIT Scheme, there's a pre-compiled binary for x86_64 here: https://textboard.org/static/mit-scheme-9.2/

301


VIP:

do not edit these