从外部获取选举元数据和结果。
politico-civic-election-loader的Python项目详细描述
政治公民选举加载器
从外部获取选举元数据和结果。在
快速启动
- 安装应用程序。在
$ pip install politico-civic-election-loader
- 将应用程序添加到Django项目设置中。在
- 迁移数据库。在
$ python manage.py migrate entity
发展中
运行开发服务器
移到example目录,安装依赖项并使用pipenv运行开发服务器。在
$ cd example
$ pipenv install
$ pipenv run python manage.py runserver
设置PostgreSQL数据库
- 运行make命令来设置一个新的数据库。在
$ make database
- 向
example/.env
添加连接URL。在
DATABASE_URL="postgres://localhost:5432/electionloader"
- 从示例应用程序运行迁移。在
$ cd example
$ pipenv run python manage.py migrate
版权所有
©2019年至今POLITICO,LLC
- 项目
标签: