Summary of significant accounting policies. | 2. Summary of significant accounting policies (a) Principles of consolidation and basis of presentation: The accompanying consolidated financial statements are prepared in accordance with accounting principles generally accepted in the United States of America (“GAAP”) and include the consolidated accounts and operations of our subsidiaries in which we have a controlling financial interest. The usual condition for a controlling financial interest is ownership of the majority of the voting interest of an entity. However, a controlling financial interest may also exist in entities, such as a variable interest entity (“VIE”), through arrangements that do not involve controlling voting interests. We apply the standard that requires consolidation of VIEs, for which we are the primary beneficiary. The guidance requires a variable interest holder to consolidate a VIE if that party has both the power to direct the activities that most significantly impact the entities’ economic performance, as well as either the obligation to absorb losses or the right to receive benefits that could potentially be significant to the VIE. We have determined that our equity investments are not VIEs by evaluating their design and capital structure. Accordingly, we use the equity method of accounting for all of our investments in which we do not have an economic controlling interest. We eliminate all intercompany accounts and transactions in consolidation. (b) Cash and cash equivalents include cash deposited at banks and highly liquid investments with original maturities of 90 days or less when purchased. (c) Restricted cash represents cash, cash equivalents and cash advances that are maintained by the projects or corporate to support payments for maintenance costs, reconstruction costs and meet project level and corporate contractual debt obligations. Restricted cash is classified as a current or long-term asset based on the timing and nature of when or how the cash is expected to be used or when the restrictions are expected to lapse. (d) Accounts Receivable are carried at cost. We periodically assesses the collectability of accounts receivable, considering factors such as specific evaluation of collectability, historical collection experience, the age of accounts receivable and other currently available evidence of the collectability, and record an allowance for doubtful accounts for the estimated uncollectible amount as appropriate. We had no allowance for doubtful accounts recorded at December 31, 2019 and 2018, respectively. (e) Deferred financing costs represent costs to obtain long‑term financing and are amortized using the effective interest method over the term of the related debt, which ranges from 1 to 6 years. The carrying amount of deferred financing costs were recorded on the consolidated balance sheets as net of long-term debt and convertible debentures and was $8.5 million and $11.8 million at December 31, 2019 and 2018, respectively. Interest expense from the amortization of deferred financing costs for the years ended December 31, 2019, 2018, and 2017 was $3.2 million, $5.1 million, and $6.3 million, respectively. (f) Inventory represents spare parts, biofuel and natural gas, the majority of which is consumed by our projects in provision of their services, and are valued at the lower of cost and net realizable value. Cost is the sum of the purchase price and incidental expenditures and charges incurred to bring the inventory to its existing condition or location. The cost of inventory items that are interchangeable are determined on an average cost basis. For inventory items that are not interchangeable, cost is assigned using specific identification of their individual costs. (g) Property, plant and equipment are stated at cost, net of accumulated depreciation. Depreciation is provided on a straight‑line basis over the estimated useful life of the related asset. Significant additions or improvements extending asset lives or increasing generating capacity are capitalized as incurred, while repairs and maintenance that do not improve or extend the life of the respective asset are charged to expense as incurred. (h) Project development costs are expensed in the preliminary stages of a project and capitalized when the project is deemed to be commercially viable. Commercial viability is determined by one or a series of actions including among others, obtaining a PPA. When a project is available for operations, capitalized interest and project development costs are reclassified to property, plant and equipment and depreciated on a straight‑line basis over the estimated useful life of the project’s related assets. Capitalized costs are charged to expense if a project is abandoned or management otherwise determines the costs to be unrecoverable. (i) Intangible assets include PPAs and fuel supply agreements at our projects acquired as part of business combinations. Carrying amounts for PPAs and fuel supply agreements are based on the fair value assigned in the allocation of the purchase price of the acquired business. The balances are presented net of accumulated amortization in the consolidated balance sheets. Amortization is recorded on a straight‑line basis over the remaining term of the agreement. (j) We have investments in entities that own power-producing assets with the objective of generating cash flow. The equity method of accounting is applied to such investments in affiliates, which include joint ventures, partnerships, and limited liability companies because the ownership structure prevents us from exercising a controlling influence over the operating and financial policies of the projects. Our investments in partnerships and limited liability companies with 50% or less ownership, but greater than 5% ownership in which we do not have a controlling interest are accounted for under the equity method of accounting. We apply the equity method of accounting to investments in limited partnerships and limited liability companies with greater than 5% ownership because our influence over the investment’s operating and financial policies is considered to be more than minor. Under the equity method, equity in pre‑tax income or losses of our investments is reflected as equity in earnings of unconsolidated affiliates in the consolidated statements of operations. We apply the nature of distributions method for the classification of our investments accounted for by the equity method in the Consolidated Statements of Cash Flows. The cash flows that are distributed to us from these unconsolidated affiliates are directly related to the operations of the affiliates’ power-producing assets and are classified as cash flows from operating activities in the consolidated statements of cash flows. We record the return of our investments in equity investees as cash flows from investing activities. Cash flows from equity investees are considered a return of capital when distributions are generated from proceeds of either the sale of our investment in its entirety or a sale by the investee of all or a portion of its capital assets. (k) Long‑lived assets, such as property, plant and equipment, and other intangible assets and liabilities subject to depreciation and amortization, are reviewed for impairment whenever events or changes in circumstances indicate that the carrying amount of an asset group may not be recoverable. Recoverability of assets to be held and used is measured by a comparison of the carrying amount of an asset to estimated undiscounted future cash flows expected to be generated by the asset group. If the carrying amount of an asset group exceeds its estimated future cash flows, an impairment charge is recognized in the amount by which the carrying amount of the asset group exceeds its fair value. Our asset groups have been determined to be at the plant level, which is the lowest level in which independent, separately identifiable cash flows have been identified. We also review a project for impairment at the earlier of executing a new PPA (or other arrangement) or six months prior to the expiration of an existing PPA. Factors such as the business climate, including current energy and market conditions, environmental regulation, the condition of assets, and the ability to secure new PPAs are considered when evaluating long‑lived assets for impairment. Investments in and the operating results of 50%-or-less owned entities not consolidated are included in the consolidated financial statements on the basis of the equity method of accounting. We review our investments in such unconsolidated entities for impairment whenever events or changes in business circumstances indicate that the carrying amount of the investments may not be fully recoverable. Evidence of a loss in value that is other than temporary might include the absence of an ability to recover the carrying amount of the investment, the inability of the investee to sustain an earnings capacity which would justify the carrying amount of the investment or, where applicable, estimated sales proceeds that are insufficient to recover the carrying amount of the investment. Our assessment as to whether any decline in value is other than temporary is based on our ability and intent to hold the investment and whether evidence indicating the carrying value of the investment is recoverable within a reasonable period of time outweighs evidence to the contrary. We generally consider our investments in our equity method investees to be strategic long‑term investments. Therefore, we complete our assessments with a long‑term view. If the fair value of the investment is determined to be less than the carrying value and the decline in value is considered to be other than temporary, the asset is written down to its estimated fair value. (l) Goodwill is the residual amount that results when the purchase price of an acquired business exceeds the sum of the amounts allocated to the assets acquired, less liabilities assumed, based on their fair values. Goodwill is allocated, as of the date of the business combination, to our reporting units that are expected to benefit from the synergies of the business combination. Goodwill is not amortized and is tested for impairment annually as of November 30, or more frequently if events or changes in circumstances indicate that would more likely than not reduce the fair value of a reporting unit below its carrying value. In our test, we first perform step zero to determine whether the existence of events or circumstances leads to a determination that it is more likely than not (i.e. more than 50%) that the fair value of a reporting unit is less than its carrying amount. Such qualitative factors may include the following: macroeconomic conditions, industry and market considerations, cost factors, overall financial performance and other relevant entity‑specific events. If the qualitative assessment determines that an impairment is more likely than not, then we perform a quantitative impairment test. In the quantitative analysis, the carrying amount of the reporting unit is compared with its fair value. When the fair value of a reporting unit exceeds its carrying amount, goodwill of the reporting unit is considered not to be impaired. When the carrying amount of a reporting unit exceeds its fair value, an impairment loss is recognized in an amount equal to the excess, not to exceed the carrying amount of goodwill, and is recorded in the consolidated statements of operations. We determine the fair value of our reporting units using an income approach with discounted cash flow models (“DCF”), as we believe forecasted cash flows are the best indicator of such fair value. A number of significant assumptions and estimates are involved in the application of the DCF model to forecast operating cash flows, including assumptions about discount rates, projected merchant power prices, generation, fuel costs and capital expenditure requirements. The undiscounted and discounted cash flows utilized in our long‑lived asset recovery, equity method investment, and goodwill impairment tests for our reporting units are generally based on approved reporting unit operating plans for years with contracted PPAs and historical relationships for estimates at the expiration of PPAs. All cash flow forecasts from DCF models utilize estimated plant output for determining assumptions around future generation and industry data forward power and fuel curves to estimate future power and fuel prices. We used historical experience to determine estimated future capital investment requirements. The discount rate applied to the DCF models represents the weighted average cost of capital (“WACC”) consistent with the risk inherent in future cash flows of the particular reporting unit and is based upon an assumed capital structure, cost of long‑term debt and cost of equity consistent with comparable independent power producers. The fair value that could be realized in an actual transaction may differ from that used to evaluate the impairment of our reporting units. The valuation of long-lived assets, equity method investments and goodwill for the impairment analyses is considered a level 3 fair value measurement, which means that the valuation of the assets and liabilities reflect management’s own judgments regarding the assumptions market participants would use in determining the fair value of the assets and liabilities. Fair value determinations require considerable judgment and are sensitive to changes in these underlying assumptions and factors. As a result, there can be no assurance that the estimates and assumptions made for purposes of an impairment test will prove to be accurate predictions of the future. Examples of events or circumstances that could reasonably be expected to negatively affect the underlying key assumptions and ultimately impact the estimated fair value of our reporting units may include macroeconomic factors that significantly differ from our assumptions in timing or degree, increased input costs such as higher fuel prices and maintenance costs, or lower power prices than incorporated in our long-term forecasts. (m) Accounts payable consists of amounts due to trade creditors related to our core business operations. These payables include amounts owed to vendors and suppliers for items such as fuel, maintenance, inventory and other raw materials. Other accrued liabilities include items such as income taxes, legal contingencies and employee-related costs including payroll, benefits and related taxes. (n) We use derivative financial instruments in the form of interest rate swaps and foreign exchange forward contracts to manage our current and anticipated exposure to fluctuations in interest rates and foreign currency exchange rates. We also separate the conversion option of certain convertible debentures from the host instrument and account for it as an embedded derivative liability as the conversion option is in a currency different from our functional currency. We have also entered into natural gas supply contracts and natural gas forwards or swaps to minimize the effects of the price volatility of natural gas, which is a significant operating cost. We do not enter into derivative financial instruments for trading or speculative purposes. Certain derivative instruments qualify for a scope exception to fair value accounting because they are considered normal purchases or normal sales in the ordinary course of conducting business. This exception applies when we have the ability to, and it is probable that we will deliver or take delivery of the underlying physical commodity. We have designated one of our interest rate swaps as a hedge of cash flows for accounting purposes. Tests are performed to evaluate hedge effectiveness and ineffectiveness at inception and on an ongoing basis, both retroactively and prospectively. Derivatives accounted for as hedges are recorded at fair value in the balance sheet. Unrealized gains or losses on derivatives designated as a hedge for accounting purposes are deferred and recorded as a component of accumulated other comprehensive (loss) income (“OCL”) until the hedged transactions occur and are recognized in earnings. The ineffective portion of the cash flow hedge, if any, is immediately recognized in earnings. Derivative financial instruments not designated as a hedge for accounting purposes are measured at fair value with changes in fair value recorded in the consolidated statements of operations. Derivative financial instruments under master netting arrangements are recorded net, when applicable, in the consolidated balance sheets. The following table summarizes derivative financial instruments that are not designated as hedges for accounting purposes and the accounting treatment in the consolidated statements of operations of the changes in fair value and cash settlements of such derivative financial instrument: Derivative financial instrument Classification of changes in fair value Classification of cash settlements Natural gas swaps Changes in fair value of derivative instrument Fuel expense Fuel purchase agreements Changes in fair value of derivative instrument Fuel expense Interest rate swaps Changes in fair value of derivative instrument Interest expense Convertible debenture conversion option Other expense (income), net NA Foreign currency forward contract Foreign exchange loss (gain) Foreign exchange loss (gain) (o) Income tax expense includes the current tax obligation or benefit and change in deferred income tax asset or liability for the period. We use the asset and liability method of accounting for deferred income taxes and record deferred income taxes for all significant temporary differences. Income tax benefits associated with uncertain tax positions are recognized when we determine that it is more‑likely‑than‑not that the tax position will be ultimately sustained. Refer to Note 16 for more information. (p) We recognize energy sales revenue on a gross basis when electricity and steam are delivered and capacity revenue when capacity is provided under the terms of the related contracts. PPAs, steam purchase arrangements and energy services agreements are long‑term contracts with performance obligations to provide electricity, steam and capacity on a predetermined basis. For certain PPAs determined to be operating leases, we recognize lease income consistent with the recognition of energy sales and capacity revenue. When energy is delivered and capacity is provided, we recognize lease income as a component of energy sales and capacity revenue. We sell the majority of the capacity and energy from our power generation projects under PPAs to a variety of utilities and other parties. Under the PPAs, which have expiration dates ranging from May 2020 to November 2043, we receive payments for electric energy sold to our customers (known as energy payments), in addition to payments for electric generation capacity (known as capacity payments). We also sell steam from a number of our projects to industrial purchasers under steam sales agreements. Sales of electricity are generally higher during the summer and winter months, when temperature extremes create demand for either summer cooling or winter heating. The following is a description of principal activities from which we generate our revenue. Products and services Nature, timing of satisfaction of performance obligations, and significant payment terms Energy Energy revenue is recognized upon transmission to the customer. Physical transactions, or the sale of generated electricity to meet supply and demand, are recorded on a gross basis in our consolidated statements of operations. The price of energy could be contracted under PPAs at set prices or merchant sales based on market merchant price. Energy revenue is also recognized under certain contracts for avoided generation during curtailment periods. Energy revenue is billed and paid on a monthly basis. Energy capacity Capacity revenues are recognized when contractually earned, and consist of revenues billed to a third party at a negotiated contract price under the applicable PPAs for making installed generation capacity available in order to satisfy reliability requirements or merchant capacity sales based on the market price for such capacity. Energy capacity is billed and paid on a monthly basis. Other revenue includes the following: Steam energy and capacity Steam revenue is recognized upon delivery to the customer. Steam capacity payments under the applicable PPAs are recognized as the amount billable under the respective PPA. Steam capacity is billed and paid on a monthly basis. Waste heat We generate electricity from excess steam provided by a nearby pipeline and its pumping station in the Solid Fuel segment. Waste heat is earned when it is generated and paid as a portion of monthly energy and capacity billing. Ancillary and transmission services We provide ancillary and transmission services to our customers under the terms of our PPAs. These services are billed and paid on a monthly basis. Asset management and operation, operation and maintenance We provide asset management and operation supervision to the Frederickson project, a facility that we jointly own with Puget Sound Energy. We also provide operation and maintenance services to several electric energy customers under the PPAs. All services are billed and paid on a monthly basis. Enhanced dispatch contracts Under certain contractual arrangements with our customers, we bill and are paid for not generating electricity. This revenue is recognized monthly under the terms of those agreements. Refer to Note 4 Revenue from contracts for disaggregation of revenue and further contract balance information. We have entered into PPAs to sell power at predetermined rates. PPAs are assessed as to whether they contain leases which convey to the counterparty the right to the use of the project’s property, plant and equipment in return for future payments. Such arrangements are classified as either capital or operating leases. PPAs that transfer substantially all of the benefits and risks of ownership of property to the PPA counterparty are classified as direct financing leases. For PPAs accounted for as operating leases, we recognize lease income consistent with the recognition of energy revenue due to variable volume of the generation. When energy is delivered, we recognize lease income in energy revenue. (q) Administrative expenses include corporate and other expenses primarily for executive management, finance, legal, human resources and information systems, which are not directly allocable to our business segments. (r) The local currency is the functional currency of our U.S. and Canadian projects. Our reporting currency is the U.S. dollar. Foreign currency denominated assets and liabilities are translated at end‑of‑period rates of exchange. Revenues, expenses, and cash flows are translated at the weighted‑average rates of exchange for the period. The resulting currency translation adjustments are not included in the determination of our statements of operations for the period, but are accumulated and reported as a separate component of shareholders’ equity until sale of the net investment in the project takes place. Foreign currency transaction gains or losses are reported within foreign exchange (gain) loss in our consolidated statements of operations. (s) The officers and certain other employees are eligible to participate in the Long‑Term Incentive Plan (“LTIP”). Notional units granted that are expected to be redeemed in cash upon vesting are accounted for as liability awards. Notional units granted that are expected to be redeemed in common shares upon vesting are accounted for as equity awards. Unvested notional units are entitled to receive dividends, if paid, equal to the dividends per common share during the vesting period in the form of additional notional units. Unvested units are subject to forfeiture if the participant is not an employee at the vesting date. We initially recognize compensation expense on the estimated number of notional units for which the requisite service is expected to be rendered. We have estimated a weighted average forfeiture rate of 11% for all notional unit grants under the LTIP. This estimate will be revisited if subsequent information indicates the actual number of notional units forfeited is likely to differ from previous estimates. Compensation expense related to awards granted to participants in the LTIP is recorded over the vesting period based on the estimated fair value of the award on the grant date for notional units accounted for as equity awards and the fair value of the award at each balance sheet date for notional units accounted for as liability awards. (t) The fair value for an asset retirement obligation is recorded in the period in which it is incurred. Retirement obligations associated with long‑lived assets are those for which a legal obligation exists under enacted laws, statutes, and written or oral contracts, including obligations arising under the doctrine of promissory estoppel, and for which the timing and/or method of settlement may be conditional on a future event. When the liability is initially recorded, we capitalize the cost by increasing the carrying amount of the related long‑lived asset. Over time, the liability is accreted to its present value each period and the capitalized cost is depreciated over the useful life of the related asset. Upon settlement of the liability, we either settle the obligation for its recorded amount or incur a gain or loss. (u) We offer pension benefits to certain employees through a defined benefit pension plan. We recognize the funded status of our defined benefit plan in the consolidated balance sheets in other long‑term liabilities and record an offset to other comprehensive (loss) income. In addition, we also recognize on an after‑tax basis, as a component of other comprehensive (loss) income, gains and losses as well as all prior service costs that have not been included as part of our net periodic benefit cost. The determination of our obligation and expenses for pension benefits is dependent on the selection of certain assumptions. These assumptions determined by management include the discount rate, the expected rate of return on plan assets, the rate of future compensation increases and retirement age. The assumptions used may differ materially from actual results, which may result in a significant impact to the amount of our pension obligation or expense recorded. (v) We account for our business combinations in accordance with the acquisition method of accounting, which requires an acquirer to recognize and measure in its financial statements the identifiable assets acquired, the liabilities assumed, and any noncontrolling interest in the acquiree at fair value at the acquisition date. It also recognizes and measures the goodwill acquired or a gain from a bargain purchase in the business combination and determines what information to disclose to enable users of an entity’s financial statements to evaluate the nature and financial effects of the business combination. In addition, transaction costs are expensed as incurred. (w) The financial instruments that potentially expose us to credit risk consist primarily of cash and cash equivalents, restricted cash, derivative instruments and accounts receivable. Cash and restricted cash are held by major financial institutions that are also counterparties to our derivative instruments. We have long‑term agreements to sell electricity, gas and steam to public utilities and corporations. We have exposure to trends within the energy industry, including declines in the creditworthiness of our customers. We do not normally require collateral or other security to support energy‑related accounts receivable. We do not believe there is significant credit risk associated with accounts receivable due to the credit-worthiness and payment history of our customers. See Note 22, Segment and geographic information , for a further discussion of customer concentrations. (x) The preparation of financial statements requires us to make estimates and assumptions that affect the reported amounts of assets and liabilities and disclosure of contingent assets and liabilities at the date of the financial statements and the reported amounts of revenue and expenses during the year. Actual results could differ from those estimates. During the periods presented, we have made a number of estimates and valuation assumptions, including the useful lives and recoverability of property, plant and equipment, valuation of goodwill, intangible assets and liabilities related to PPAs and fuel supply agreements, the recoverability of equity investments, the recoverability of deferred tax assets, tax provisions, the fair value of financial instruments and derivatives, pension obligations, asset retirement obligations, and the fair values of acquired assets and liabilities assumed. In addition, estimates are used to test long‑lived assets and goodwill for impairment and to determine the fair value of impaired assets. These estimates and valuation assumptions are based on present conditions and our planned course of action, as well as assumptions about future business and economic conditions. As better information becomes available or actual amounts are determinable, the recorded estimates are revised. Should the underlying valuation assumptions and estimates change, the recorded amounts could change by a material amount. (y) Accounting Standards Adopted in 2019 In February 2016, the FASB issued authoritative guidance intended to increase transparency and comparability among organizations by recognizing lease assets and liabilities on the balance sheet and disclosing key information about leasing arrangements. Under the new guidance, lessees are required to recognize a right-of-use asset and a lease liability, measured on a discounted basis, at the commencement date for all leases with terms greater than twelve months. Additionally, this guidance requires disclosures to help investors and other financial statement users to better understand the amount, timing, and uncertainty of cash flows arising from leases, including qualitative and quantitative requirements. Any leases that expired before the initial application date did not require any accounting adjustment. This guidance became effective for annual reporting periods beginning after December 15, 2018, including interim periods within those fiscal years, with early adoption permitted. We elected certain practical expedients permitted, including the expedient that permits us to retain our existing lease assessment and classification. The Company has elected not to apply the recognition requirements to short-term leases and not to separate non-lease components from associated lease components, for all classes of underlying assets. In July 2018, the FASB issued further authoritative guidance to provide an additional transition method to adopt the new lease requirements by allowing entities to initially apply the requirements by recognizing a cumulative-effect adjustment to the opening balance of retained earnings in the period of adoption. We elected this transition method. As the result of our adoption of the guidance, we recorded $6.4 million and $7.2 million of right-of-use assets and lease liabilities, respectively, in the consolidated balance sheets on January 1, 2019. We have no transitional adjustments to our opening retained earnings or our consolidated statements of operations. See Note 16, Leases for further information. In August 2017, the FASB issued authoritative guidance to align an entity’s risk management activities and financial reporting for hedging relationships through changes to both the designation and measurement guidance for qualifying hedging relationships and the presentation of hedge results. The guidance expands and refines hedge accounting for both nonfinancial and financial risk components and aligns the recognition and presentation of the effects of the hedging instrument and the hedged item in the financial statements. The guidance became effective for fiscal years beginning after December 15, 2018, with early adoption permitted. Adoption of this guidance did not impact the consolidated financial statements. In February 2018, the FASB issued authoritative guidance to allow a reclassification from accumulated other comprehensive income to retained earnings for stranded tax effects resulting from the Tax Cuts and |