greedo / python-xbrl

xbrl parser written in Python :bulb:

Home Page:https://pypi.python.org/pypi/python-xbrl

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Cannot fetch common shares outstanding

mmistroni opened this issue · comments

Hello
great library! just what i need to monitor historical data for corporates. Unfortunately, out of the gaap_object i cannot get out the common_shares_outsanding, which is what i desperately need.
Would you be able to tell me why
here's my sample code, i'll attach the XBRL i m trying to parse

    >>> from xbrl import *
    >>> xbrl_parser = XBRLParser()
    >>> xbrl = xbrl_parser.parse(file('brn-20171231.xml'))
    >>> gaap_obj = xbrl_parser.parseGAAP(xbrl, context="current", ignore_errors=0)
    >>>gaap_obj.__dict__
    {'assets': 31231.0,

'commitments_and_contingencies': 0,
'common_shares_authorized': 0,
'common_shares_issued': 0,
'common_shares_outstanding': 0,
'comprehensive_income': -999.0,
'comprehensive_income_interest': 0,
'comprehensive_income_parent': -999.0,
'cost_of_revenue': 0.0,
'costs_and_expenses': 3240.0,
'current_assets': 0,
'current_liabilities': 0,
'equity': 0,
'equity_attributable_interest': 408.0,
'equity_attributable_parent': 0,
'extraordary_items_gain_loss': 0,
'gross_profit': 0,
'income_before_equity_investments': -1384.0,
'income_continuing_operations_tax': 0,
'income_discontinued_operations': 0,
'income_from_equity_investments': -153.0,
'income_loss': -1537.0,
'income_tax_expense_benefit': -503.0,
'interest_and_debt_expense': 0,
'liabilities': 227.0,
'liabilities_and_equity': 31231.0,
'net_cash_flows_discontinued': 0,
'net_cash_flows_financing': 0,
'net_cash_flows_financing_continuing': 0,
'net_cash_flows_investing': 0,
'net_cash_flows_investing_continuing': 0,
'net_cash_flows_investing_discontinued': 0,
'net_cash_flows_operating': 0,
'net_cash_flows_operating_continuing': 0.0,
'net_cash_flows_operating_discontinued': 0,
'net_cash_operating_continuing': 0,
'net_income_loss': -1017.0,
'net_income_loss_noncontrolling': 0,
'net_income_parent': 0.0,
'net_income_shareholders': 0,
'non_current_assets': -31231.0,
'noncurrentLiabilities': 0.0,
'noncurrent_liabilities': 0,
'nonoperating_income_loss': 0,
'operating_expenses': 0,
'operating_income_loss': 0,
'other_comprehensive_income': 0,
'other_operating_income': 0,
'preferred_stock_dividends': 0,
'redeemable_noncontrolling_interest': 0,
'revenue': 0.0,
'revenues': 821.0,
'stockholders_equity': 16254.0,
'temporary_equity': 0}

If u dont have time, pls give me some hints and i'll dig in the code myself
thanks a lot!
Damn, i cant attach any files. the XBRL i am tyring to parse is at this location

https://www.sec.gov/Archives/edgar/data/10048/000001004818000002/