Closed serra closed 5 years ago
The build script works and publishes the wiki to http://xscalealliance.org/wiki/#.
However, we get errors, I suspect because there is missing content.
It looks like it is trying to run in server mode. Which is odd because it doesn't do this when I open the output of rendertiddler
locally (and the newer render
). I do seem to be missing the contribution banner as well though.
If I open a version I saved manually (from the big menu). It has the contribution banner but is reports
Error retrieving skinny tiddler list: XMLHttpRequest error code: 0
Hmm. Maybe our build script is wrong.
@jamesgorman2 how do we publish now? By saving the wiki and uploading pushing the index.html file?
To reproduce locally:
tiddlywiki . --rendertiddler $:/core/save/all index.html text/plain
cd ./output
python3 -m http.server
This logs the following:
Serving HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/) ...
127.0.0.1 - - [09/Apr/2019 11:31:37] "GET / HTTP/1.1" 200 -
127.0.0.1 - - [09/Apr/2019 11:31:39] code 404, message File not found
127.0.0.1 - - [09/Apr/2019 11:31:39] "GET /status HTTP/1.1" 404 -
127.0.0.1 - - [09/Apr/2019 11:31:39] code 501, message Unsupported method ('OPTIONS')
127.0.0.1 - - [09/Apr/2019 11:31:39] "OPTIONS / HTTP/1.1" 501 -
127.0.0.1 - - [09/Apr/2019 11:31:40] code 404, message File not found
127.0.0.1 - - [09/Apr/2019 11:31:40] "GET /favicon.ico HTTP/1.1" 404 -
127.0.0.1 - - [09/Apr/2019 11:31:41] code 501, message Unsupported method ('PUT')
127.0.0.1 - - [09/Apr/2019 11:31:41] "PUT /recipes/undefined/tiddlers/%2FUsers%2Fmarijn%2Fdev%2FZefram-Cochrane%2Ftiddlers%2Ffavicon.ico HTTP/1.1" 501 -
127.0.0.1 - - [09/Apr/2019 11:31:41] code 501, message Unsupported method ('PUT')
127.0.0.1 - - [09/Apr/2019 11:31:41] "PUT /recipes/undefined/tiddlers/%24%3A%2FStoryList HTTP/1.1" 501 -
127.0.0.1 - - [09/Apr/2019 11:31:41] code 501, message Unsupported method ('PUT')
127.0.0.1 - - [09/Apr/2019 11:31:41] "PUT /recipes/undefined/tiddlers/%24%3A%2Fplugins%2Ffelixhayashi%2Ftiddlymap%2Fmisc%2FdefaultViewHolder HTTP/1.1" 501 -
I suspect those are strong hints to your trained :eye: @jamesgorman2
Something is trying to PUT
stuff to the server in the index.html file we compiled with our new build script.
Hm, interesting. This does work:
Given an open wiki in the browser
When I hit save as `adirectory/index.html` in the wiki interface
and I run a simple web server from `adirectory`
and I browse to the start page
Then the wiki opens without errors in a browser
I'm pretty sure that sth is wrong with the build script I proposed.
When I do a diff, it indeed appears that the built version includes plugins that the downloaded version does not:
...
> <div author="JeremyRuston" core-version=">=5.0.0" dependents="" description="Local filesystem syncadaptor" list="readme" plugin-type="plugin" title="$:/plugins/tiddlywiki/filesystem" type="application/json" version="5.1.17" revision="0" bag="default">
...
> <div author="JeremyRuston" core-version=">=5.0.0" dependents="" description="TiddlyWeb and TiddlySpace components" list="readme" plugin-type="plugin" title="$:/plugins/tiddlywiki/tiddlyweb" type="application/json" version="5.1.17" revision="0" bag="default">
...
For the tiddlywiki readme, I get the suggestion that the "rendertiddlers" command I used, renders server side components, which is different to creating an offline copy. See https://github.com/Jermolene/TiddlyWiki5
I think I've got it. Look at the tiddlywiki.info from a clean install:
"build": {
"index": [
"--rendertiddler",
"$:/plugins/tiddlywiki/tiddlyweb/save/offline",
"index.html",
"text/plain"
],
Our build command should be
tiddlywiki . --rendertiddler $:/plugins/tiddlywiki/tiddlyweb/save/offline index.html text/plain
I'll run an experiment on master to verify this.
🎉 🚀 fixed it with 64cdf6fbec07686bdaab5d77523de55110d98856
Ain't no stopping us now @jamesgorman2 !
Great detective work @serra
I'll have a look in the morning
@jamesgorman2 I'm closing this issue as I think it is sufficiently resolved by #8. Please reopen if you disagree.
CI Pipe - set up with #2.
I suggest we use a simple makefile, inspired by Scripts to rule them all
(untested)