Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • M memopol
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 32
    • Issues 32
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 6
    • Merge requests 6
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • Political MemoryPolitical Memory
  • memopol
  • Merge requests
  • !78

Rewrite score computing, fixes #69

  • Review changes

  • Download
  • Email patches
  • Plain diff
Merged njoyard requested to merge rewrite-scores-fcb1226b into master May 29, 2016
  • Overview 2
  • Commits 5
  • Pipelines 0
  • Changes 16

Created by: njoyard

This PR removes static, asynchronous representative score updates by replacing plain models with views in the representatives_recommendations app:

  • votescores computes the score consequence of each vote on the representative score ; it is mapped to the new VoteScore model that replaces ScoredVote (which extended Vote and computed scores in python).
  • dossierscores was introduced in a previous changeset but was rewritten to use votescores; it aggregates votes over proposals from a single dossier and returns the score contribution of each dossier on representatives scores. It is mapped to the DossierScore model.
  • representativescore aggregates scores from the dossierscores view over all dossiers for each representative and gives a direct queryable access to the score of each representative. It is mapped to the RepresentativeScore model.

This PR also removes score update facilities as they now don't have any use.

TL;DR: no more manual score updates, scores are computed on the fly.

Assignee
Assign to
Reviewers
Request review from
Time tracking
Source branch: rewrite-scores-fcb1226b