Magento2: Error creating configurable products in 2.1.1

Created on 31 Aug 2016  路  73Comments  路  Source: magento/magento2

This was working fine in 2.1, but now in 2.1.1 there is an issue. When creating a configurable product, when you click into the "create configurations" menu, the first couple steps work fine. I am able to select the correct attribute, then select the values I want to apply, then on the next step, all the settings work fine (apply image to all products, apply custom quantities, ect), but when you go to click next, nothing happens, then when you click next again it skips over the summary step and goes back to the main product page. The configurable options show up there like it worked, but when you go to save the product the associated simple products are not saved.

Is Magento 2 still in testing or something. This is getting really frustrating.

Preconditions

Magento 2.1.1 oh PHP 7

Steps to reproduce

  1. Add new configurable product
  2. Fill out configurable product information and save
  3. Go to create configurations
  4. Select attribute set (in this case shirt size)
  5. Select attribute values (example Small, Medium, Large)
  6. Choose image for each, price for each, quantity for each
  7. Click Next to go to Summary (nothing happens)
  8. Click Next again and it skips summary and goes back to original configurable product page
  9. New associated simple products show up, but when you click save they are not actually created
  10. When you go back to the configurable product the simple associated products are gone as well

Expected result

  1. Expected result is for it to work like 2.1
  2. Create configurable product and save
  3. Click create configurations
  4. Select Attribute set
  5. Select Attribute Values you want to create
  6. Enter image/pricing/quantities for each associated product
  7. Hit next and go to summary
  8. Hit Next and have it actually create the associated products and keep them associated with the configurable product

Actual result

  1. Add new configurable product
  2. Fill out configurable product information and save
  3. Go to create configurations
  4. Select attribute set (in this case shirt size)
  5. Select attribute values (example Small, Medium, Large)
  6. Choose image for each, price for each, quantity for each
  7. Click Next to go to Summary (nothing happens)
  8. Click Next again and it skips summary and goes back to original configurable product page
  9. New associated simple products show up, but when you click save they are not actually created
  10. When you go back to the configurable product the simple associated products are gone as well

Please get Magento 2 working correctly, this thing is an absolute mess and my clients are pissed and I'm frustrated.

Catalog Ready for Work bug report

Most helpful comment

I have the same problem. I am also running 2.1.1 on PHP 7.0.9

Some additional information. If you regenerate your static files and make sure the file owner is the web server, then you will be able to "create" variants - but only on a clean install. I found the with Migrated databases the error is still present.

To make matters worse. If you edit the description of a configurable product (without touching configurations) it will then dis-associate all your variants on Save !!!!!

This is a massive, massive problem...... Configurable products is the backbone of Magento and its been broken in some-way since version 2.0

All 73 comments

I have the same problem. I am also running 2.1.1 on PHP 7.0.9

Some additional information. If you regenerate your static files and make sure the file owner is the web server, then you will be able to "create" variants - but only on a clean install. I found the with Migrated databases the error is still present.

To make matters worse. If you edit the description of a configurable product (without touching configurations) it will then dis-associate all your variants on Save !!!!!

This is a massive, massive problem...... Configurable products is the backbone of Magento and its been broken in some-way since version 2.0

I have same problem. Also I have upgraded to 2.1.1 and now when I save a configurable product, it removes the associated simple products. Is anyone testing these before releasing?

Same here - just tested with an upgraded version to 2.1.1.

Can anyone of the magento team pls check this.

I realized that a lot of new bugs appear on every update. Things that worked perfect in former versions now cause problems (fotorama bugs etc. etc.).

I think this must be a quality check problem on magento side. To me it appears as new features are implemented and not tested completely 馃憥
A feedback from magento side would be great.

@SewHappy58 a content manager in our shop also reported this after our 2.1.1 upgrade, but I am not able to reproduce it. neither using her account nor on a nightly backup - when I save the product, the associated simple products are kept...

we did some screen sharing sessions with our content manager to try to reproduce the problem. I was not able to find a pattern. most of the configurable products saved just fine after modifying their values, others would save but loose their associated products.

then one case we observed the product was saved ok, then immediately edited again due to a misspelled word in the description, and this second save removed the children.

it all seems pretty random to me at this point...

In our case, the configurable products children are loosing prices if you update the configurable product itself. In conclusion with every small change made, you'll have to mass update the associated simple products price.

Composer 2.1.1

@gewaechshaus if you're not using en_US as locale in the admin backend, you ran into issue #5973

Same issue here, if we edit a Configurable product it dissociates all simple products. This is a major issue, we have had to stop all further development, this needs addressing immediately.

It does seem more and more issues derive from upgrades. When upgrading to 2.1.0 I could not create an Invoice!
These are basic functionalities that should be tested. Don't run you tests on a clean install but run them upgraded install too!

@dapdx Thanks for reporting.
We've created internal ticket MAGETWO-58017 to fix it.

@picamator does MAGETWO-58017 also include the problem while saving a preexisting configurable product (and then losing the child asssociations) as discussed in the comments? if not, should a separate issue be opened?

@heldchen MAGETWO-58017 includes scenario about updating an existing configurable product.
Therefore, it does not need to create separate ticket.

thank you!

@picamator
Can i ask you a question regrading this topic?

We have seen bugs reported for month here and internal tickets created but nothing happened after this. Also in the new version 2.1.1 many bugs are not implemented.

Is there any timeline on this bug to be implemented.
We want to go online in a view weeks but with this bug it is simply not possible.

Many thanks!

If I was Magento I'd pull 2.1.1 down for downloading, this to me is a critical bug.... anyone who might not throughly test could get could ruining their production database.

I'd second that @rkhoury82, 2.1.1 is unusable if using configurable products.

@andidhouse we have put highly that particular issue and expect them to solve in a nearest patch releases.
So thank you all of your participation here. Please feel free to take next steps forward to become Magento 2 contributors.

Same issue here as well, after upgrade to 2.1.1 if you try to upload images to the configurable product the product is changed from Configurable to Simple Product!!!
Also on save the simple associated products are lost!!
On a clean 2.1.1 instance these issues are not happening, it is very strange how the upgrades are added to Magento, does anyone know a proper way to upgrade from old instances to the latest ones and how can we be sure that our site won't brake? Every time I upgraded had to revert because more problems appeared...

@ksz2013 simulate the upgrades on an identical copy of your sites and test test test. if everything works or is patched, upgrade the production instance...

I feel like more of a testing company then a company building working online-shops :-/.

I do not want to calculate the time we spent in testing and bug reporting - by for the worst experience so far for us. Hope this changes now. On a long term view we are not able to handle and support a software with that many new and existing bugs with every release.

So fingers crossed magento changes its policy here now and not later.

@andidhouse I hear you - our project is ~4 man-months overdue due to magento 2.x "quirks"

Same problem here.

I feel the pain guys as well. And I would pay to get these bugs dealt with to make this platform usable, as where it is right now, it is not. and the fact this is the CE channel as opposed to the EE, should not be the excuse here.

I think that this is the CE version should have nothing to do with it - if the ce version is gone i think magento has a much bigger problem ;-) Really hope this is changing now. Fingers crossed guys!

Can anyone provide an actual timeline for a fix? Ready to throw in the towel on this whole thing after this and the fotorama bug.

Hello. I'm working on MAGETWO-58017 but can't reproduce this issue, except saving configurable after upgrade only if browser data isn't cleaned after the upgrade. Try to empty browser data, cache and hard reload admin panel.
If anyone has some errors in logs caused by this issue please attach it here.

@andimov our content admin did that and switched even browsers. it seems to be happending random. she edited around 200 configurable parent products, around 30 of them were affected. some got damaged after the first save, some after a second or third. unfortunately no server/browser log errors when it happens.

I can reproduce everytime even with browser cache cleaned;
I can give u a copy of my database if you like ?

Hi, in the same time I got this error, I got also an 503 AJAX error on mui/renderer/index saying DOM couldn't be created, and a pop-up message saying an error occurs. Sending you screenshots in the evening.

@dapdx Did you try to clear cache? Did this help?

@heldchen, @rkhoury82
Looks like you have different issues.
@rkhoury82, please find something related to this issue in your log files and provide detailed steps to reproduce the issue.

@andimov Yes, clearing browser cache fixed this issue and I'm able to create configurable products again. Is there a way to relink configurable products to simple products? I had quite a few of them get messed up with this bug and get converted to simple products, and now I need to rebuild all of those items. It would be nice if I can just create the configurable products and relink them to the simple products that should be associated with them.

@andimov if old cached files would be the cause would enabling static file signing fix this, or is the brower's javascript local storage data part of the problem?

@dapdx you can. follow these steps:

  • edit the existing configurable product
  • create a new configuration in the "Configurations" section through the button
  • select the attribute(s) you want to have configurable
  • select any attribute value, does not matter which one
  • click through the wizard until you're back at the parent product
  • immediately click "Select > Remove Product" in the "Action" column of the newly "added" child product
  • there's an "Add Products Manually" button available now
  • use this to select the existing child products
  • save the parent product

@andimov I did a clean install using composer over my existing database and it works now.
Cleaning browser cache fixes the problem. Good news!

We're experiencing the same problem. We were able to create three configurable products, each with one or two attributes with several options, on a clean 2.1.1 install on a PHP7 server with varnish cache, without any problems. But the problem started when we tried to add child products to one of the configurable products by reconfiguring it. Clearing cache does not help us. Deleting the product and making a new one leads to the same problem. The parent product is saved all right but not the child products. We noticed that the third or fourth screen in the configuration of the product, with the overview of the to be generated child products, is missing. When you confirm, you do see the child products at first, but when you save the product they are gone. Please help!

We have just done a fresh install of 2.1.1 and it has fixed the problem for us too. Thanks @rkhoury82!

Hey @rkhoury82 and @fendowuk can you tell this novice how to go about installing a fresh copy of Magento over an existing DB without losing the data? I would really like to fix this problem, but I don't have a whole lot of experience with Magento. Thank you in advance for any help.

Hi RMA-web.

Download the files, either the whole package or via composer on to your website. I wont detail this, as i assume you already have done that before.

Then run the installer as if it was a fresh install.

When it asks for your database details, but your existing database details in there.

Make sure you use the same Admin username, password and email (or you will get an error)

Once finished, you might need to run: php bin/magento setup:upgrade to upgrade the DB (but can't remember).

You should regenerate your static files and compile commands to be sure.

hi @iTea2
Try doing the fresh install as above.
Unfortunately i haven't been able to full stress test this problem further. I was planning to see if it was address in the next point update.
Also issue #6167 stops me testing this further.
Rudi

Thank you @rkhoury82 will give this a shot.

Hi,
I have the same issue after upgrading from 2.1.0 to 2.1.1 via composer.
configurable products does not show anymore on frontend.
when i checked the exception log, this is what it shows me
[2016-09-21 08:23:25] main.CRITICAL: Magento\FrameworkException\LocalizedException: Configurable product "kit_pro" does not have sub-products in /var/www/vhosts/magento2.1.1/httpdocs/test123/vendor/magento/module-configurable-product/Pricing/Price/ConfigurablePriceResolver.php:65
Stack trace:

0 /var/www/vhosts/magento2.1.1/httpdocs/test123/vendor/magento/module-configurable-product/Pricing/Price/FinalPrice.php(43): Magento\ConfigurableProduct\Pricing\Price\ConfigurablePriceResolver->resolvePrice(Object(Magento\Catalog\Model\Product\Interceptor))

Attached a file
front end errors.txt
of errors displayed on frontend saying it does not have sub-products, but on the backend it has products associated with it. I tried clearing browser cache and reindexing it, did not resolve the issue.

@nmallepally it's probably a related but different issue: #6422

Similar issue here on 2.0.9
It does not disassociate simple products, but the configurable product is not appearing in category listing on frontend, and all simple product options are missing on product page.

Hi,

2.1.1
When the adminhtml product edit form catch an error, for example required field missing, if you click on "save" button, after reloading, the link with simple products is lost in table catalog_product_relation

I have updated several configurable product programmatically - meta data, descriptions etc.
All configurable products have lost the connection with their children...

I have the same problem. Children products disasociated from paren configurable product.

That's a big pain in the ass... We still don't know what to do. 6 months from the first issue and anybody knows wheres the bug... So sad.... :-1:

Hi Guys,

All of you having this error, please, downgrade your php version from 7.0 to 5.6.x. I faced the same issue and now its working fine after downgrading the php version.

running magento2 on 5.6 is just too slow and not really an option.

This is fixed now in 2.1.3

The issue is fixed in develop.

We are still seeing this issue in 2.1.5. Has anyone found a fix?

@maksek Can we get references to the commits?

@dapdx, @Ctucker9233, you can find fix here 4c4a4a2ab9002d76a3356ef49f81b20e4ca5b740

I am having the same problem in 2.1.4...

This is still an issue for me as well. I cannot have a product with more than 19 configurations! Can someone please put in some sort of update on this issue or when it will be released?

I am having the same problem in 2.1.5 when use PHP 7.0.x

Version 2.1.3-error has not been fixed-VERY FRUSTRATING!

This is still an issue with version 2.1.6

re Magento2 products not showing front end
Hi I had a similar problem. Using collar size as an attribute I used for example 16 16.5 17 and so on.
I recalled that when using 1.7 I could not use " for inches I used in instead.
Changing the collar size in simple products fixed it and the product then appeared on the front end.

Issue still present on version 2.1.6

This is still an issue for 2.1.7. It was very embarrassing for this bug to come up during a demo with one of my clients. I hope a fix is coming up soon.

This bug will/might be fixed in 2.2. The 2.1 Version only receives security fixes. For client demos we use 2.2 ;-)

i am not shure but not fixing a major bug since over 10 month from magento side... if it is fixed in 2.2 ok - but then it is 12 month and i think all agree that this is a time period nobody can work with.

Hi @SchumacherFM, is that official?

The 2.1 Version only receives security fixes.

Is there some kind of public announcement you could reference in that regard?

@korostii - i think you will not revceive a public announcement regarding this. There are over 2K issues reported here (maybe 200-300 are really bugs) and i think magento has no interest at all to communicate that 2.1 is only getting security updates.

In my opinion the magento communication should be more developer centered - not marketing centered.

@SchumacherFM I've got an application that is ready to launch, with the exception of this blocker. Is there a known temporary fix or a stable version I can downgrade to? If you're using 2.2 for demos, which version are you using in production?

This seems to be an issue with decimal points in some of the custom options. Try and drop any of those before downgrading.

@Caryyon After extensive testing, it seems the issue may be related to the size of the request, not the values of each attribute. I was able to create product variations using single attributes at a time. When I attempted to generate the variations using the two larger attributes (most values), the request failed.

Failed Attempt: size (5 values) and color (9 values)

The following request returned a 404 status.

POST  /catalog/product/validate/id/{id}/type/configurable/store/{id}/set/{id}/key/{key}/?isAjax=true

Successful Attempt: size (5 values) and quality (2 values)

The following request returned a 200 status.

 POST catalog/product/validate/id/{id}/type/configurable/store/{id}/set/{id}/key/{key}/?isAjax=true

The only notable difference between these two requests is the size of the configurable-matrix-serialized parameter sent in the POST request.

Findings

  1. In the failed request, the parameter contained 39561 characters. While in the successful request, it contained 16745 characters.
  2. In the failed request, the controller was never executed.
  3. In the successful request, the controller was executed. Upon receiving a response, the page reloaded as expected, whereas the failed request returned a 404 and did not reload the page.

I'm looking into bypassing the validation to see if the variations will still save.

Quick update, it turns out the issue I addressed in my previous post was related to a firewall on my hosting provider's end.

Can't reproduce this issue on 2.1.7.

Creating a configurable product in Magento 2 is a long process so maybe you are missing any step. Here's a simple and detailed guide: Configurable product Magento 2.

Internal ticket for ver. 2.1 - MAGETWO-59501
It was fixed already and fix will be available in one of the nearest releases.

@antboiko this shows as solved but I still have the same problem in magento.2.2.4.

Was this page helpful?
0 / 5 - 0 ratings