Skip to content

Conversation

@zandre-eng
Copy link
Contributor

Product Description

No user-facing changes.

Technical Summary

Link to ticket here.

This PR adds a query which will be run within a Django shell to query production data. Specifically, the query is inteded to find out what the average number of deliveries is for users, categorised by delivery type and status. The result of this query will inform what reasonable milestone markers can be used for Connect delivery credentials.

PLEASE NOTE: This PR is intended for review only and should not be merged, hence keeping it in draft status.

Safety Assurance

Safety story

  • Tested on staging

This is simply a once-off query that does not affect/change any existing data.

Automated test coverage

N/A

QA Plan

No QA planned.

Labels & Review

  • The set of people pinged as reviewers is appropriate for the level of risk of the change

Copy link
Collaborator

@calellowitz calellowitz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one suggestion, otherwise looks good

),
status_name=F("status"),
)
.annotate(user_count=Count("opportunity_access__user_id", distinct=True), total_completed_work=Count("id"))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it might be worth filtering this for approved status or saved_approved_count__gt=0 to only count valid completed works

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Filtering has been added for only approved works (65849e3).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants