Construction in progress (construction)#
One signature and one documentation text are shared by every maker listed at the end of this page. The call is shown for co.bs.construction; the other kinds take the same arguments.
- co.bs.construction(name, spend, complete_at=None, life=None, *, opening=None, category='Depreciation expense', actuals=None)#
Add construction in progress, depreciated straight-line once it is complete.
The line’s value is the balance at the end of each period: the opening balance, the spend, and any capitalized interest, less depreciation after completion. Without
complete_atthe balance stays in construction in progress.- Parameters:
- namestr
Asset name; required. It must be unique among the lines of this kind in the entity.
- spendscalar, Quantity, Series, or dict
Spend in each period, in the entity’s currency per period; cash pays it. A dict maps period labels, indices, or dates to amounts and spends 0 in the other periods.
- complete_atint, str, or date, optional
Period in which construction completes. Depreciation starts in this period, on the balance at the end of the period before it.
- lifeQuantity or Unit, optional
Useful life from completion as a time such as
5 * b.year; required withcomplete_at, and must be positive.- openingscalar, Quantity, Series, or dict, optional
Opening balance before the first period, in the entity’s currency.
- categorystr, default=”Depreciation expense”
Label stored as
LineItem.categoryon the depreciation expense line.- actualsdict, optional
Historical carrying amounts for periods up to
Model.actual_until, as{period: amount}. RequiresModel(..., actual_until=...).
- Returns:
- LineItem
The construction line, valued at its balance. Its
balanceattribute is the same series; withcomplete_at, itsdepreciationattribute is the depreciation expense line.
- Raises:
- TypeError
At construction, if
complete_atis given withoutlife, or an amount has a type boki cannot use in an expression.- ValueError
At construction, if a line with this name already exists for this kind or
lifeis not positive.- UnitError
At construction, if an amount is in a unit other than the entity’s currency, or
lifeis not a time.- IndexError
At evaluation, if
complete_atgiven as a label or date, or a period ofspend, is outside the model timeline.
Notes
The documentation of each maker starts this section with the maker’s kind, its side, and the section and cash-flow class of the kind; the layout pages list them.
Spending debits the line and credits cash. Depreciation after completion is the balance at the end of the period before
complete_at, times the period length overlife, never more than the balance, and is booked in the layout’s depreciation kind, whichco.depreciationcounts. Interest fromco.bs.loancan be added to the cost withcapitalize_into. See the construction row.Examples
Spend 100 in each of the first two months, complete the asset in the third, and depreciate it over a year:
>>> import boki as b >>> m = b.Model("Plant", start="2027-01", periods=4, step=b.month) >>> co = m.entity("A", standard=b.IFRS) >>> co.bs.opening(cash=1000) >>> plant = co.bs.construction("Plant", {0: 100, 1: 100}, complete_at=2, life=1 * b.year) >>> r = m.render() >>> [round(r.value(plant, month), 2) for month in ("2027-01", "2027-02", "2027-03", "2027-04")] [100.0, 200.0, 183.33, 166.67]
Makers that use this template#
IFRS general:
co.bs.constructionUS GAAP general:
co.bs.constructionJ-GAAP general:
co.bs.construction