Voting starts in March for the Drupal Association Board election.
I created a drupal e-commerce using Commerce Kickstarter (v. 7.x-1.10) profile on my local machine (Debian wheezy php 5.4.4-7) with Corporateclean theme.
Then i moved on the production machine (Debian squeeze php 5.3.3-7+squeeze14) performing few database search&replace (domain name changed, for example, but nothing about prices/amount/numberformat).
Now, in the production machine, the prices's amount get saved correctly in the database (integer, 2 decimal, e.g. 1499 for 14,99$), the problem comes when the prices are showed: looks like they pass throught a number_format function and for 14.99 i get 14.9900000000000002.
I used mymodule_form_commerce_product_ui_product_form_alter() to do some debug, and:
$form['commerce_price']['und']['#entity']->commerce_price['und']['amount'] = 1499
$form['commerce_price']['und'][amount]['#default_value'] = 14.9900000000000002
This is a big problem becose, for example, break down Paypal payment method (14.9900000000000002 is not a valid amount).
Another thing I noticed, is that the price doesnt show in the 'Add to Cart' form, but when the prices are showed to the user (in the cart, checkout page, order, etc..) they are all right: looks like this issue happen only when the amount is converted from integer to floating (e.g. when editing the product, when calculating the amounts for the payment method)
I tryed to reproduce the problem moving another site (that is very similar, same base-theme, same modules, same installation profile [kickstarter], same hosting's php settings, etc..) from the local machine to the production one, and again throught the search&replace db, but nothing, the problem does not happen again.
I havent made any "brute-force" edit to modules.
The theme (corporateclean) doesnt have theming funciton about prices/amounts, neither do my custom module (that i tryed to disable too)
I tryed both with and w/ taxes.
I dont have custom pricing rules (by the way, this problem happen even in the product's edit page, so nothing to do with pricing rules).
I really dont know how to debug further; Where can i look to see why is this happening?
p.s: i know that testing and deployng on different machines with different SO and php version is really a bad practice, but this is what the company gave me -.-