Open Data Day is a gathering of citizens in cities around the world to write applications, liberate data, create visualizations and publish analyses using open public data to show support for and encourage the adoption of open data policies by the world's local, regional and national governments.
You're invited. Again. The next Open Data Day will take place on Saturday 5 March 2022.
Check http://opendataday.org for public website.
make install
make serve
grunt
will watch for changes to your SCSS files, and also icons (see svgstore).lektor deploy
will deploy to the gh-pages branch, putting changes live, if you have deploy permissions.To translate the site we need to duplicate the contents.lr file, and save with the language code in the file name, like contents+de.lr.
We also need to add translations to:
If we are adding new language to the site we also need to:
Requirements:
Setup:
requirements.in
file (to ejecute pip-compile
it's required to update requirements.txt
)pip install -r requirements.txt
nvm use 19
npm ci
lektor server
Events are populated using a very lightweight import script which:
git pull
)This is run in a github action with a workflow_dispatch trigger, which allows our content manager to maintain the events in a spreadsheet update the site via a button in github.
In general, the import process is designed to be lax about missing fields and unexpected values. Some minimal validation is performed on the fields we require for the site to build correctly. Any errors will fail the action and be displayed in the GitHub actions log. e.g:
marshmallow.exceptions.ValidationError: {'Latitude': ['Not a valid number.'], 'Longitude': ['Not a valid number.']}
These will need to be resolved by editing the input spreadsheet.
There are three bits of setup we need to do each year:
Before we start, we will need a Google Form and a Google Sheet to collect the event data.
This is the 2023 form: https://docs.google.com/forms/d/e/1FAIpQLSc5wiXeUur8GHMKmi1TQIMxwk107eMJVN6UVoibIfUwGZfc7A/viewform
The Google Sheet identificators must be added to the /etl/202x.py
file.
This script will attempt to read the data from the Google Sheet so you need to ensure this sheet is public.
./etl/202x.py
based on a previous year's fileSPREADSHEET_ID
, SHEET_ID
and THIS_YEAR
python ./etl/202X.py
. We don't need to keep running last year's script./databags/202x.json
file. This is consumed by the events list page and the events mappython ./etl/202x.py
locally as well as triggering it with GitHub actions./content/events/202x/contents.lr
based on a previous year's file./content/events/202x/contents.<lang>.lr
for each supported alternate language./content/events/202x/reports
dir or edit any content under it. This will be automatically generated by the import job./events/202x
to the list of events pages (main-nav.json).For reference, you can check the:
The previous version of the site has been moved to the v1 branch.