Skip to content
This repository has been archived by the owner on Sep 28, 2020. It is now read-only.

Make most setup script flags work #473

Merged
merged 7 commits into from
Dec 7, 2017

Conversation

jisantuc
Copy link
Collaborator

@jisantuc jisantuc commented Oct 20, 2017

Overview

This PR makes changes to make most setup.py flags work.

The (mostly) working flags are:

  • -gX (load geolevels, very slow)
  • -V (create database views)
  • -t (create template plans)
  • -s (collect static files)
  • -l (create language files)

The broken flags are:

  • -G (was blocked by -gX, may not be any more, but I'm out of time to investigate right now)
  • -a (create adjacencies, depends on a data file that I don't have a good mock for)
  • -nX (nest geolevel X, relies on old geos interface)

Remaining known issues with the flags are captured in #472.

It also removes several flags that existed to enable functionality that either is no longer intended or is no longer necessary with a more modern django.

Checklist

  • PR has a name that won't get you publicly shamed for vagueness

Testing

  • docker-compose build
  • ./scripts/load_development_data -- runs migrations, downloads a shapefile, loads shapes from the shapefile into the database (runs setup.py ... -g0, proving functionality). You can cancel this after a minute or two if you're feeling impatient.
  • docker-compose exec django bash
  • run ./setup.py config/config.xsd config/config.xml with each of the other working flags above
  • they should all succeed except -t and -s. -t depends on running I think -g1 and also -n1. It has data dependencies. If you let -g0 run for a little bit though, two plans succeed, which you can check with:
>>> Plan.objects.count()
2

from the django shell. -s fails because I uninstalled compressor when I setup the dev environment 🤦‍♂️. Should be an easy fix.

@jisantuc jisantuc changed the title Make most scripts work Make most setup script flags work Oct 20, 2017
@jisantuc jisantuc requested a review from kshepard October 24, 2017 15:15
@jisantuc jisantuc merged commit 01cee7e into develop Dec 7, 2017
@jisantuc jisantuc deleted the feature/jis/try-flags-and-make-changes branch December 7, 2017 15:59
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant