codeforpdx / recordexpungPDX

A project to automate the expungement of qualifying criminal records in Oregon. This project is done in conjunction with Qiu-Qiu Law.
https://recordsponge.com
MIT License
49 stars 87 forks source link

Classify a disposition more accurately #601

Closed wittejm closed 4 years ago

wittejm commented 4 years ago

For the purposes of expungement, a charge can be ruled as "convicted", "dismissed", or "no complaint".

Legally speaking, "dismissed" and "acquitted" have separate definitions. But for expungement they are considered the same and we call both of those dismissals.

In the OECI database, multiple different ruling strings on the Disposition can be interpreted as convictions:

And multiple different ruling strings can be interpreted as dismissals:

Also, the "Diverted" ruling is a weird case that is being addressed in #592

Currently the Charge class has the convicted() method which returns True only if the disposition.ruling.lower() value begins with the substring "convicted". This should be updated to classify all of the listed rulings correctly. The Charge.acquittal should be updated also.

This addresses two bugs reported from the logic bug-reports page (identifying record information is omitted here)

Also I suggest renaming the occurrences of acquittal and dismissal in the project to to a single term since their legal definitions are distinct but we treat them as equivalent in the expunger.

wittejm commented 4 years ago

More types that can come from OECI: "converted" and "conversion" (appearing as a substring in the disposition ruling) should both be interpreted as convictions.

wittejm commented 4 years ago

This field be the one that is read by the frontend to determine convicted/not convicted status (related to PR #622 ), rather than redundnantly parse the ruling string