Jump to content

The precision of the currency change itself (9 decimals instead of 2)


anapnd

Recommended Posts

Hello,

I have Prestashop 1.7.7.8. There's a bug that happened twice on my website on july the 24 and today : the precision of the currency decimals changed on its own. The price becomes 23,120000000 € on the front instead of 23,12 €

I've seen Prestashop logs and no one touched the currency part. I have a module with more precised logs and there's no sign of changing it either. Plus only the administrators have access to the currency part and we are 2, one in vacation and myself. We didn't touch that part.

When I corrected the decimal from 9 to 2, the log appeared for that in my name so that is something that is logged.

Did someone already have this problem? Do you know if a particular module can cause the decimal to change on its own?

Does someone have a clue of what can cause that?

 

Link to comment
Share on other sites

On 8/30/2022 at 4:09 PM, Nickovitshj said:

Can you check the code/html and database on that?
See how it's configured there?

Thank you for your answer.

I've checked them. That's not the code that has the problem. When it happens, I find the precision set to 9 on the database (ps_currency) and thus on the back-office too on Localization > Currency > Euro (because it comes from the database). I then change it to 2 on the back-office and the database update itself as it should.

The problem is that I don't know why and how this integer changes itself. I excluded the humans because no one has access to it and the logs doesn't display any change on the back-office. Also, there's no related event at the hours it happened. There's no module scheduled task.

I've searched on the code of every module if one of it changes this variable but none does that. I don't have any module about currency, even the prestashop one is disabled.

I wanted to know if anyone can relate to this problem and maybe has found the code, action or module that causes that.

 

Edit 02/09/22 : It happened again this morning.

Edited by anapnd (see edit history)
Link to comment
Share on other sites

  • 4 weeks later...

Hi, I have the same problem, decimals change themselves to 9 zeros, it happened 3 times already! I'm the only person doing back office and it's not me doing it. It starts happening after updating to the 1.7.8.7 version.

My shop uses 4 currencies and it happens only with the default one.

Does anyone have a solution for how to fix it as its not look good on the front page when is happening?

Link to comment
Share on other sites

On 9/21/2022 at 4:41 PM, mageek said:

Hi, I have the same problem, decimals change themselves to 9 zeros, it happened 3 times already! I'm the only person doing back office and it's not me doing it. It starts happening after updating to the 1.7.8.7 version.

My shop uses 4 currencies and it happens only with the default one.

Does anyone have a solution for how to fix it as its not look good on the front page when is happening?

I still haven't found out why it happens. Someone on a Prestashop Facebook Group has the same problem as us. She hasn't got the same modules as mine. The hours it happened aren't the same as mine so I excluded a Prestashop module doing something externaly.

It happened the 24/07/22, the 25/08/22, the 02/09/22, the 05/09/22 and the 14/09/22 for me.

Let's see if we have other clues on the next time...

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...