Error when closing fiscal year

Bug #588776 reported by TeMPO
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Odoo Addons (MOVED TO GITHUB)
Status tracked in Trunk
5.0
Won't Fix
Medium
Unassigned
Trunk
Invalid
Medium
OpenERP R&D Addons Team 3

Bug Description

using 5.0.9

When closing a fiscal year (with the wizard_fisclayear_close.py module) onaccounts with
balance deferal method , the balance can be taken in account two times if account are not set
in a very specific way.

example taken from the french account_plan

10 Type= View
101000 TYpe=Other Deferal=Balance
101300 type=Other Deferal=Balance

The closing balance if 101300 shows 1000 and the closing balance of 101000 shows also 1000 (since it is the sum of what is
into 101000 (0) and what is in 101300 (1000)

WIth this configuration when closing the fiscal year an entry for both 101300 AND 101000 are created in the opening journal
After the closing 101300 has a balance of 1000 but 101000 has a balance of 2000.

To solve this beahviour just define 101000 as view type but the underlying problem is that you cannot pout entries in a
parent account and children account with balance deferal modes.

Maurice

Related branches

Revision history for this message
hbto [Vauxoo] http://www.vauxoo.com (humbertoarocha) wrote : Re: [Bug 588776] [NEW] Error when closing fiscal year

this bug is related to this bug

https://bugs.launchpad.net/bugs/560378

2010/6/2 TeMPO <email address hidden>

> Public bug reported:
>
> using 5.0.9
>
> When closing a fiscal year (with the wizard_fisclayear_close.py module)
> onaccounts with
> balance deferal method , the balance can be taken in account two times if
> account are not set
> in a very specific way.
>
> example taken from the french account_plan
>
> 10 Type= View
> 101000 TYpe=Other Deferal=Balance
> 101300 type=Other Deferal=Balance
>
> The closing balance if 101300 shows 1000 and the closing balance of 101000
> shows also 1000 (since it is the sum of what is
> into 101000 (0) and what is in 101300 (1000)
>
> WIth this configuration when closing the fiscal year an entry for both
> 101300 AND 101000 are created in the opening journal
> After the closing 101300 has a balance of 1000 but 101000 has a balance of
> 2000.
>
> To solve this beahviour just define 101000 as view type but the underlying
> problem is that you cannot pout entries in a
> parent account and children account with balance deferal modes.
>
> Maurice
>
> ** Affects: openobject-addons
> Importance: Undecided
> Status: New
>
> --
> Error when closing fiscal year
> https://bugs.launchpad.net/bugs/588776
> You received this bug notification because you are subscribed to
> OpenObject Addons.
>

Revision history for this message
TeMPO (info-tempo-consulting) wrote :

Dear hbto

it is related but also different
I was only pointing out that you can put entries in
a parent account and entries into the children (some customers of
mine do that)

Then the problem is that if these accounts have deferal mode=balance
the wizard for closing the fiscal year will duplicate some entries.

Regards

Maurice

> this bug is related to this bug
>
> https://bugs.launchpad.net/bugs/560378
>
>
> 2010/6/2 TeMPO <email address hidden>
>
>
>> Public bug reported:
>>
>> using 5.0.9
>>
>> When closing a fiscal year (with the wizard_fisclayear_close.py module)
>> onaccounts with
>> balance deferal method , the balance can be taken in account two times if
>> account are not set
>> in a very specific way.
>>
>> example taken from the french account_plan
>>
>> 10 Type= View
>> 101000 TYpe=Other Deferal=Balance
>> 101300 type=Other Deferal=Balance
>>
>> The closing balance if 101300 shows 1000 and the closing balance of 101000
>> shows also 1000 (since it is the sum of what is
>> into 101000 (0) and what is in 101300 (1000)
>>
>> WIth this configuration when closing the fiscal year an entry for both
>> 101300 AND 101000 are created in the opening journal
>> After the closing 101300 has a balance of 1000 but 101000 has a balance of
>> 2000.
>>
>> To solve this beahviour just define 101000 as view type but the underlying
>> problem is that you cannot pout entries in a
>> parent account and children account with balance deferal modes.
>>
>> Maurice
>>
>> ** Affects: openobject-addons
>> Importance: Undecided
>> Status: New
>>
>> --
>> Error when closing fiscal year
>> https://bugs.launchpad.net/bugs/588776
>> You received this bug notification because you are subscribed to
>> OpenObject Addons.
>>
>>
>
>

--
Très cordialement

Maurice MORETTI

_________________________________________________________________________
TeMPO CONSULTING Valparc 9, rue du Parc 67205 Oberhausbergen FRANCE

Web : http://www.tempo-consulting.fr
email : <email address hidden>

Tel : 33 (0)3 88 56 82 10
Fax : 33 (0)3 88 56 46 64
Mobile : 33 (0)6 08 61 85 02

Revision history for this message
Nhomar - Vauxoo (nhomar) wrote :
Download full text (4.2 KiB)

Hello Tempo.

For an accountant point of view "tottally incorrect", We in the
accounting-experts-mailing list dicuss this point some time ago, there are
no reasons for put moves lines in a parent view. I mean, you allways will
have at least one generic child when you need to put related move lines
(even for the process to open or close a period), I confirm if the closing
fiscal is putting moves in an account of type "view" i confirm this is a
bug. Every move should go in one selected child.

Thanks.

2010/6/3 TeMPO <email address hidden>

> Dear hbto
>
> it is related but also different
> I was only pointing out that you can put entries in
> a parent account and entries into the children (some customers of
> mine do that)
>
> Then the problem is that if these accounts have deferal mode=balance
> the wizard for closing the fiscal year will duplicate some entries.
>
> Regards
>
> Maurice
>
>
> > this bug is related to this bug
> >
> > https://bugs.launchpad.net/bugs/560378
> >
> >
> > 2010/6/2 TeMPO <email address hidden>
> >
> >
> >> Public bug reported:
> >>
> >> using 5.0.9
> >>
> >> When closing a fiscal year (with the wizard_fisclayear_close.py module)
> >> onaccounts with
> >> balance deferal method , the balance can be taken in account two times
> if
> >> account are not set
> >> in a very specific way.
> >>
> >> example taken from the french account_plan
> >>
> >> 10 Type= View
> >> 101000 TYpe=Other Deferal=Balance
> >> 101300 type=Other Deferal=Balance
> >>
> >> The closing balance if 101300 shows 1000 and the closing balance of
> 101000
> >> shows also 1000 (since it is the sum of what is
> >> into 101000 (0) and what is in 101300 (1000)
> >>
> >> WIth this configuration when closing the fiscal year an entry for both
> >> 101300 AND 101000 are created in the opening journal
> >> After the closing 101300 has a balance of 1000 but 101000 has a balance
> of
> >> 2000.
> >>
> >> To solve this beahviour just define 101000 as view type but the
> underlying
> >> problem is that you cannot pout entries in a
> >> parent account and children account with balance deferal modes.
> >>
> >> Maurice
> >>
> >> ** Affects: openobject-addons
> >> Importance: Undecided
> >> Status: New
> >>
> >> --
> >> Error when closing fiscal year
> >> https://bugs.launchpad.net/bugs/588776
> >> You received this bug notification because you are subscribed to
> >> OpenObject Addons.
> >>
> >>
> >
> >
>
> --
> Très cordialement
>
> Maurice MORETTI
>
> _________________________________________________________________________
> TeMPO CONSULTING Valparc 9, rue du Parc 67205 Oberhausbergen FRANCE
>
> Web : http://www.tempo-consulting.fr
> email : <email address hidden>
>
> Tel : 33 (0)3 88 56 82 10
> Fax : 33 (0)3 88 56 46 64
> Mobile : 33 (0)6 08 61 85 02
>
> --
> Error when closing fiscal year
> https://bugs.launchpad.net/bugs/588776
> You received this bug notification because you are subscribed to
> OpenObject.
>
> Status in OpenObject Addons Modules: New
>
> Bug description:
> using 5.0.9
>
> When closing a fiscal year (with the wizard_fisclayear_close.py module)
> onaccounts with
> balance deferal method , the balance can be tak...

Read more...

Revision history for this message
Nhomar - Vauxoo (nhomar) wrote :

Please we ned to review this behaviour.

Changed in openobject-addons:
assignee: nobody → OpenERP Accounting Experts (openerp-expert-accounting)
status: New → Confirmed
Revision history for this message
TeMPO (info-tempo-consulting) wrote :
Download full text (5.0 KiB)

Hello Nhomar

just to make it clear I did NOT say that the closing process
is putting moves in an account of type view; in fact I said the opposite
to avoid having moves in an account put it as view.

My problem is that if you put moves in a parent account and also in
children account
and it the accounts are both defined with a deferal method of Balance,
then the
parent account will have duplicate moves after the closing.

Regards

Maurice

> Hello Tempo.
>
> For an accountant point of view "tottally incorrect", We in the
> accounting-experts-mailing list dicuss this point some time ago, there are
> no reasons for put moves lines in a parent view. I mean, you allways will
> have at least one generic child when you need to put related move lines
> (even for the process to open or close a period), I confirm if the closing
> fiscal is putting moves in an account of type "view" i confirm this is a
> bug. Every move should go in one selected child.
>
> Thanks.
>
> 2010/6/3 TeMPO <email address hidden>
>
>
>> Dear hbto
>>
>> it is related but also different
>> I was only pointing out that you can put entries in
>> a parent account and entries into the children (some customers of
>> mine do that)
>>
>> Then the problem is that if these accounts have deferal mode=balance
>> the wizard for closing the fiscal year will duplicate some entries.
>>
>> Regards
>>
>> Maurice
>>
>>
>>
>>> this bug is related to this bug
>>>
>>> https://bugs.launchpad.net/bugs/560378
>>>
>>>
>>> 2010/6/2 TeMPO <email address hidden>
>>>
>>>
>>>
>>>> Public bug reported:
>>>>
>>>> using 5.0.9
>>>>
>>>> When closing a fiscal year (with the wizard_fisclayear_close.py module)
>>>> onaccounts with
>>>> balance deferal method , the balance can be taken in account two times
>>>>
>> if
>>
>>>> account are not set
>>>> in a very specific way.
>>>>
>>>> example taken from the french account_plan
>>>>
>>>> 10 Type= View
>>>> 101000 TYpe=Other Deferal=Balance
>>>> 101300 type=Other Deferal=Balance
>>>>
>>>> The closing balance if 101300 shows 1000 and the closing balance of
>>>>
>> 101000
>>
>>>> shows also 1000 (since it is the sum of what is
>>>> into 101000 (0) and what is in 101300 (1000)
>>>>
>>>> WIth this configuration when closing the fiscal year an entry for both
>>>> 101300 AND 101000 are created in the opening journal
>>>> After the closing 101300 has a balance of 1000 but 101000 has a balance
>>>>
>> of
>>
>>>> 2000.
>>>>
>>>> To solve this beahviour just define 101000 as view type but the
>>>>
>> underlying
>>
>>>> problem is that you cannot pout entries in a
>>>> parent account and children account with balance deferal modes.
>>>>
>>>> Maurice
>>>>
>>>> ** Affects: openobject-addons
>>>> Importance: Undecided
>>>> Status: New
>>>>
>>>> --
>>>> Error when closing fiscal year
>>>> https://bugs.launchpad.net/bugs/588776
>>>> You received this bug notification because you are subscribed to
>>>> OpenObject Addons.
>>>>
>>>>
>>>>
>>>
>> --
>> Très cordialement
>>
>> Maurice MORETTI
>>
>> _________________________________________________________________________
>> TeMPO C...

Read more...

Revision history for this message
Borja López Soilán (NeoPolus) (borjals) wrote :

At least on Spain and Portugal is not valid to put entries on parent accounts, you need to use a "leaf" account without children.

Revision history for this message
TeMPO (info-tempo-consulting) wrote : Re: [Bug 588776] Re: Error when closing fiscal year

I will check that for France
> At least on Spain and Portugal is not valid to put entries on parent
> accounts, you need to use a "leaf" account without children.
>
>

--
Très cordialement

Maurice MORETTI

_________________________________________________________________________
TeMPO CONSULTING Valparc 9, rue du Parc 67205 Oberhausbergen FRANCE

Web : http://www.tempo-consulting.fr
email : <email address hidden>

Tel : 33 (0)3 88 56 82 10
Fax : 33 (0)3 88 56 46 64
Mobile : 33 (0)6 08 61 85 02

Revision history for this message
Nhomar - Vauxoo (nhomar) wrote :

Hello Tempo.

Right, i understood your point, the problem for your case is not allow moves
in accoun with types == View, The especific problem is: It should not do
nothing whatever deferral method you choice, Is this right?.

My pointing is that the closing method IMHO shouldn't create any move
directly in account it mus calculate for you and make the respéctive move
usind the methods on accounting System, to avoid duplicate code, with this
behaviour we can see that is putting moves directly with out use the methods
creted befor this is a problem of design for this procedure, we invite to
discuss in depth this problem, because we are in the middle of year in mayor
of countries, when we will close the year in the near future everybody will
have problem with this....

Thanks ;-)

2010/6/3 Borja López Soilán (Pexego) <email address hidden>

> At least on Spain and Portugal is not valid to put entries on parent
> accounts, you need to use a "leaf" account without children.
>
> --
> Error when closing fiscal year
> https://bugs.launchpad.net/bugs/588776
> You received this bug notification because you are a direct subscriber
> of the bug.
>
> Status in OpenObject Addons Modules: Confirmed
>
> Bug description:
> using 5.0.9
>
> When closing a fiscal year (with the wizard_fisclayear_close.py module)
> onaccounts with
> balance deferal method , the balance can be taken in account two times if
> account are not set
> in a very specific way.
>
> example taken from the french account_plan
>
> 10 Type= View
> 101000 TYpe=Other Deferal=Balance
> 101300 type=Other Deferal=Balance
>
> The closing balance if 101300 shows 1000 and the closing balance of 101000
> shows also 1000 (since it is the sum of what is
> into 101000 (0) and what is in 101300 (1000)
>
> WIth this configuration when closing the fiscal year an entry for both
> 101300 AND 101000 are created in the opening journal
> After the closing 101300 has a balance of 1000 but 101000 has a balance of
> 2000.
>
> To solve this beahviour just define 101000 as view type but the underlying
> problem is that you cannot pout entries in a
> parent account and children account with balance deferal modes.
>
> Maurice
>
> To unsubscribe from this bug, go to:
> https://bugs.launchpad.net/openobject-addons/+bug/588776/+subscribe
>

Revision history for this message
TeMPO (info-tempo-consulting) wrote :
Download full text (3.4 KiB)

Dear Nhomar
> Hello Tempo.
>
> Right, i understood your point, the problem for your case is not allow moves
> in accoun with types == View, The especific problem is: It should not do
> nothing whatever deferral method you choice, Is this right?.
>
This is not my problem.
If the account is defined with view type , OpenERP will not make move
into that account
and this is correct.
The problem into wich I ran was related to the situation where you put
moves into a
parent account and moves into a child account. This can be done if both
accounts are not of
view type. (The question raised by somedy else is to know if that should
be allowed or not.)
When you close the fiscal year, if both accounts are defined as deferal
mode = balance
then the balance of the parent account will be false.(very easy to
reproduce)
> My pointing is that the closing method IMHO shouldn't create any move
> directly in account it mus calculate for you and make the respéctive move
> usind the methods on accounting System, to avoid duplicate code, with this
> behaviour we can see that is putting moves directly with out use the methods
> creted befor this is a problem of design for this procedure, we invite to
> discuss in depth this problem, because we are in the middle of year in mayor
> of countries, when we will close the year in the near future everybody will
> have problem with this....
>
So far the problem that I raised what the only one I was facing in my
context

Maurice
> Thanks ;-)
>
> 2010/6/3 Borja López Soilán (Pexego) <email address hidden>
>
>
>> At least on Spain and Portugal is not valid to put entries on parent
>> accounts, you need to use a "leaf" account without children.
>>
>> --
>> Error when closing fiscal year
>> https://bugs.launchpad.net/bugs/588776
>> You received this bug notification because you are a direct subscriber
>> of the bug.
>>
>> Status in OpenObject Addons Modules: Confirmed
>>
>> Bug description:
>> using 5.0.9
>>
>> When closing a fiscal year (with the wizard_fisclayear_close.py module)
>> onaccounts with
>> balance deferal method , the balance can be taken in account two times if
>> account are not set
>> in a very specific way.
>>
>> example taken from the french account_plan
>>
>> 10 Type= View
>> 101000 TYpe=Other Deferal=Balance
>> 101300 type=Other Deferal=Balance
>>
>> The closing balance if 101300 shows 1000 and the closing balance of 101000
>> shows also 1000 (since it is the sum of what is
>> into 101000 (0) and what is in 101300 (1000)
>>
>> WIth this configuration when closing the fiscal year an entry for both
>> 101300 AND 101000 are created in the opening journal
>> After the closing 101300 has a balance of 1000 but 101000 has a balance of
>> 2000.
>>
>> To solve this beahviour just define 101000 as view type but the underlying
>> problem is that you cannot pout entries in a
>> parent account and children account with balance deferal modes.
>>
>> Maurice
>>
>> To unsubscribe from this bug, go to:
>> https://bugs.launchpad.net/openobject-addons/+bug/588776/+subscribe
>>
>>
>
>

--
Très cordialement

Maurice MORETTI

_________________________________________________________________________
TeMPO CONS...

Read more...

Revision history for this message
Ferdinand (office-chricar) wrote :

IIRC it has been discussed and "decided" on the accounting expert list that no moves should be attached to views.
IMHO this must be valid for all structures (analytic account, product, stock location, budgets .....)

OpenERP must always respect the rule
view (node) = sum of leaves

Revision history for this message
Diabel NDAW (dndaw) wrote :

I have the same without putting something in the parent account. If this one has not the type "View", the closing wizard will duplicate entries (one by child with balance not null et the last on for the parent account with sum of child's balance as value !!
One example
Before Closing year
10 - Capital ==> 10 000 000 (type "view")
10100000 - Capital Social ==> 10 000 000 (type "other")
10130000 - Capital souscrit, appele.. ==> 10 000 000 (type "other")

After Closing Year
10 - Capital ==> 20 000 000 (type "view")
10100000 - Capital Social ==> 20 000 000 (type "other")
10130000 - Capital souscrit, appele.. ==> 10 000 000 (type "other")

As said, putting parent account's type as "View" can avoid this issue but all parents account can't be set as view type, customers must have possibility defining some hierachical specific accounts... for their own needs.
I think account, with a deferal method of balance, must be reported only if the account contains entries "account.move.lines" for the closing year.

Question : Does someone knows how the V6 release treat this issue ?

Revision history for this message
Tidiane Sy (BAAMTU) (tsy) wrote :

The balance returned by model account.account is an aggregation of child accounts balances. It is not correct to use it to write fiscal year opening entries. For each account we need to get the real move lines that are directly associated to the account.
Please see the patch attached

Changed in openobject-addons:
assignee: OpenERP Accounting Experts (openerp-expert-accounting) → Jay (OpenERP) (jvo-openerp)
importance: Undecided → Medium
Revision history for this message
Purnendu Singh (OpenERP) (purnendu-singh) wrote :

Hello TeMPO,

Thanks for your contribution Tidiane Sy (BAAMTU). We have fixed the problem in lp:~openerp-commiter/openobject-addons/trunk-dev-addons3-psi2

Revision No: 4592
Revision ID: <email address hidden>

Thanks

Revision history for this message
Mustufa Rangwala (Open ERP) (mra-tinyerp) wrote :

patch is not fully correct. kindly check again

Revision history for this message
qdp (OpenERP) (qdp) wrote :

hello everyone,

we decided not to apply the above patch but instead we will put a constraint like "if an account has children then it has to be of type='view'".

Indeed, the problem here is more generic and allowing this structure of chart of accounts (even with the patch) doesn't garantee at all that the other part of the accounting of OpenERP will work fine: it hasn't been build for such situations.

So we wiill soon (before v6) add the constraint depicted above on the account.account, but also on the account.account.template in order to detect the wrong configuration existing currently and fix it directly in the l10n_* modules by setting the type of parent account to 'view'.

Thanks for your contribution,
Quentin

Revision history for this message
qdp (OpenERP) (qdp) wrote :

Thus, as explained in my previous post we should consider this bug as invalid as such configuration will not be allowed anymore in a near future.

Revision history for this message
Tidiane Sy (BAAMTU) (tsy) wrote :

Hi Quentin,
I understand your point. This should be sufficient for next releases.
Anyway, if you want the fix for versions that do not have the constraint, you can find it on lp:~openerp-community/openobject-server/trunk-bugfix-588776
Revision No: 4198
Revision ID: <email address hidden>

Regards

Revision history for this message
Jay Vora (Serpent Consulting Services) (jayvora) wrote :

As discussed, I am closing the bug for stable.
Thanks.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.