Skip to content

Add AequilibraE support (#1)#511

Merged
billyc merged 12 commits intosimwrapper:stagingfrom
outerl:master
Feb 23, 2026
Merged

Add AequilibraE support (#1)#511
billyc merged 12 commits intosimwrapper:stagingfrom
outerl:master

Conversation

@tomstephen
Copy link
Copy Markdown
Contributor

@tomstephen tomstephen commented Jan 16, 2026

This PR,

  • extends the HTTPFilesystem to support S3 buckets
  • adds a "SqliteMapComponent" plugin (generalised to support AequilibraE (and similar) projects)
  • adds a "AequilibraeMapComponent" plugin
  • extends the "Tile" panel to support hard-coded values, sqlite-database-queried values and other colours

Closes #507

I have documentation for the AequilibraE map panels and extension to Tile, am I right in assuming that should be a PR back to https://github.com/simwrapper/simwrapper.github.io ? Documentation PR open here

There is also a demo hosted at https://explore.outerloop.io/chicago/. Happy to look to setup a more permanent demo for the docs if that would help.

Some run-time errors and tidying left to do but mostly complete as is. Open to any and all feedback while I'm finishing this off!

* Initial commit, re-target npm deploy and change tagline

* Stop the deploy command trying (and failing) to set relative paths. Do it myself.

* misc splash page reformatting

* add aeq plugin, copied from xml viewer

* Add to plugin repo

* Flesh out reader.vue, add file system to extend http fs

* Clean up sqlite calls

* update templates, config access, add yaml parsing, etc

* Successfully reading tables from spatialite database

* remove comment

* Complete architecture for dashboards etc

* refine dashboard functionality

* Remote hosted demo

* hit s3 bucket files, not the aws console

* Extend file system to support S3

* Drop custom map component, use the existing one

* .

* Trim comments

* Refactor

* Add style by param

* Map centering and zoom

* Adds ability to join another (results) database

* many small fixes

* Revert irrelevant changes

* Dont track changes to package-lock.json, bloating PR

* Did that last one wrong

* Revert changes to scripts in package.json

* drop erroneous notes

* Refactor of styling

* stop tracking changes on package-lock.json

* .

* Scaling by meters/pixels options

* Main .vue refactor

* tweaks

* Add dataRange to colours

* Add ability to filter sql query from yaml

* Fix map resize bug

* Manually defined legends

* .

* Fix S3 support for panels opening webworkers

* revert changes to tile.vue

* Remove localhost from datasources on splash

* add manual linewidths to styling

* Fix basemap and uncolour tiles

* style tweaking in tile panel, plotly now supports fixed axis

* Meter or pixels for radius units

* Removed dark-matter, use internal options

* Linting

* Drop dark matter

* rounding out styling, more careful loading and memory management, documentation and refactoring

* Cleaning, add sqlfilter to joined db

* cache database loading

* Refactoring

* Compacting code

* Apply suggestions from code review

Co-authored-by: Copilot <[email protected]>

* Refactor aequlibrae plugin to sqlite-map to generalise

* sqlite-map: avoid caching remote DBs; clear join-data cache and export clearAllCaches alias

* sqlite-map: re-enable DB caching for all paths; deck: honor initialView and finalize overlay on destroy

* revert: undo DeckMapComponent.vue edits (restore previous behavior)

* refactoring, fixes to zoom. Issue with caching

* More refactoring

* Init. commit adding POLARIS features

* Drop polaris again, extend db.ts for some better generality

* Tom/extend tile panel (#4)

* Extend tile.vue to support hard-coded key-value pairs, sqlite queries for said values, sqlite queries for entire table

* Full SQL support, either individual queries or a full table

* Add usage comment

* Colour palette-ing, defaults to original pastel palette

* Apply suggestions from review

* Revert erroneous changes

* Cleaning, renaming

* Refactoring sqlite-map, mostly styling

* .

* Linting

* Move docs out of comments

* rename to aequilibrae-map

* Tidy, replace filesystem with default

* Rename map 'readers' to 'mapComponents'

* Fix legend

* Refactor

* .

---------

Co-authored-by: Copilot <[email protected]>
@billyc
Copy link
Copy Markdown
Contributor

billyc commented Jan 19, 2026

@tomstephen - wow this is quite a nice addition, thanks so much for sending this PR! I think the SQL-based viewer could be really beneficial for many people out there 🙏

It's a large PR so I need to some time to go through all of this. Just some quick notes before I dive in:

  • Yes, the docs should be a separate PR in the github.com/simwrapper/simwrapper.github.io repo. It would help me understand the code if that was added soon.
  • The example site looks really nice! It would be cool if I could get a .zip of the files (or similar) to add to our automated testing suite for the new views. Is that possible?
  • There are a few new dependencies, including packages that only have a few hundred weekly installs. I'm usually wary of one-off npm packages. There are already a TON of dependencies. Can you tell me the difference between the spatialite and spl.js packages? Do we need both? (At one point, we were using the sql.js package but removed it since we ended up not using it. So I know that one :-) )
  • There are changes to some common components like the Plotly and Tile plugins. I'll have to make sure that these additions aren't causing problems for our existing dashboards, of which there are many!
  • GitHub is telling me that "1 workflow awaiting approval" in the PR. What is this? I haven't seen that before.

Lots to chew on here! This is by far the largest PR I've received from outside our little dev team here in Berlin. Heaps of thanks to you and your team for putting this much effort into this open source project.

@jamiecook
Copy link
Copy Markdown

jamiecook commented Jan 19, 2026 via email

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Jan 20, 2026

@jamiecook ok makes sense re: the workflow. I guess the previous PRs have all been internal to my org so I didn't notice that before.

Now that it's enabled, the test suite tries to run... but fails immediately because package-lock.json is out of sync with the updated package.json. We check in our package-lock.json file whenever we change dependencies, because we have run into problems (many times) when packages silently update with "minor" revisions.

So, please run npm i to create a package-lock.json file and commit it - then the tests should be able to run automatically 🤞

@tomstephen
Copy link
Copy Markdown
Contributor Author

Thanks for all the feedback @billyc ! On those dot points,

  • (draft) PR for docs incoming.
  • Absolutely, I'll package a concentrated demo and send through tomorrow.
  • Good catch, spatialite and sql.js are both erroneous and I have removed. spl.js gives us sqlite w/ spatialite, but yes noted few weekly downloads. It may be possible to either compile our own wasm sqlite library, or use DuckDB with their sqlite/spatial options, but there's a bit of work in both of those options so I'm trying to avoid.
  • The tile ones I'm confident are not breaking changes, maintaining the original defaults. The plotly ones may, and are on my list to address. If you'd prefer these separated from this PR just in case I can sort that out.
  • As Jamie said, and I've run npm i and committed the new package-lock.json

@tomstephen tomstephen marked this pull request as ready for review January 29, 2026 01:53
…erived columns work (lineColor+lineWidth)

sqlite-map: robust join query and fetch all needed join columns for style-driven columns
@jamiecook
Copy link
Copy Markdown

Hey @billyc - was there anything else you identified as needing done on this? I think it's looking fairly complete, but tests still haven't been authorized so might be one or two little changes needed.

@tomstephen can you update the PR description with the linkage to the documentation PR too please.

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Feb 13, 2026

Hi guys, I'm back from holiday. And stupidly I didn't click the "authorize tests" button before I left so you couldn't see them run or fail 🤣 . Sorry about that.

The package-lock.json file was out of sync with your new carto-colors which caused the action to fail. Once I updated that, the tests ran here locally without incident. I also reviewed the files you changed and briefly examined the new plugin: everything seems quite compartmentalized and in good shape!

  • I did notice you edited ShapeFile.vue, thanks for the minor fix there
  • The tiles and legends of our existing dashboards don't look like they've been affected
  • I am very happy to see you using Vue functionality and slots, everything looks like it's well thought out.

Next I'm going to load up the test data files that you sent and see if I can get them to display, make sure it's loading and unloading properly, etc.

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Feb 13, 2026

And it loads! Looks very nice guys. 🎉

Two things:

(1) I think the viz is leaking background threads, which mean the entire viz stays in memory when the user navs back from the map to the file browser. Users navigate back and forth between different visualizations often, so it's really important that each view clean up resources (usually via Vue's beforeDestroy() lifecycle). Otherwise a 500Mb leak pretty quickly turns into a crashed tab :-(

You can see in the screenshot (from Chrome's "Memory" devtools tab) that the main window held 250Mb and there are two dangling workers. This snapshot was taken after loading the test data and then clicking on a navigation breadcrumb to go up a level.

I bet when the sql workers are destroyed correctly, the whole viz will release properly. I didn't look deeply at the SqliteMapComponent but my guess is that something there is being created and not destroyed. Please check that out?

(2) We include zoom/compass UI on each map for consistency, users usually expect these to be on maps. Did you leave this off on purpose or just an oversight? The template lines are on ShapeFile.vue:117

That's all I see so far. Let me know if you need help debugging the memory leak (or don't see it).

Billy

image

…ads, pass center info with view-state update
@tomstephen
Copy link
Copy Markdown
Contributor Author

Hey Billy, thanks for all the advice!

(0) Doh. package.lock updated!

(1) Yes, I see that too. Now closing things properly, I can see the worker disappear between dashboards. I do see one remaining, which I believe is the maplibre worker. This seems to remain while other dashboards however (say, https://simwrapper.app/examples/11-public-transport/) so I'm guessing that is intentional. Also noticed a potential memory issue from passing the view state poorly (ie not providing the center), then maps competing to update it, fixed that. Seems better on my end now...

(2) Not intentional, have added scale bar/north arrow!

Cheers,
Tom

@pedrocamargo
Copy link
Copy Markdown

pedrocamargo commented Feb 20, 2026

Hey @billyc , The latest AequilibraE support brings tools to build SimWrapper dashboards!! The documentation is coming, so you should see an uptick in usage in the next few months!

https://github.com/AequilibraE/aequilibrae/releases

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Feb 23, 2026

Hey @billyc , The latest AequilibraE support brings tools to build SimWrapper dashboards!! The documentation is coming, so you should see an uptick in usage in the next few months!

https://github.com/AequilibraE/aequilibrae/releases

@pedrocamargo This is awesome! I always felt like these projects/tools were complementary. Now it's happening! Thanks guys :-)

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Feb 23, 2026

@tomstephen I'll put this on staging today, it's more than good enough at this point.

With your permission may I use those test files you sent me as part of the Playwright automated test suite? I try to have at least one test per plugin, to ensure that the view loads and appears on-screen. Then as bugs arrive we try to to TDD to fix the bugs. (Most of the time, anyway).

@billyc billyc merged commit c2c4271 into simwrapper:staging Feb 23, 2026
1 check passed
@tomstephen
Copy link
Copy Markdown
Contributor Author

Thanks @billyc !

Yes, those test files are fine to include.

@billyc
Copy link
Copy Markdown
Contributor

billyc commented Mar 5, 2026

@pedrocamargo @tomstephen --

The Aequilibrae support is now live with release v4.5 of SimWrapper. You can see the test dashboard at the following link:

Thanks guys, this is great. 🙏

Normally I write up a little announcement when new features land. If you have something you want me to say other than "now supports Aequilibrae networks" please let me know!!

I'll also merge the documentation you supplied now, since the features are live.

@pedrocamargo
Copy link
Copy Markdown

pedrocamargo commented Mar 5, 2026

Just saying it supports AequilibraE models should be enough, @billyc. Thanks!

Well done, @tomstephen.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants