diff --git a/.github/workflows/update-data.yml b/.github/workflows/update-data.yml index dfc8006ec..03c59ce9a 100644 --- a/.github/workflows/update-data.yml +++ b/.github/workflows/update-data.yml @@ -28,7 +28,7 @@ jobs: - name: Update Data run: | - python ./etl/2021.py + python ./etl/2022.py git config user.name "opendataday[bot]" git config user.email "actions@users.noreply.github.com" git add -A diff --git a/Datasets/Events 2022.csv b/Datasets/Events 2022.csv new file mode 100644 index 000000000..dd6875776 --- /dev/null +++ b/Datasets/Events 2022.csv @@ -0,0 +1,2 @@ +event_date,event_name,event_photo_url,event_purpose,event_report_url,event_tweet_url,event_video_url,has_event_report,latitude,longitude,num_participants,online_event_url,organisers,place,slug,url,world_region_code,world_region_text +,Test event name,,To open some test data,,,,False,33.12223443,-61.234455,24,,Test organizer,"Cordoba, Argentina",test-event-name,https://data99.com.ar,, diff --git a/README.md b/README.md index d2e35e229..cb9c85a7b 100644 --- a/README.md +++ b/README.md @@ -73,25 +73,28 @@ These will need to be resolved by editing the input spreadsheet. There are three bits of setup we need to do each year: + - **1. Create a new import job:** - Create `./etl/202x.py` based on a previous year's file - - Fill in `IN_URL` and `THIS_YEAR` + - Fill in `SPREADSHEET_ID`, `SHEET_ID` and `THIS_YEAR` - Update schema as applicable if the spreadsheet has changed, but we want to keep the JSON output the same if possible as every year's events page uses the same template to render the JSON to HTML - - Replace https://github.com/okfn/opendataday/blob/d51d490fe15c9b02e33f0e8460cadadb636f83f6/.github/workflows/update-data.yml#L31 with the new job. We don't need to keep running last year's script. + - Replace the [GitHub workflow update-data.yml](/.github/workflows/update-data.yml) with the new job tu run `python ./etl/202X.py`. We don't need to keep running last year's script. - Once we've run the job for the first time it will create a `/databags/202x.json` file. This is consumed by the events list page and the events map - We can run `python ./etl/202x.py` locally as well as triggering it with GitHub actions - **2. Update the map:** - - Update https://github.com/okfn/opendataday/blob/d51d490fe15c9b02e33f0e8460cadadb636f83f6/assets/js/map.js#L1 to consume the new JSON file + - Update [map.js file](/assets/js/map.js) to consume the new JSON file - **3. Create a new events page:** - Create `./content/events/202x/contents.lr` based on a previous year's file - Fill in the fields - Create a stub `./content/events/202x/contents..lr` for each supported alternate language - It is not necessary to manually create the `./content/events/202x/reports` dir or edit any content under it. This will be automatically generated by the import job. - Add the new 202x events page to the menu: - - Add `/events/202x` to the list of events pages. - - Update the 'Search events' link to the current year + - Add `/events/202x` to the list of events pages ([main-nav.json](/databags/main-nav.json)). + - Update the 'Search events' link to the current year ([main-nav.json](/databags/main-nav.json)). - Repeat for each supported alternate language +For reference, you can check the [PR for the 2022 update](https://github.com/okfn/opendataday/pull/345) + ## Previous version The previous version of the site has been moved to the [v1](https://github.com/okfn/opendataday/tree/v1) branch. diff --git a/assets/icons/okfn.svg b/assets/icons/okfn.svg new file mode 100644 index 000000000..a56664eec --- /dev/null +++ b/assets/icons/okfn.svg @@ -0,0 +1,109 @@ + + + + + + image/svg+xml + + Open Knowledge Foundation + + + + + Open Knowledge Foundation + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/assets/js/map.js b/assets/js/map.js index 67eea9f53..e096ef500 100644 --- a/assets/js/map.js +++ b/assets/js/map.js @@ -1,4 +1,4 @@ -var url = 'https://raw.githubusercontent.com/okfn/opendataday/master/databags/events-2021.json'; +var url = 'https://raw.githubusercontent.com/okfn/opendataday/master/databags/events-2022.json'; mapboxgl.accessToken = 'pk.eyJ1Ijoib2tmbiIsImEiOiJjaXlrOW5yczgwMDEzMnlwaWd2ZzF6MDQ3In0.2UJlkR69zbu4-3YRJJgN5w'; var clusterRadius = 50, diff --git a/content/contents.lr b/content/contents.lr index 58cb1e7f6..e34ffcdb1 100644 --- a/content/contents.lr +++ b/content/contents.lr @@ -40,7 +40,7 @@ year_label_5: Ocean **data** for a thriving planet --- register_text: Register your event --- -events_registered: events registered in 2021 +events_registered: events registered in 2022 --- who_heading: Who is this for? Everyone! --- @@ -152,8 +152,7 @@ support_scheme_heading: Support Scheme --- support_scheme_body: -The 2021 mini-grant scheme has now closed. Read our blogpost to find out more about the organisations receiving mini-grants this year - +IMPORTANT: There will be a different grant scheme this year for Open Data Day. We will not support online events happening on March 5th, 2022. Instead, we will be opening a call for grants to celebrate face to face meetings, when local conditions permit, to have months of action around Open Data. More information will be published shortly. --- support_scheme_button: Read more --- diff --git a/content/events/2022/contents+de.lr b/content/events/2022/contents+de.lr new file mode 100644 index 000000000..bd036cd9b --- /dev/null +++ b/content/events/2022/contents+de.lr @@ -0,0 +1,9 @@ +language: de +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+es_es.lr b/content/events/2022/contents+es_es.lr new file mode 100644 index 000000000..e6c627a1a --- /dev/null +++ b/content/events/2022/contents+es_es.lr @@ -0,0 +1,9 @@ +language: es_es +--- + + + +title: Events de 2002 +--- +banner_heading_2: Eventos de 2022 +--- diff --git a/content/events/2022/contents+fr.lr b/content/events/2022/contents+fr.lr new file mode 100644 index 000000000..6d11ec9cf --- /dev/null +++ b/content/events/2022/contents+fr.lr @@ -0,0 +1,9 @@ +language: fr +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+it.lr b/content/events/2022/contents+it.lr new file mode 100644 index 000000000..4ecc1e321 --- /dev/null +++ b/content/events/2022/contents+it.lr @@ -0,0 +1,9 @@ +language: it +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+ja.lr b/content/events/2022/contents+ja.lr new file mode 100644 index 000000000..36a9737f4 --- /dev/null +++ b/content/events/2022/contents+ja.lr @@ -0,0 +1,9 @@ +language: ja +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+kr.lr b/content/events/2022/contents+kr.lr new file mode 100644 index 000000000..184cc879f --- /dev/null +++ b/content/events/2022/contents+kr.lr @@ -0,0 +1,9 @@ +language: kr +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+ne.lr b/content/events/2022/contents+ne.lr new file mode 100644 index 000000000..f3def3693 --- /dev/null +++ b/content/events/2022/contents+ne.lr @@ -0,0 +1,9 @@ +language: ne +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+nl.lr b/content/events/2022/contents+nl.lr new file mode 100644 index 000000000..0a9092293 --- /dev/null +++ b/content/events/2022/contents+nl.lr @@ -0,0 +1,9 @@ +language: nl +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+pt_br.lr b/content/events/2022/contents+pt_br.lr new file mode 100644 index 000000000..92cd5d64a --- /dev/null +++ b/content/events/2022/contents+pt_br.lr @@ -0,0 +1,9 @@ +language: pt_br +--- + + + +title: Eventos de 2022 +--- +banner_heading_2: Eventos de 2022 +--- diff --git a/content/events/2022/contents+ru.lr b/content/events/2022/contents+ru.lr new file mode 100644 index 000000000..6c22a4fea --- /dev/null +++ b/content/events/2022/contents+ru.lr @@ -0,0 +1,9 @@ +language: ru +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+th.lr b/content/events/2022/contents+th.lr new file mode 100644 index 000000000..3e27b2625 --- /dev/null +++ b/content/events/2022/contents+th.lr @@ -0,0 +1,9 @@ +language: th +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+zh_hans.lr b/content/events/2022/contents+zh_hans.lr new file mode 100644 index 000000000..bb3b8753f --- /dev/null +++ b/content/events/2022/contents+zh_hans.lr @@ -0,0 +1,9 @@ +language: zh_hans +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents+zh_tw.lr b/content/events/2022/contents+zh_tw.lr new file mode 100644 index 000000000..27f8b9c8c --- /dev/null +++ b/content/events/2022/contents+zh_tw.lr @@ -0,0 +1,9 @@ +language: zh_tw +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/content/events/2022/contents.lr b/content/events/2022/contents.lr new file mode 100644 index 000000000..9545b87f4 --- /dev/null +++ b/content/events/2022/contents.lr @@ -0,0 +1,17 @@ +_model: events_list +--- +_template: events_list.html +--- +data_file: events-2022 +--- +banner_link: main +--- +csv_link: https://raw.githubusercontent.com/okfn/opendataday/master/Datasets/Events%202022.csv +--- + + + +title: 2022 Events +--- +banner_heading_2: 2022 Events +--- diff --git a/databags/events-2022.json b/databags/events-2022.json new file mode 100644 index 000000000..56d8579e3 --- /dev/null +++ b/databags/events-2022.json @@ -0,0 +1,24 @@ +{ + "events": [ + { + "event_date": null, + "event_name": "Test event name", + "event_photo_url": "", + "event_purpose": "To open some test data", + "event_report_url": "", + "event_tweet_url": "", + "event_video_url": "", + "has_event_report": false, + "latitude": 33.12223443, + "longitude": -61.234455, + "num_participants": "24", + "online_event_url": "", + "organisers": "Test organizer", + "place": "Cordoba, Argentina", + "slug": "test-event-name", + "url": "https://data99.com.ar", + "world_region_code": "", + "world_region_text": "" + } + ] +} \ No newline at end of file diff --git a/databags/global-content.ini b/databags/global-content.ini index 507c829bb..98191d38c 100644 --- a/databags/global-content.ini +++ b/databags/global-content.ini @@ -4,7 +4,7 @@ banner_content_1 = Open Data Day 2022 will take place on banner_content_2 = Saturday 5th March menu_label = Menu footer = This is a bottom-up initiative. Like in previous years, the Open Knowledge Foundation helps maintain this website and works with mini-grant supporters to foster a community. Everyone can contribute. You can contact the [mailing list](https://groups.google.com/forum/#!forum/open-data-day) or go to the [GitHub repo](https://github.com/okfn/opendataday) | [Privacy Policy](https://okfn.org/privacy-policy/) -support_scheme_logos = The Open Data Day 2021 mini-grants scheme was kindly supported by: +support_scheme_logos = The Open Data Day 2022 mini-grants scheme was kindly supported by: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -16,7 +16,7 @@ banner_content_1 = Open Data Day findet statt am banner_content_2 = Samstag, 5. März 2022 menu_label = Menü footer = Das ist eine echte Graswurzelbewegung, die von Freiwilligen koordniert wird. In diesem Jahr hat [Open Knowledge Foundation](http://okfn.org/) ein neues Layout für den Open Data Day beigesteuert und die Vergabe von Mini-Grants mit [SPARC](http://sparcopen.org/) und [HIVOS](http://hivos.org/) koordinidert. Jeder kann den Open Data Day mitgestalten - über die [internationale Mailingliste](https://groups.google.com/forum/#!forum/open-data-day) oder das [GitHub repo](https://github.com/okfn/opendataday) | [Privacy Policy](https://okfn.org/privacy-policy/) -support_scheme_logos = The Open Data Day 2021 mini-grants scheme is kindly supported by: +support_scheme_logos = The Open Data Day 2022 mini-grants scheme is kindly supported by: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -28,7 +28,7 @@ banner_content_1 = El Día de los Datos Abiertos se llevará a cabo el banner_content_2 = Sábado, 5 de marzo de 2022 menu_label = Menú footer = Esta es una iniciativa de abajo arriba coordinada en esta [lista de correo](https://groups.google.com/forum/#!forum/open-data-day). Como todos los años, [Open Knowledge Foundation](http://okfn.org/) ha ayudado en la creación del sitio del Día de los Datos Abiertos y ha ofrecido mini becas junto con [SPARC](http://sparcopen.org/) e [HIVOS](http://hivos.org/) para fomentar la realización de más eventos en todo el mundo. Cualquiera puede contribuir, ya sea usando la lista de correo o bien a través del [repositorio de Github](https://github.com/okfn/opendataday). -support_scheme_logos = Las mini-subvenciones del Open Data Day 2021 son gracias a: +support_scheme_logos = Las mini-subvenciones del Open Data Day 2022 son gracias a: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -40,7 +40,7 @@ banner_content_1 = La Journée des Données Ouvertes 2022 a lieu le banner_content_2 = Samedi 5 Mars menu_label = Menu footer = Il s'agit d'une initiative ascendante. Comme les années précédentes, l'Open Knowledge Foundation contribue à la maintenance de ce site web et travaille avec les sponsors de mini-subventions pour développer une communauté. Tout le monde peut contribuer. Vous pouvez contacter la [liste de diffusion](https://groups.google.com/forum/#!forum/open-data-day) ou vous rendre sur le [dépot GitHub](https://github.com/okfn/opendataday) | [Politique de confidentialité](https://okfn.org/privacy-policy/) -support_scheme_logos = Le programme de mini-subventions Open Data Day 2021 est soutenu par : +support_scheme_logos = Le programme de mini-subventions Open Data Day 2022 est soutenu par : licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -52,7 +52,7 @@ banner_content_1 = L'Open Data Day si terrà banner_content_2 = Sabato 5 marzo 2022 menu_label = Menu footer = L'Open Data Day è una vera iniziativa dal basso coordinata su [questa mailing list](https://groups.google.com/forum/#!forum/open-data-day). Quest'anno [Open Knowledge Foundation](http://okfn.org/) ha contribuito alla creazione del sito Web e offre delle mini-sovvenzioni insieme a [SPARC](http://sparcopen.org/) e [HIVOS](http://hivos.org/) per sostenere l'organizzazione di eventi. Chiunque può contribuire all'Open Data Day sia tramite la mailing list che sul [repository GitHub](https://github.com/okfn/opendataday) | [Privacy Policy](https://okfn.org/privacy-policy/) -support_scheme_logos = The Open Data Day 2021 mini-grants scheme is kindly supported by: +support_scheme_logos = The Open Data Day 2022 mini-grants scheme is kindly supported by: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -76,7 +76,7 @@ banner_content_1 = 2022년 오픈 데이터 데이가 열립니다. banner_content_2 = 2022년 3월 5일 토요일 menu_label = 메뉴 footer = 이 조직은 아래로부터 시작된 조직입니다. 지난 연도들과 마찬가지로, Open Knowledge Foundation은 이 웹사이트를 유지하는 것을 돕고, 커뮤니티를 육성하기 위한 작은 지원금으로 지원자들을 돕습니다. 누구든 기여할 수 있습니다. 당신은 [이메일 리스트](https://groups.google.com/forum/#!forum/open-data-day)로 연락하거나 [깃헙 레포지토리](https://github.com/okfn/opendataday)로 방문할 수 있습니다. | [개인정보 정책](https://okfn.org/privacy-policy/) -support_scheme_logos = 2021년 오픈 데이터 데이 보조금 계획은 아래 조직들로부터 지원되고 있습니다.: +support_scheme_logos = 2022년 오픈 데이터 데이 보조금 계획은 아래 조직들로부터 지원되고 있습니다.: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -112,7 +112,7 @@ banner_content_1 = O Dia dos Dados Abertos 2022 será no banner_content_2 = Sábado, 5 de março menu_label = Menu footer = Esta é uma iniciativa de raiz. Como nos anos anteriores, a Open Knowledge Foundation ajuda a manter este website e trabalha com os apoiadores de minibolsas para fomentar uma comunidade. Todos podem contribuir. Você pode contactar a [lista de e-mails](https://groups.google.com/forum/#!forum/open-data-day), [fórum Discuss](https://discuss.okfn.org/c/network-and-community/open-data-day/93), [grupo no Telegram](https://t.me/opendatadaybrazil) ou ir para o [repositório no GitHub](https://github.com/okfn/opendataday) | [Política de Privacidade](https://okfn.org/privacy-policy/) -support_scheme_logos = As minibolsas do Dia dos Dados Abertos 2021 foram gentilmente sustentadas por: +support_scheme_logos = As minibolsas do Dia dos Dados Abertos 2022 foram gentilmente sustentadas por: licences = Informações de Licença code_licence = O código e o texto do site do Dia dos Dadoa Abertos são disponibilizados sob a [licença CC0 1.0](https://creativecommons.org/publicdomain/zero/1.0/deed.pt_BR) data_licence = Os arquivos de dados estão disponibilizados sob a [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -136,7 +136,7 @@ banner_content_1 = Open Data Day 2022 จะมีขึ้นใน banner_content_2 = วันเสาร์ที่ 5 มีนาคม menu_label = เมนู footer = นี่เป็นความริเริ่มที่สร้างขึ้นมาจากฐานโดยแท้จริง ปีนี้มูลนิธิ [Open Knowledge Foundation](http://okfn.org/) ได้ช่วยสร้างเว็บไซต์ Open Data Day และร่วมกับ [SPARC](http://sparcopen.org/) และ [HIVOS](http://hivos.org/) มอบทุนขนาดเล็กเพื่อสนับสนุนการจัดกิจกรรม ทุกคนสามารถลงแรงช่วยวันข้อมูลเปิดได้ผ่าน[อีเมลกลุ่ม](https://groups.google.com/forum/#!forum/open-data-day) หรือ [GitHub](https://github.com/okfn/opendataday) | [นโยบายความเป็นส่วนตัว](https://okfn.org/privacy-policy/) -support_scheme_logos = โครงการทุนขนาดเล็ก Open Data Day 2021 สนับสนุนโดย: +support_scheme_logos = โครงการทุนขนาดเล็ก Open Data Day 2022 สนับสนุนโดย: licences = ข้อมูลสัญญาอนุญาต code_licence = โค้ดและข้อความของเว็บไซต์ Open Data Day เผยแพร่ภายใต้สัญญาอนุญาต [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = แฟ้มข้อมูลกิจกรรมเผยแพร่ภายใต้สัญญาอนุญาต [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -148,7 +148,7 @@ banner_content_1 = 2022 开放数据日将举办于 banner_content_2 = 3 月 5 日周六 menu_label = 菜单 footer = footer = This is a bottom-up initiative. Like in previous years, the Open Knowledge Foundation helps maintain this website and works with mini-grant supporters to foster a community. Everyone can contribute. You can contact the [mailing list](https://groups.google.com/forum/#!forum/open-data-day)or go to the [GitHub repo](https://github.com/okfn/opendataday) | [Privacy Policy](https://okfn.org/privacy-policy/) -support_scheme_logos = 2021 年开放数据日小额赠款计划得到以下机构的大力支持: +support_scheme_logos = 2022 年开放数据日小额赠款计划得到以下机构的大力支持: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -160,7 +160,7 @@ banner_content_1 = Open Data Day 2022 將在這一天 banner_content_2 = 3 月 5 日 星期六舉行 menu_label = 選單 footer = 這是草根發起的活動,使用[郵件論壇](https://groups.google.com/forum/#!forum/open-data-day)進行協調。今年,[Open Knowledge Foundation](http://okfn.org/) 建制了 Open Data Day 網站,並與 [SPARC](http://sparcopen.org/) 和 [HIVOS](http://hivos.org/) 合作提供獎助金協助舉辦活動。所有人都可以幫忙 Open Data Day 這個活動,請使用郵件論壇或 [GitHub ](https://github.com/okfn/opendataday) | [Privacy Policy](https://okfn.org/privacy-policy/) -support_scheme_logos = Open Data Day 2021 微型獎助由以下單位慷慨提供: +support_scheme_logos = Open Data Day 2022 微型獎助由以下單位慷慨提供: licences = Licence Information code_licence = The Open Data Day website code and text content are made available under the [CC0 1.0 licence](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Event Data files are made available under the [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) @@ -172,7 +172,7 @@ banner_content_1 = El Dia de les Dades Obertes 2022 tindrà lloc el banner_content_2 = Dissabte 5 de Març menu_label = Menú footer = Aquesta és una iniciative construïda des de baix. Com en els anys anteriors, la Open Knowledge Foundation ajuda a mantenir aquest lloc i treballa amb els contribuents al programa d'ajuts per impulsar una comunitat. Tothom hi pot contribuir . Podeu contactar la [llista de correu](https://groups.google.com/forum/#!forum/open-data-day) o visitar el [repostiori de GitHub](https://github.com/okfn/opendataday) | [Política de Privacitat](https://okfn.org/privacy-policy/) -support_scheme_logos = El programa d'ajuts del Dia de les Dades Obertes 2021 rep el generós suport de: +support_scheme_logos = El programa d'ajuts del Dia de les Dades Obertes 2022 rep el generós suport de: licences = Informació sobre llicències code_licence = El contingut i codi del llock web del Dia de les Dades Obertes són disponibles amb [llicència CC0 1.0](https://creativecommons.org/publicdomain/zero/1.0/) data_licence = Els arxius de dades sobre els events són disponibles amb llicència [Open Database License](https://opendatacommons.org/licenses/odbl/1.0/) diff --git a/databags/main-nav.json b/databags/main-nav.json index e9aa916d7..de2180a62 100644 --- a/databags/main-nav.json +++ b/databags/main-nav.json @@ -28,8 +28,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -76,8 +80,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -124,8 +132,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -172,8 +184,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -220,8 +236,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -268,8 +288,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -316,8 +340,12 @@ }, { "title": "이벤트 검색", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -364,8 +392,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -412,8 +444,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -460,8 +496,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -508,8 +548,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -556,8 +600,12 @@ }, { "title": "ค้นหากิจกรรม", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -604,8 +652,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -652,8 +704,12 @@ }, { "title": "Search events", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" @@ -699,8 +755,12 @@ }, { "title": "Cerca actes", - "link": "/events/2021/", + "link": "/events/2022/", "children": [ + { + "title": "2022", + "link": "/events/2022/" + }, { "title": "2021", "link": "/events/2021/" diff --git a/databags/mini-grant-funders.json b/databags/mini-grant-funders.json index 786175fad..c7918c447 100644 --- a/databags/mini-grant-funders.json +++ b/databags/mini-grant-funders.json @@ -5,5 +5,6 @@ "ILDA": "the [Latin American Open Data Initiative.](https://idatosabiertos.org/en/)", "Mapbox": "[Mapbox.](https://www.mapbox.com/)", "Microsoft": "[Microsoft.](https://www.microsoft.com/en-us/)", - "OCP": "the [Open Contracting Partnership.](https://www.open-contracting.org/)" -} + "OCP": "the [Open Contracting Partnership.](https://www.open-contracting.org/)", + "OKFN": "[OKFN](https://okfn.org/)" +} \ No newline at end of file diff --git a/etl/2022.py b/etl/2022.py new file mode 100644 index 000000000..37f75f6e3 --- /dev/null +++ b/etl/2022.py @@ -0,0 +1,22 @@ +from pathlib import Path +from lib import main + +# Google Spreadsheet main ID +SPREADSHEET_ID = '1VZ96Jn-JBhZ0C6ew89t3MPjiSMi6mcivlkz25AhDIDY' +# Intrernal sheet ID +SHEET_ID = '634064076' +IN_URL = f'https://docs.google.com/spreadsheets/d/{SPREADSHEET_ID}/export?format=csv&id={SPREADSHEET_ID}&gid={SHEET_ID}' +THIS_YEAR = 2022 +JSON_OUT_FILE = Path(__file__).absolute().parent.parent / 'databags' / f'events-{str(THIS_YEAR)}.json' +CSV_OUT_FILE = Path(__file__).absolute().parent.parent / 'Datasets' / f'Events {str(THIS_YEAR)}.csv' +REPORTS_DIR = Path(__file__).absolute().parent.parent / 'content' / 'events' / str(THIS_YEAR) / 'reports' +IMAGES_DIR = Path(__file__).absolute().parent.parent / 'assets' / 'images' / str(THIS_YEAR) + + +if __name__ == '__main__': + try: + main(IN_URL, THIS_YEAR, JSON_OUT_FILE, CSV_OUT_FILE, REPORTS_DIR, IMAGES_DIR) + except Exception as e: + print('❌') + print(str(e)) + raise e diff --git a/etl/lib.py b/etl/lib.py index f3748459b..2a32dc500 100644 --- a/etl/lib.py +++ b/etl/lib.py @@ -44,31 +44,31 @@ class Meta: validate=validate_not_empty ) num_participants = fields.Str(required=True, data_key="Number of participants") - organisers = fields.Str(required=True, data_key="Organisers") + organisers = fields.Str(required=True, data_key="Event organiser") event_purpose = fields.Str(required=True, data_key="Event purpose") event_date = fields.DateTime( required=False, missing=None, data_key="Date of event", format="%m/%d/%Y" # USA format ) - event_time = fields.Str(required=True, data_key="Time of event") # just a string - timezone = fields.Str(required=True, data_key="Timezone") - country = fields.Str(required=True, data_key="Country") - world_region_code = fields.Str(required=True, data_key="World region AMER/EMEA/APAC", + event_time = fields.Str(required=False, data_key="Time of event") # just a string + timezone = fields.Str(required=False, data_key="Timezone") + country = fields.Str(required=False, data_key="Country") + world_region_code = fields.Str(required=False, data_key="World region AMER/EMEA/APAC", validate=validate.OneOf(['AMER', 'EMEA', 'APAC', '']) ) - online = fields.Boolean(required=True, data_key="Online event?") - online_event_url = fields.Str(required=True, data_key="Online event URL") - event_report_url = fields.Str(required=True, data_key="Event report external URL") - event_photo_url = fields.Str(required=True, data_key="Event photo") - event_video_url = fields.Str(required=True, data_key="Event video URL") - event_tweet_url = fields.Str(required=True, data_key="Event tweet URL") - mini_grant_winner = fields.Boolean(required=True, data_key="Mini-grant winner?") - has_event_report = fields.Boolean(required=True, data_key="Has event report?") - report_question_1 = fields.Str(required=True, data_key="How did your event celebrate open data?") - report_question_2 = fields.Str(required=True, data_key="Lessons learned from your event") - report_question_3 = fields.Str(required=True, data_key="Why do you love Open Data Day?") - report_question_4 = fields.Str(required=True, data_key="Any resources produced during event which can be shared?") - mini_grant_funder = fields.Str(required=True, data_key="Name of mini-grant funder", + online = fields.Boolean(required=False, data_key="Online event?", default=False) + online_event_url = fields.Str(required=False, data_key="Online event URL") + event_report_url = fields.Str(required=False, data_key="Event report external URL") + event_photo_url = fields.Str(required=False, data_key="Event photo") + event_video_url = fields.Str(required=False, data_key="Event video URL") + event_tweet_url = fields.Str(required=False, data_key="Event tweet URL") + mini_grant_winner = fields.Boolean(required=False, data_key="Mini-grant winner?", default=False) + has_event_report = fields.Boolean(required=False, data_key="Has event report?", default=False) + report_question_1 = fields.Str(required=False, data_key="How did your event celebrate open data?") + report_question_2 = fields.Str(required=False, data_key="Lessons learned from your event") + report_question_3 = fields.Str(required=False, data_key="Why do you love Open Data Day?") + report_question_4 = fields.Str(required=False, data_key="Any resources produced during event which can be shared?") + mini_grant_funder = fields.Str(required=False, data_key="Name of mini-grant funder", validate=validate.OneOf(VALID_FUNDERS) ) @@ -84,10 +84,29 @@ def get_data(in_url): def pre_process(data): + """ Clean all data before started using it """ + + new_data = [] for row in data: - if row['Date of event'] == "": - row['Date of event'] = None - return data + new_row = { + # default values no longer in use in google form + 'Online event URL': '', + 'Event report external URL': '', + 'Event photo': '', + 'Event video URL': '', + 'Event tweet URL': '', + 'World region AMER/EMEA/APAC': '', + 'Has event report?': False, + } + # remove the (required) sufix + for k, v in row.items(): + if '(required)' in k: + new_row[k.replace(' (required)', '')] = v + else: + new_row[k] = v + new_data.append(new_row) + + return new_data def write_json(filename, data): diff --git a/templates/home.html b/templates/home.html index 7e4a160ba..fec36ef43 100644 --- a/templates/home.html +++ b/templates/home.html @@ -62,7 +62,7 @@

{% if this.mini_grants_title %}
- {{ this.register_text }} + {{ this.register_text }} 0 {{ this.events_registered }}
@@ -168,9 +168,11 @@

{{ this.resources_ideas_theme_6 }}

{{ this.support_scheme_heading }}

{{ this.support_scheme_body }}
+ diff --git a/templates/includes/logos.html b/templates/includes/logos.html index 2fee5b88f..387562737 100644 --- a/templates/includes/logos.html +++ b/templates/includes/logos.html @@ -13,33 +13,6 @@ -
  • - - - - - - - -
  • -
  • - - - - - - - -
  • -
  • - - - - - - - -
  • @@ -51,18 +24,9 @@
  • - - - - - - -
  • -
  • - - + - +