/filings/ endpoint marking more than one most_recent
Form 1 (Statement of Organization)
#3096
Closed
3 of 4 tasks
So that committees and the public can see the most recent version of the Form 1 (Statement of Organization), we need to update the logic to handle when a committee files multiple Form 1's as new and only show the newest as "Current Version" and the others as "Past Version."
@patphongs discovered this issue.
Example: (https://www.fec.gov/data/committee/C00639013/?tab=filings)
Background: Using FECFile and other 3rd party vendors, committees can amend their Statement of Organization (Form 1) by filing it as new. Then, an overnight process updates it to show as amended. As a result, there is no amendment number associated with the file that was submitted as new and now displays as amended.
Potential fix: Add to /filings/ "amendment chain" logic to handle multiple F1Ns for the same committee. If the amendment chain logic fails (>1 current version for the same filing type - for statements of org. ) then use the most recently filed one as the current version and mark the others as past version.
API example
https://fec-dev-api.app.cloud.gov/v1/filings/?api_key=DEMO_KEY&sort_hide_null=false&sort=-receipt_date&per_page=10&page=1&candidate_id=H8CA05035&form_type=F99&form_type=RFAI&request_type=-1&request_type=-2&request_type=-3&request_type=-4&request_type=-5&request_type=-6&request_type=-7&request_type=-8&request_type=-9
Other front-end example:
https://fec-dev-proxy.app.cloud.gov/data/candidate/H8WI01024/?tab=filings
- [ ] Run the PGtap amendment chain test ([DO NOT MERGE] Add pgTap test for amendment chain view #3268)PGTap test is for efiling amendment_chainExisting amendment chain view is complicated and not a good place to fix the logic for F1's and F2's. We should investigate where else we can fix the logic upstream.
The text was updated successfully, but these errors were encountered: