-
Notifications
You must be signed in to change notification settings - Fork 9.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Error on checkout page when empty region field #7387
Comments
Affecting all UK checkouts, and any countries without preset regions. Needs urgent attention. |
We now have 3 clients directly affected by this and it's holding up their go live. Can we get a view on when this will be resolved? |
@ankitce please, format this issue according to the Issue reporting guidelines: with steps to reproduce, actual result and expected result. |
We are experiencing same issue on Magento EE 2.0.10 - but I believe this is not related to EE and same thing will happen with CE |
@veloraven - adding this on behalf of other users experiencing this issue.
Steps to Reproduce
Expected Result Actual Result Additional Information I'm aware the save function has been deprecated and will be replaced with EntityManager functions. I don't believe this refactor has extended to the shipping address as yet. This same save function is being used inside core code on Shipping Address in Magento\Quote\Observer\Frontend\Quote\Address\VatValidator::validate function around line 73. |
@wsagen thank you for details! |
@SerhiyShkolyarenko - I realise the checkout works without my test extension - because the core code statement causing the bug is not executed during this flow. The same call is made during checkout when VAT ID validation is enabled in some instances - I have not seen steps here that will reliably reproduce it every time. |
Further to this, if extension code exposes issues with core code, this needs to be supported. At present this code is not extensible. |
@SerhiyShkolyarenko We have given you some code which reliably reproduces the issue. Its now down to you to fix it. Magento is a platform, its designed to be extended, you are writing code that can't be extended. Please just fix the issue, going back/forth like this is ridiculous. |
@wsagen you used direct model saving($address->save()) which is deprecated. Please look at |
I temporarily bypassed this bug: In Search line 2920
Replace by
|
@DogSports do you have the steps to reproduce on the clean magento installation? |
We had this issues several months ago and implemented a work around. We created a module that extends the affected file and took advantage of magento 2's dependency injection to resolve it to the new class. You can find the module here: https://github.com/gloong/module-quote |
@gloong how can I reproduce it on my instance? What are the steps for clean magento? |
Importing Regions for the UK Resolves the issue, query as follows:- INSERT INSERT |
Note to contributors; if you would like to recreate the issue, delete all records from directory_country_region and directory_country_region_name. This will then recreate the issue for any country, as all region data for all countries would be missing. As a recoverable error shouldn't the query cater for the absence of the region data? |
Reopened #12436 |
We have this issue in Magento 2.3.6. I guess core fix is the way then. |
Error message:
Recoverable Error: Object of class Magento\Customer\Model\Data\Region could not be converted to string in /vendor/magento/framework/DB/Adapter/Pdo/Mysql.php
The checkout page halts after this error.
Originally reported issue - #4187
Steps to reproduce: #4187 (comment)
The text was updated successfully, but these errors were encountered: