mirror of
https://expo.survex.com/repositories/expoweb/.git/
synced 2024-11-22 07:11:55 +00:00
enlarging future troggle notes
This commit is contained in:
parent
e8d654ff94
commit
032dc2210c
@ -2,7 +2,7 @@
|
||||
<html>
|
||||
<head>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
|
||||
<link rel="stylesheet" type="text/css" href="css/main2.css" />
|
||||
<link rel="stylesheet" type="text/css" href="../../css/main2.css" />
|
||||
<title>CUCC's Austria expeditions: Recent changes</title>
|
||||
</head>
|
||||
<body>
|
@ -82,41 +82,6 @@ Most people will not want to read this at all. This is for speleosoftwarearcheol
|
||||
|
||||
<p>Two page preliminary design document for <a href="../../documents/caca_arch2.pdf">'caca' (Cave Catalogue) rev.2 2013-07-26</a> by Wookey (copied from http://wookware.org/software/cavearchive/caca_arch2.pdf)
|
||||
|
||||
<h3>stroggle</h3>
|
||||
<p>At one time Martin Green attempted to reimplement troggle as "stroggle" using <a href="https://www.fullstackpython.com/flask.html">flask</a> instead of Django at
|
||||
<a href="https://en.wikipedia.org/wiki/Gitorious">git@gitorious.org:stroggle/stroggle.git</a> (but gitorious has been deleted).</p>
|
||||
<p>A copy of this project is archived by Wookey on <a href="http://wookware.org/software/cavearchive/stroggle/">wookware.org/software/cavearchive/stroggle/</a>.
|
||||
<p>There is also a copy of stroggle on the backed-up, read-only copy of gitorious on "<a href="https://gitorious.org/">gitorious valhalla</a>"<br />
|
||||
<a href="https://gitorious.org/stroggle/stroggle.git/">stroggle code</a></br>
|
||||
<a href="https://gitorious.org/stroggle/stroggle-gitorious-wiki.git/">stroggle-gitorious-wiki</a></br>
|
||||
but note that this domain has an expired ertificate so https:// complains.
|
||||
|
||||
<h3 id="automation">Automation on expo.survex.com</h3>
|
||||
|
||||
<p>Ths section is entirely out of date (June 2014), and moved here for historic interest</p>.
|
||||
|
||||
<p>The way things normally work, python or perl scripts turn CSV input into HTML for the data management system. Note that:</p>
|
||||
<p>The CSV files are actually tab-separated, not comma-separated despite the extension.</p>
|
||||
<p>The scripts can be very picky and editing the CSVs with microsoft excel has broken them in the past- not sure if this is still the case.</p>
|
||||
<p>Overview of the automagical scripts on the expo data management system</p>
|
||||
[Clearly very out of date is it is assuming the version control is svn whereas we changed to mercurial years ago.]
|
||||
<pre>
|
||||
Script location Input file Output file Purpose
|
||||
/svn/trunk/expoweb/noinfo/make-indxal4.pl /svn/trunk/expoweb/noinfo/CAVETAB2.CSV many produces all cave description pages
|
||||
/svn/trunk/expoweb/scripts/make-folklist.py /svn/trunk/expoweb/folk/folk.csv http://expo.survex.com/folk/index.htm Table of all expo members
|
||||
|
||||
/svn/trunk/surveys/tablize-csv.pl /svn/trunk/surveys/tablizebyname-csv.pl
|
||||
/svn/trunk/surveys/Surveys.csv
|
||||
|
||||
http://expo.survex.com/expo/surveys/surveytable.html http://expo.survex.com/surveys/surtabnam.html
|
||||
Survey status page: "wall of shame" to keep track of who still needs to draw which surveys
|
||||
|
||||
</pre>
|
||||
|
||||
<h3><a id="arch">Archived updates</a></h3>
|
||||
<p>Since 2008 we have been keeping detailed records of all data management system updates in the version control system.
|
||||
Before then we manually maintained <a href="../update.htm">a list of updates</a> which are now only of historical interest.
|
||||
<p>A history of the expo website and software was published in Cambridge Underground 1996. A copy of this article <a href="c21bs.html">Taking Expo Bullshit into the 21st Century</a> is archived here.
|
||||
|
||||
<h2>The data management system conventions bit</h2>
|
||||
<p>This is likely to change with structural change to the site, with style changes which we expect to implement and with the method by which the info is actually stored and served up.</p>
|
||||
@ -387,72 +352,141 @@ Storage:
|
||||
|
||||
<hr />
|
||||
|
||||
<h3 Radost's proposal</h3>
|
||||
|
||||
<h3> Radost's proposal</h3>
|
||||
<div style="font-family: monospace; font-size: large">
|
||||
<p>Radost Waszkiewicz (CUCC member 2016-2019) proposed a plan for superceding troggle</p>
|
||||
|
||||
<pre>
|
||||
Hey,
|
||||
<p>
|
||||
Hey,<br>
|
||||
|
||||
on the design sesh we've looked a bit on the way data is organised in the
|
||||
loser repo and how to access it via troggle.
|
||||
|
||||
<p>
|
||||
A proposal arised that all this database shannaingans is essentially
|
||||
unnecessary - we have about 200 caves, about 250 entrances, about 200
|
||||
people and couple dozen expos. We don't need efficient lookups at all. We
|
||||
can write something which will be 'slow' and make only things we actually
|
||||
care about. Similarly I see little gain from doing the html - python himera
|
||||
care about.
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[What Rad has misunderstood here is that the database is not for speed. We use it mostly so that we can manage 'referential integrity' i.e. have all the different bits of information match up correctly. While the total size of the data is small, the interrelationships and complexity is quite large. From the justification for troggle: <p>"A less obvious but more deeply rooted problem was the lack of relational information. One table named folk.csv stored
|
||||
names of all expedition members, the years in which they were present, and a link to a biography page. This was great
|
||||
for displaying a table of members by expedition year, but what if you wanted to display a list of people who wrote in the
|
||||
logbook about a certain cave in a certain expedition year? Theoretically, all of the necessary information to produce that
|
||||
list has been recorded in the logbook, but there is no way to access it because there is no connection between the
|
||||
person's name in folk.csv and the entries he wrote in the logbook".
|
||||
<p>And for ensuring survey data does not get lost we need to coordinate people, trips, survex blocks,
|
||||
survex files, drawing files (several formats), QMs, wallet-progress pages, rigging guides, entrance photos, GPS tracks, kataster boundaries, scans of sketches, scans of underground notes, and dates for all those - Philip Sargent]
|
||||
</em>
|
||||
</div>
|
||||
|
||||
<p>Similarly I see little gain from doing the html - python himera
|
||||
template pages. These contain mainly nested for loops which could just as
|
||||
well be written in e.g. python.
|
||||
|
||||
I'd advocate following solution:
|
||||
- give up on fixing things in troggle
|
||||
- have a small number of .py scripts which generate static webpages with
|
||||
content we want
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[He could indeed. But for most people producing HTML while writing in python is just unnecessarily difficult.]
|
||||
</em>
|
||||
</div>
|
||||
|
||||
I'd advocate following solution:
|
||||
<ul>
|
||||
<li> give up on fixing things in troggle
|
||||
<li> have a small number of .py scripts which generate static webpages with
|
||||
content we want
|
||||
</ul>
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[A reasonable proposal, but needs quantifying with all the things troggle does
|
||||
which Rad was unaware of. This will not be a "small" number but it needs estimating. We don't need
|
||||
everything troggle does for us of course, but that doesn't mean that removing django/troggle
|
||||
will reduce the total amount of code. The input data parsers will be nearly the same size obviously.]
|
||||
</em>
|
||||
</div>
|
||||
Why do this:
|
||||
- we don't have multiple intermediate layers all of which are difficult to
|
||||
<ul>
|
||||
<li> we don't have multiple intermediate layers all of which are difficult to
|
||||
maintain
|
||||
- anyone can run this on their machine without need for local vm's
|
||||
- to change something there is one thing you change - script that generates
|
||||
<li> anyone can run this on their machine without need for local vm's
|
||||
<li> to change something there is one thing you change - script that generates
|
||||
pages belonging to particular pattern. currently you need to take care of
|
||||
parsers, view script, url script, and template
|
||||
- it runs offline (just like that as pages are just blocks of literal text
|
||||
<li> it runs offline (just like that as pages are just blocks of literal text
|
||||
+ some javascript)
|
||||
- we never end up with no working copy during expo - run scripts once
|
||||
<li> we never end up with no working copy during expo - run scripts once
|
||||
before expedition and put results in /backup and just leave it there till
|
||||
next year. Something goes wrong on the daily updated version - we have a
|
||||
very easy fallback
|
||||
- just one (or very close to it) programming language
|
||||
- change to python3 to parse silly chars
|
||||
- wayyyy fewer lines of code and substantially better code to comment ratio
|
||||
<li> just one (or very close to it) programming language
|
||||
<li> change to python3 to parse silly chars
|
||||
<li> wayyyy fewer lines of code and substantially better code to comment ratio
|
||||
(if this is us writing this now)
|
||||
- compatible with all the already existing static pages
|
||||
- we can host this on a potato hosting as we're not running anything fancy
|
||||
<li> compatible with all the already existing static pages
|
||||
<li> we can host this on a potato hosting as we're not running anything fancy
|
||||
anymore
|
||||
- get's rid of the horrifying url rewrites that correspond to no files that
|
||||
<li> get's rid of the horrifying url rewrites that correspond to no files that
|
||||
exist
|
||||
|
||||
</ul>
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[This vastly underestimates the number of things that troggle does for us. See "<a href="/expofiles/documents/troggle/troggle_paper.pdf" download>Troggle: a novel system for cave exploration information management</a>". And a VM is not required to run and debug troggle.
|
||||
Sam has produced a docker variant which he uses extensively.
|
||||
<p>Troggle today has 8,200 lines of python (including comments and blank lines), plus 600 in imagekit and 200 in flatpages. 2,200 of those are in the parsers. Django itself has a lot more, including integration with TinyMCE in-browser HTML editor. </em>]
|
||||
</div>
|
||||
How much work would this actually take:
|
||||
- most likely one script per page type, so far page types that are
|
||||
<ul>
|
||||
<li> most likely one script per page type, so far page types that are
|
||||
obviously needed:
|
||||
--cave index
|
||||
--individual cave descriptions
|
||||
--logbooks
|
||||
- more than half of the parsers are already rewriten by me and can be
|
||||
<ul>
|
||||
<li>cave index
|
||||
<li>individual cave descriptions
|
||||
<li>logbooks
|
||||
</ul>
|
||||
<li> more than half of the parsers are already rewriten by me and can be
|
||||
changed to do this instead of modifying SQL database with minimal effort
|
||||
- html/css side of things already exists, but it would be nice to go for a
|
||||
<li> html/css side of things already exists, but it would be nice to go for a
|
||||
more modern look there as well
|
||||
|
||||
Things this solution doesn't solve:
|
||||
- no webpage-based 'wizzard' for creating caves and such (did people use it
|
||||
</ul>
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[The effort estimate is similarly a gross underestimate because (a) he assumes one script per page of output, forgetting all the core work to create a central consistent dataset, and (b) he is missing out most
|
||||
of the functionality we use without realizing it because it is built into
|
||||
django's SQL system, such as multi-user operations.
|
||||
<p><span style="color:red">Eventually we will have to migrate from django of course</span>, as it will eventually
|
||||
fail to keep up with the rest of the world. Right now we need to get ourselves onto python3
|
||||
so that we can use an LTS release which has current security updates. This is
|
||||
<a href="https://docs.djangoproject.com/en/3.0/internals/release-process/#supported-versions-policy">more urgent for django</a> than for Linux. In Ubuntu terms we are on 18.04 LTS (Debian 10) which has no free maintenance updates from 2023. <span style="color:red">We should plan to migrate troggle from django to another framework in about 2025. See stroggle below.</span>]
|
||||
</em>
|
||||
</div>
|
||||
Things this [Rad's] solution doesn't solve:
|
||||
<ul>
|
||||
<li> no webpage-based 'wizzard' for creating caves and such (did people use it
|
||||
much? do we care?) -> maybe 'send an email to this address' is the ultimate
|
||||
solution to this
|
||||
- uploading photos is still difficult (in the sense that they don't get
|
||||
<li> uploading photos is still difficult (in the sense that they don't get
|
||||
minified automatically)
|
||||
|
||||
</ul>
|
||||
Rad
|
||||
<div style="margin-left: 4em; margin-right:4em; font-family: sanserif"><em>
|
||||
[Creating a cave description for a new cave, and especially linking in images,
|
||||
is currently so difficult that only a couple of people can do it. Fixing this is
|
||||
a matter of urgency. No one should have to imagine where the path to a file will be but isn't now.
|
||||
We need a file uploading system to put things in the right place; and this would help photos too.]
|
||||
</em>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
<h3>stroggle</h3>
|
||||
<p>At one time Martin Green attempted to reimplement troggle as "stroggle" using <a href="https://www.fullstackpython.com/flask.html">flask</a> instead of Django at
|
||||
<a href="https://en.wikipedia.org/wiki/Gitorious">git@gitorious.org:stroggle/stroggle.git</a> (but gitorious has been deleted).</p>
|
||||
<p>A copy of this project is archived by Wookey on <a href="http://wookware.org/software/cavearchive/stroggle/">wookware.org/software/cavearchive/stroggle/</a>.
|
||||
<p>There is also a copy of stroggle on the backed-up, read-only copy of gitorious on "<a href="https://gitorious.org/">gitorious valhalla</a>"<br />
|
||||
<a href="https://gitorious.org/stroggle/stroggle.git/">stroggle code</a></br>
|
||||
<a href="https://gitorious.org/stroggle/stroggle-gitorious-wiki.git/">stroggle-gitorious-wiki</a></br>
|
||||
but note that this domain has an expired certificate so https:// complains.
|
||||
<p>The schema for stroggle is <a href="http://wookware.org/software/cavearchive/stroggle/git/exampledata/expo/schema.json">a schema.json file</a>. See the comparable <a href="datamodel.html">troggle schema file</a> which is indeed horrendously bigger.
|
||||
|
||||
|
||||
<h3><a id="arch">Archived updates</a></h3>
|
||||
<p>Since 2008 we have been keeping detailed records of all data management system updates in the version control system.
|
||||
Before then we manually maintained <a href="../computing/update.html">a list of updates</a> which are now only of historical interest.
|
||||
<p>A history of the expo website and software was published in Cambridge Underground 1996. A copy of this article <a href="c21bs.html">Taking Expo Bullshit into the 21st Century</a> is archived here.
|
||||
|
||||
</pre>
|
||||
</body>
|
||||
</html>
|
||||
|
Loading…
Reference in New Issue
Block a user