patricktemple / 350BillTracker

1 stars 3 forks source link

350Brooklyn Bill Tracker

Overview

The 350Brooklyn Bill Tracker is a web app made for 350.org's Brooklyn chapter to help them lobby for strong climate legislation in NYC and New York State. It's a centralized place for volunteers to keep track of the bills that the group is pushing and organize efforts to get them passed. It's hosted at 350billtracker.com but its use is locked down to organizers within the group. Some demos are displayed on this page below.

Key features:

The main design principle is to keep it simple, and build only features that are useful and don't exist elsewhere. The city and state both already have websites displaying legislative info, and there's no point in recreating those. Along the same lines, a lot of activists work using simple tools like Google Sheets. We don't want to force too much of their workflow into this app instead, which has specific use cases in mind and requires software work to change.

Instead, this tool provides specific time-saving features by pulling in information that's helpful to have tracked in one place. It is meant to work alongside 3rd party websites and spreadsheets, rather than replace them.

Tech stack

Backend:

Frontend:

Deployment:

Development

Running locally

From repo root:

script/run

This builds the frontend and then hosts that inside the Flask app, which it starts in a Dockerized environment. Then you can just hit http://localhost to run the frontend.

For local frontend development, you'll want a React dev server instead:

cd frontend
yarn start

This will point to the locally running Flask backend. You can have both running at the same time; just remember that port 3000 is the live frontend dev server whereas port 80 is the React app built into the Flask backend.

Deploying

From repo root:

script/deploy

Do NOT just run eb deploy within the backend directory, as this will not rebuild the frontend to the latest version.

Formatting

From repo root, autoformat both backend and frontend code:

script/format

Demos

Tracking a new state bill

Tracking a new state bill

Generating a Power Hour spreadsheet

Each week, 350Brooklyn runs "Power Hour" phone bank sessions in which volunteers call the city council members for particular bills to ask them to sponsor the bill. We run these off a spreadsheet where volunteers log the results of each conversation. This tool autogenerates the sheets along with the latest sponsorship status and contact info. Generating a power hour