okfn-brasil / jarbas

🎩 API for information and suspicions about reimbursements by Brazilian congresspeople
https://jarbas.serenata.ai/
296 stars 61 forks source link

Update Django #268

Closed cuducos closed 7 years ago

cuducos commented 7 years ago

Opening this PR in favor of #266 because updating Django REST Framework required minor edits on the source code.

This is a basic update: if after updating the packages tests still pass and navigation still works probably we haven't broken anything.

anaschwendler commented 7 years ago

Testing this PR!

  1. Clone the repository:

    $ git clone git@github.com:datasciencebr/jarbas.git
  2. Open the repo folder:

    $ cd jarbas
  3. Checkout to @cuducos branch:

    $ git checkout -b cuducos-update-django origin/cuducos-update-django
  4. Update the branch:

    $ git merge master
  5. Copy the .env file:

    $ cp contrib/.env.sample env
  6. Build and start services:

    $ docker-compose up -d
  7. Create the database and apply the migrations:

    $ docker-compose run --rm django python manage.py migrate
  8. Seeding it with sample data:

$ docker-compose run --rm django python manage.py reimbursements /mnt/data/reimbursements_sample.xz
$ docker-compose run --rm django python manage.py companies /mnt/data/companies_sample.xz
$ docker-compose run --rm django python manage.py suspicions /mnt/data/suspicions_sample.xz
$ docker-compose run --rm django python manage.py tweets
  1. Open http://localhost:8000/ and http://localhost:8000/dashboard and do tests with functionalities and works fine :)

There is some conflicts with the master branch, @cuducos can you solve it and then I merge it?

cuducos commented 7 years ago

Conflicts fixed ; )