Repository navigation
v6.2.0
pip install --upgrade edgartools6.2 is a minor release. Two fixes return different values than 6.1 did: get_operating_cash_flow() returns None instead of the continuing-operations figure when discontinued operations also report operating cash, and a reported zero shows as 0 where it showed blank. ParserConfig(extract_images=...) is deprecated; see the 6.1 upgrade notes.
Please report anything that breaks at https://github.com/dgunning/edgartools/issues.
Added
viewer.compare_statements(xbrl)checks the statements edgartools builds against the SEC's statement pages. Each page row and cell is compared with whatxbrl.statements(and soget_financials()) shows, in the DataFrame and the rendered table, with dropped rows, wrong values, signs and crashes counted separately. On Brixmor's FY2020 cash flow it reports beginning cash 360,073,000 where the page shows 21,507. (bead edgartools-auvk1.10)- Standard concepts for broker, insurer, BDC and utility line items. Ten industry measures that had no standard concept now have their own: net revenue after interest expense, investment banking revenue, trading gains, securities borrowed, resale-agreement assets, future policy benefits, policyholder funds, paid-in-kind interest income, and regulated and unregulated operating revenue. JPMorgan's FY2023 total net revenue of 158,104M now reads as
NetRevenueAfterInterestExpense. report.section(item)says how reliably an item was located: it returns theSectionthatreport[item]reads, with.confidence,.warningsand.detection_method;strict=Trueraises the newLowConfidenceSectionErrorinstead of returning a doubtful one. On 10-K, 10-Q, 8-K, 20-F and 40-F. NVIDIA's FY2025 Item 8, a 207-character pointer to Item 15, reports confidence 0.5 with an incorporation-by-reference warning.- Extensible-enumeration domains and members:
XBRL.element_metadata(concept).enumerationgives an enumeration concept's declared domain, linkrole, headUsable flag and set/single kind, from the filing schema or the FASB release the filing imports, andXBRL.enumeration_members(value)splits a fact value into namespace, local name and concept id. All 237 enumeration facts in 15 tracked fixture filings now resolve, with all 260 members mapped to a concept. XBRL.element_metadata()says what a concept is. It returns a concept's type, balance, period type, abstract flag, FASB definition and ASC references from the filing's schema, the bundled FASB table and the filing's MetaLinks.json, which it downloads lazily. Oracle's 10-Q 0001193125-26-389274 givesIncreaseDecreaseInContractWithCustomerLiabilityas debit, with ASC 912-310-45-11 and 230-10-45-28. (GH #1426)
Changed
viewer.compare()pairs every numeric cell of the SEC statement pages with exactly one XBRL fact. Sign, dimensions, units and equity statements are checked, the tolerance is half the last displayed digit, and a cell the page does not identify isnot_comparablewith a reason, withcoveragereported besidematch_rate. Airbnb's FY2024 10-K went from 141 of 190 values matched to 278 of 278 cells. (bead edgartools-auvk1.8)
Deprecated
ParserConfig(extract_images=...)is deprecated. The field defaulted toFalseand was documented as switching image extraction, but nothing read it, so every<img>became anImageNoderegardless. Passing it now raises aDeprecationWarning; it is removed in 7.0 and parsing output is unchanged. (bead edgartools-ru9x)
Fixed
- A reported zero shows as 0 — the rendered table printed nothing for a filed zero, as if no fact were filed, and a negated label turned a zero into -0.0 in
to_dataframe(); the SEC page shows 0 for both. On an 82-filing sample, blank zeros fell from 840 cells to 0 and negative zeros from 185 to 0. - 20-F Part sections hold their items.
doc.sections['part_i']on a 20-F returned only its divider line ('PART I') when the Part and its first item header scored the same heading level; a Part now runs to the next Part divider or SIGNATURES. Nine of fifteen corpus 20-Fs were affected, e.g. 0001213900-21-018959part_igrows from 6 to 604,618 characters. - Negated labels sign the value on every statement — the presentation sign applied only to four statement types, so a statement reached by role kept the filed sign (DRDGOLD cost of sales: +3,741,500,000 where the SEC page shows (3,742) million) and parentheticals and statements of equity ignored negated labels. On an 82-filing sample, sign disagreements fell from 58 cells to 0.
- Balance rows in duration columns show the right period's value — a member row under a beginning balance showed the closing balance (Brixmor 2020: 360,073,000 where the SEC page shows 21,507 thousand), and the rendered table blanked balance rows the DataFrame had. Both now place an instant by one rule, the row's own arc role; on an 82-filing sample, value disagreements fell from 48 to 0 and rendered blanks from 279 to 74.
Statement.to_dataframe()crashed under pandas 3 on a statement where no row has a display sign. Applying signs assigned an empty object slice into a float column, raisingInvalid value '[]' for dtype 'float64', so walking Keysight's FY2020 10-K notes failed on its land-sale details role. Signs are now read as numbers; the filing's cash flow still shows accounts receivable as 75 (millions). (GH #1960)balance_sheet()returned a one-row stub for some filers in 6.1.0. A filing's statement-typed role holding only a text block was accepted before the real balance sheet was reached, so Mettler-Toledo's FY2021-2023 10-Ks returned the Schedule II text block and no values. The real statement now wins: MTD's FY2022 total assets read 3,492,395K again. (GH #1970)- Cover-page checkbox answers, mid-sentence emphasis and prose cross-references became headings. Header patterns matched case-insensitively, so all-caps rules accepted any word (Apple's FY2024 10-K made
ora heading), and context alone could promoteNoor a bold word inside a sentence. Over the 128-filing parser corpus about 4,100 such headings are gone and no section moved. (bead edgartools-s4cg) - A 20-F that writes its lettered items as
Item 16. A.returned none of them as sections. Section patterns expected the letter attached (Item 16A), so 20-F 0001062993-16-008650 lost all eight of Items 16A-16H; all eight now resolve, and the same spelling is accepted for every lettered 10-K, 10-Q and 20-F item. (bead edgartools-ga4a) PortfolioInvestments.from_statement()disagreed withfrom_xbrl()on the same filing. It re-parsed the statement's labels without member candidates orfrom_xbrl's exclusions, so on 38 BDC 10-K and 10-Q filings it returned no rows on 11 (Hercules, Sixth Street, Crescent among them) and differed in rows or names on the other 27. It now reads the statement's filing throughfrom_xbrl. (GH #1612)- Grid and simple markdown tables split a row at every line break in a cell. A cell like
Line one<br>line twobroke its row over three lines and left the value after it in no column. Both formats now collapse a cell to one line, as the pipe format already did. (bead edgartools-grn9e) - Table rows mixing
<th>and<td>came out with their cells reordered. Everytdwas emitted before everyth, so a row writtenLabel | Revenue | 100parsed asRevenue | 100 | Label, moving the row label to the last column. Cells now keep document order. (bead edgartools-j99a) - Table footers were duplicated or dropped. A
<tfoot>table without<tbody>read its total rows twice (once as body, once as footer); one with<tbody>lost them from markdown,text()andto_dataframe(), which never read the footer. Footer rows now appear exactly once, after the body, in every output. (bead edgartools-niru) - A note's detail tables went missing when the filer left "(Details)" off their titles. SEC's FilingSummary.xml then files them under Notes, Cover or Uncategorized, so Costco's FY2021
tenk.notes["Leases"].detailswas empty and one lease table was typed as a cover page. A disclosure role with value line items and no text block is now read as a detail; FY2021 Leases has its four tables. (GH #1947) - Markdown and heading text split words a filer wrote across two inline elements. A 2010 10-K's
PROPERT<a>IES</a>heading read asPROPERT IES, and markdown space-joined every inline run: 2,519 of 17,394 multi-child paragraphs across the HTML fixtures had extra word breaks, now 139. Markdown now places gaps wheretext()does. (bead edgartools-8n9an) ViewerReport.currency_scalingreturned a scale the SEC page does not use. It was inferred from XBRLdecimals, which states rounding. It is now the scale each R page declares, for any currency symbol, and 1 when the page declares none: Airbnb's FY2024 statement of operations, shown in whole dollars, read 1,000,000 and now reads 1.parse_numericalso reads values such as₨ 12,724andR$ 88,242.5. (GH #807, bead edgartools-auvk1.8)get_concept('revenue')andget_concept('stockholders_equity')agree with the getters. The synonym groups lacked the IFRS, bank and utility totals thatget_revenue()andget_shareholders_equity()read: TD's equity came back as its FY2019 figure (87.7B CAD against 125.6B), Novo Nordisk's equity and Goldman Sachs's revenue as None, and Duke's revenue as its contract-revenue slice.get_concept('net_income')returns profit attributable to owners for IFRS filers. Its synonym group reachedProfitLoss, which includes non-controlling interests, beforeProfitLossAttributableToOwnersOfParent, so it disagreed withget_net_income()once that was fixed: TSM's 1,157.52B against 1,158.38B attributable to owners.EntityFactsgetters read IFRS filers' own totals.get_shareholders_equity()andget_operating_income()now read the ifrs-full totals, andget_net_income()returns profit attributable to owners. Of 16 IFRS filers measured, 14 got None for equity and the other two (Toyota, Sony) got their last US-GAAP figure, years old; BHP's net income was 24% high.get_total_assets()no longer returns current assets.get_operating_cash_flow()returned operating cash of continuing operations as the total when discontinued operations also had operating cash. It now returns None for those filings (64 of the 95 CY2025 filers reporting continuing without a total had nonzero discontinued operating cash);get_standard_concept()now uses the section or statement forDividendsReceivable,DividendsPreferredStockandImpairmentOfInvestments. (GH #1452)- Abstract status of us-gaap and srt concepts now comes from the FASB declarations. Presentation trees and
calculation_linkbase()read the bundled element table before guessing from the name, so headings the name guess missed are now abstract, like Microsoft's FY2024AwardTypeAxis, which never reached its element catalog. Across the 24,439 bundled elements the guess was wrong for 17. (GH #1730)