juriscraper icon indicating copy to clipboard operation
juriscraper copied to clipboard

533 Adds NDAs support for recap email

Open albertisfu opened this issue 3 years ago • 1 comments

Support to parse and download free documents for NDAs was added.

It was necessary to add a new field to support download documents for NDAs email_notice_type due to download link structures are different.

Here is some example data for an NDA:

{
  "case_name": "New York State Telecommunicati v. James",
  "court_id": "ca2",
  "date_filed": "2022-03-23",
  "docket_entries": [
    {
      "date_filed": "2022-03-23",
      "description": "REPLY BRIEF, on behalf of Appellant Letitia A. James, FILED. Service date 03/23/2022 by CM/ECF. [3283515] [21-1975]",
      "document_number": "00208754210",
      "document_url": "https://ecf.ca2.uscourts.gov/docs1/00208754210?uid=59a7f7615f78153b",
      "pacer_case_id": "21-1975",
      "pacer_doc_id": "00208754210",
      "pacer_magic_num": "59a7f7615f78153b",
      "pacer_seq_no": null
    }
  ],
  "docket_number": "21-1975",
  "email_notice_type": "NDA",
  "email_recipients": [
    {
      "email_addresses": [
        "[email protected]"
      ],
      "name": "Recap email recipient, -:"
    }
  ]
}

Added tests using examples from the emails we've received from different courts but they aren't too many, so as long as we receive more NDA's it might be necessary to adjust the parser to consider all possible cases.

Let me know what do you think and if it's ok I can do a version bump and update the CL PR.

albertisfu avatar Aug 12 '22 15:08 albertisfu

Thanks! I've changed the email_notice_type parameter to appellate.

Also added the version bump but I think is not ready because I updated my CL dev image with it and ran more tests including some new NDA's we received today and there is a new one from ca11 that it's failing to parse the document description properly. So I'll be back with the fix it and add more tests.

albertisfu avatar Aug 12 '22 23:08 albertisfu

I've solved the problem parsing the description that I detected in ca11.

  • Now we get the pacer_case_id for NDAs
  • As we discussed on #2257 the document_number now is null for NDAs
  • Added new examples (recipients anonymized)

Let me know if there is anything else. I'll also update CL PR with these changes.

albertisfu avatar Aug 23 '22 19:08 albertisfu

Thanks! I've applied the suggestion and rebased with main so I also update some tests to combine the last NDAs and NEFs changes, I also update the change log with the get attached documents for NEFs. So that when this PR is merged into the main the new Juriscraper version will be released.

albertisfu avatar Aug 24 '22 15:08 albertisfu