Skip to content

feat(talks): add 3D Earth globe for Djangonaut talks worldwide#640

Open
Mitchina wants to merge 8 commits intodevelopfrom
feature/3d-earth-talks-map
Open

feat(talks): add 3D Earth globe for Djangonaut talks worldwide#640
Mitchina wants to merge 8 commits intodevelopfrom
feature/3d-earth-talks-map

Conversation

@Mitchina
Copy link
Contributor

@Mitchina Mitchina commented Jan 5, 2026

This PR adds a 3D Earth Talks Map Feature.

A new page was added with a Three.js globe showcasing Djangonaut Space member presentations worldwide with geo-located purple spike markers and popups.

Features

  • 3D Earth Globe: Three.js with OrbitControls, auto-rotation, realistic texture (CC BY 4.0)
  • Geo Markers: Purple spikes + glowing orbs for on-site talks (online talks filtered out)
  • Popups: Title, event, year, speakers list, video links on click
  • Wagtail Admin: Leaflet geo-widget + address autocomplete + validation
  • Live Updates: GeoJSON API refreshes every 3s
  • Responsive

New Dependencies:

  • gdal==3.6.2
  • wagtailgeowidget>=9.1.0
  • djangorestframework-gis>=1.2.0
  • psycopg2-binary>=2.9.11

Stack Additions:

  • Backend: PostGIS, DRF + GeoJSON APIs
  • Frontend: Three.js, Leaflet.js

Documentation:

  • Added docs/post-map-changes.md - PostGIS setup for existing DBs
  • Updated README.md - Map setup instructions
  • Updated .claude/CLAUDE.md - Talks app structure

This PR also closes #625 (the playwright test issue)

@Mitchina Mitchina requested a review from tim-schilling January 5, 2026 22:43
@Mitchina Mitchina self-assigned this Jan 5, 2026
@Mitchina Mitchina added the enhancement New feature or request label Jan 5, 2026
@Mitchina Mitchina marked this pull request as draft January 5, 2026 23:35
@sentry
Copy link

sentry bot commented Jan 6, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.80%. Comparing base (e978baa) to head (0fbfe83).

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #640   +/-   ##
========================================
  Coverage    94.80%   94.80%           
========================================
  Files          162      162           
  Lines         7156     7156           
  Branches       238      238           
========================================
  Hits          6784     6784           
  Misses         331      331           
  Partials        41       41           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Mitchina
Copy link
Contributor Author

Mitchina commented Jan 6, 2026

This PR also fixes the playwright test issue reported here

@Mitchina Mitchina marked this pull request as ready for review January 7, 2026 00:23
Copy link
Member

@tim-schilling tim-schilling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for doing this @Mitchina! This is going to be great to have. I have a few pointers on how to structure the changes, but it largely seems solid. I do think we'll want to add some tests to the application for this. We'd want to confirm the API works as expected and that the page works. Since we don't have a JS testing utility, I've been using playwright to test those changes.

@Mitchina
Copy link
Contributor Author

Mitchina commented Jan 11, 2026

Hi @tim-schilling! Thanks so much for the detailed review and taking the time to go through this! Really appreciate it.

I've extracted the timezone fix into its own PR for quick merge 😊

For your other suggestions in the comments, I'm planning to address them this next weekend if I feel better, I got a cold and feeling a bit under the weather right now.

For Playwright tests, I can definitely give those a try, but others with more experience might be faster. Happy if someone else wants to jump in on that too!

Thanks again!

@Mitchina
Copy link
Contributor Author

Mitchina commented Jan 26, 2026

Hi @tim-schilling! Thanks again for the thorough review. I finally managed to find the time to address all your comments from the previous feedback (the PR has so many lines added because we've pulled the three module files asked here: #640 (comment) into the repo). I've also added all the tests, plus one Playwright test, please let me know what do you think!

Note: my building is failing again because of that Playwright test that checks the timezone (the one not related to the map changes), and the timezone in the CI is different again of the expected (locally I have every test passing):
Screenshot from 2026-01-26 01-17-50

@@ -0,0 +1,70 @@
# Post-Map Page Setup (For Existing DB Users)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm a bit confused by the purpose of this file. Can you help me understand it please?

Comment on lines +19 to +22
migrations.RunSQL(
"CREATE EXTENSION IF NOT EXISTS postgis;",
reverse_sql=migrations.RunSQL.noop, # Does nothing when rolled back
),
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This can be replaced with django.contrib.postgres.operations.CreateExtension if you'd like:

        CreateExtension("postgis"),

def get_popup_html(self, obj):
video_html = (
f"""
<a href="${obj.video_link}" target="_blank" aria-label="Watch talk recording">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
<a href="${obj.video_link}" target="_blank" aria-label="Watch talk recording">
<a href="{obj.video_link}" target="_blank" aria-label="Watch talk recording">

I think there's an errant character in this?

markers = globe_page.locator("#markerPopup")
# Markers will be present in the DOM but hidden
expect(markers).to_be_attached()
expect(markers).to_be_hidden()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is it possible to confirm that clicking on a marker causes the extra panel to appear?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll likely swap these out for their minified versions. If you want to do that, that's great, but I'm happy to do that as we get closer to merging.

Copy link
Member

@tim-schilling tim-schilling left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is coming along really nicely! I have a few more changes and suggestions.

@tim-schilling
Copy link
Member

Note: my building is failing again because of that Playwright test that checks the timezone (the one not related to the map changes), and the timezone in the CI is different again of the expected (locally I have every test passing):

I've merged a change which should help us diagnose that in the future. For now if you see an error with that timezone comparison, please ignore it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Fix flaky playwright test for timezone toggle

2 participants

Comments