{"action":"created","issue":{"url":"https://api.github.com/repos/magento/magento2/issues/5762","repository_url":"https://api.github.com/repos/magento/magento2","labels_url":"https://api.github.com/repos/magento/magento2/issues/5762/labels{/name}","comments_url":"https://api.github.com/repos/magento/magento2/issues/5762/comments","events_url":"https://api.github.com/repos/magento/magento2/issues/5762/events","html_url":"https://github.com/magento/magento2/issues/5762","id":167039143,"number":5762,"title":"Magento EE 2.1.0 'Configurable product \"%1\" does not have sub-products'","user":{"login":"etessari","id":10881108,"avatar_url":"https://avatars.githubusercontent.com/u/10881108?v=3","gravatar_id":"","url":"https://api.github.com/users/etessari","html_url":"https://github.com/etessari","followers_url":"https://api.github.com/users/etessari/followers","following_url":"https://api.github.com/users/etessari/following{/other_user}","gists_url":"https://api.github.com/users/etessari/gists{/gist_id}","starred_url":"https://api.github.com/users/etessari/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/etessari/subscriptions","organizations_url":"https://api.github.com/users/etessari/orgs","repos_url":"https://api.github.com/users/etessari/repos","events_url":"https://api.github.com/users/etessari/events{/privacy}","received_events_url":"https://api.github.com/users/etessari/received_events","type":"User","site_admin":false},"labels":[{"id":429635502,"url":"https://api.github.com/repos/magento/magento2/labels/2.1.x","name":"2.1.x","color":"fbca04","default":false},{"id":147131376,"url":"https://api.github.com/repos/magento/magento2/labels/bug%20report","name":"bug report","color":"d93f0b","default":false},{"id":374038437,"url":"https://api.github.com/repos/magento/magento2/labels/Catalog","name":"Catalog","color":"1d76db","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":31,"created_at":"2016-07-22T12:54:19Z","updated_at":"2016-11-25T16:18:22Z","closed_at":null,"body":"## Steps to reproduce\n1. Create configurable product with no simple products associated\n2. Associate product to category\n3. Save category\n## Actual result\n1. Exception: Configurable product \"%1\" does not have sub-products\n\nThe problem is with the method, cause the configurable product has no child:\n\n``` php\n<?php\nnamespace Magento\\ConfigurableProduct\\Pricing\\Price;\n\n/**\n     * @param \\Magento\\Framework\\Pricing\\SaleableInterface|\\Magento\\Catalog\\Model\\Product $product\n     * @return float\n     * @throws \\Magento\\Framework\\Exception\\LocalizedException\n     */\n    public function resolvePrice(\\Magento\\Framework\\Pricing\\SaleableInterface $product)\n    {\n        $price = null;\n        foreach ($this->configurable->getUsedProducts($product) as $subProduct) {\n            $productPrice = $this->priceResolver->resolvePrice($subProduct);\n            $price = $price ? min($price, $productPrice) : $productPrice;\n        }\n        if ($price === null) {\n            throw new \\Magento\\Framework\\Exception\\LocalizedException(\n                __('Configurable product \"%1\" does not have sub-products', $product->getSku())\n            );\n        }\n        return (float)$price;\n    }\n\n```\n"},"comment":{"url":"https://api.github.com/repos/magento/magento2/issues/comments/262990129","html_url":"https://github.com/magento/magento2/issues/5762#issuecomment-262990129","issue_url":"https://api.github.com/repos/magento/magento2/issues/5762","id":262990129,"user":{"login":"shiftedreality","id":3396658,"avatar_url":"https://avatars.githubusercontent.com/u/3396658?v=3","gravatar_id":"","url":"https://api.github.com/users/shiftedreality","html_url":"https://github.com/shiftedreality","followers_url":"https://api.github.com/users/shiftedreality/followers","following_url":"https://api.github.com/users/shiftedreality/following{/other_user}","gists_url":"https://api.github.com/users/shiftedreality/gists{/gist_id}","starred_url":"https://api.github.com/users/shiftedreality/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/shiftedreality/subscriptions","organizations_url":"https://api.github.com/users/shiftedreality/orgs","repos_url":"https://api.github.com/users/shiftedreality/repos","events_url":"https://api.github.com/users/shiftedreality/events{/privacy}","received_events_url":"https://api.github.com/users/shiftedreality/received_events","type":"User","site_admin":false},"created_at":"2016-11-25T16:18:22Z","updated_at":"2016-11-25T16:18:22Z","body":"Hi @etessari \r\n\r\nWe already have related ticket MAGETWO-60483  and the fix will be delivered soon.\r\nThanks."}}
{"actor":{"display_login":"shiftedreality"}}