Closed lizadaly closed 1 year ago
Merging #1994 (473dc1f) into develop (f8ee11c) will decrease coverage by
0.32%
. The diff coverage is21.87%
.
@@ Coverage Diff @@
## develop #1994 +/- ##
===========================================
- Coverage 76.82% 76.51% -0.32%
===========================================
Files 62 63 +1
Lines 6927 6975 +48
===========================================
+ Hits 5322 5337 +15
- Misses 1605 1638 +33
Impacted Files | Coverage Δ | |
---|---|---|
web/main/legal_document_sources.py | 21.38% <21.38%> (ø) |
|
web/main/models.py | 82.67% <100.00%> (+8.72%) |
:arrow_up: |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.
This is ready to review. It should be deployable to staging without the API key; since the source defaults to inactive
the relevant code won't be called and this should just be a no-op.
I created a separate issue for generating and populating API keys for staging and prod and then we can flip the source to "active" on staging and start reviewing the actually behavior and content for what final acceptance criteria should be.
This functions as a proof of concept, but it's very rough. There's a lot to do in terms of mapping CourtListener's API fields to our own, and figuring out what transformations need to happen on the content itself.
What this does do:
active=False
and that can be overridden per environment in the admin.What this doesn't do:
metadata
field forLegalDocuments
.class="indent"
).What this happens to do:
models.py
. These aren't Django models and it's already hard to reason about that file because it's so long.Next steps
I think we'll need a few days to decide whether we want to merge a version of this. The code can easily go live as-is and as long as the source is left in the default
inactive
state, it won't be visible on prod, but could be enabled on staging. We'd want to give all parties a heads-up before doing so and maybe see if there's a more performant API key available; the response time from the one I set up is pretty variable but perhaps it's being rate-limited.