dgunning / edgartools

Navigate SEC Edgar data in Python
MIT License
489 stars 97 forks source link

Submissions in pages > 1 not available when identifying company by ticker #144

Open TristanJanicki opened 4 hours ago

TristanJanicki commented 4 hours ago

So I have this code here

set_identity('tristan@pocket-quant.com')
ticker = "BLK"
c = Company(ticker)
print(c.category)
filing = c.get_filings(accession_number='0000950170-22-022155').latest(1)
reportDate = filing.report_date

And it throws this exception

File "/utils/test-edgartools.py", line 11, in <module> reportDate = filing.report_date ^^^^^^^^^^^^^^^^^^ AttributeError: 'NoneType' object has no attribute 'report_date'

However when I use this code with the CIK instead of the ticker it works

ticker = "0001364742"
c = Company(ticker)
...

This submission is on page 2 of BLKs submissions api response so I'm guessing it has to do with that.

https://data.sec.gov/submissions/CIK0001364742-submissions-002.json

dgunning commented 3 hours ago

There are 2 Blackrocks, which is why the discrepancy

blackrock