Skip to content
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

Filter out resources with blank physical_resource_id #113

Conversation

Ladas
Copy link
Contributor

@Ladas Ladas commented Oct 11, 2017

Filter out resources with blank physical_resource_id.
Before we were ignoring those with:
https://github.com/Ladas/manageiq-providers-openstack/blob/d0799c4a5766650f2d3d149875c1b58f8a16040f/app/models/manageiq/providers/openstack/refresh_parser_common/orchestration_stacks.rb#L165

Without ignoring thise results in error :
[NoMethodError]: undefined method `ems_ref=' for nil:NilClass Method:[block in method_missing]

@Ladas Ladas added the bug label Oct 11, 2017
@Ladas Ladas requested review from aufi and mansam October 11, 2017 15:47
@Ladas Ladas force-pushed the filter_out_resources_without_physical_resource_id branch from 8fe9503 to 4b18799 Compare October 11, 2017 15:58
@@ -173,6 +173,8 @@ def orchestration_stack_resources(stack, stack_inventory_object)
raw_resources.reject! { |r| r.physical_resource_id.nil? }
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There's already a check on this line for nil, just like in the old refresher. I'm guessing it should be changed to a check for blank?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hum, you might be right

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Ladas Ladas force-pushed the filter_out_resources_without_physical_resource_id branch 2 times, most recently from 26b632b to 258732c Compare October 11, 2017 16:28
Filter out resources with no physical_resource_id.
Before we were ignoring those with:
https://github.com/Ladas/manageiq-providers-openstack/blob/d0799c4a5766650f2d3d149875c1b58f8a16040f/app/models/manageiq/providers/openstack/refresh_parser_common/orchestration_stacks.rb#L165

Without ignoring thise results in error :
[NoMethodError]: undefined method `ems_ref=' for nil:NilClass  Method:[block in method_missing]
@Ladas Ladas changed the title Filter out resources with no physical_resource_id Filter out resources with blank physical_resource_id Oct 11, 2017
@Ladas Ladas force-pushed the filter_out_resources_without_physical_resource_id branch from 258732c to b89f7ab Compare October 11, 2017 16:29
@miq-bot
Copy link
Member

miq-bot commented Oct 11, 2017

Checked commit Ladas@b89f7ab with ruby 2.3.3, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 0 offenses detected
Everything looks fine. 🍰

@mansam
Copy link
Contributor

mansam commented Oct 11, 2017

💯 🚀 LGTM

@mansam
Copy link
Contributor

mansam commented Oct 11, 2017

@tzumainn tzumainn merged commit 08eb876 into ManageIQ:master Oct 11, 2017
@aufi aufi added this to the Sprint 71 Ending Oct 16, 2017 milestone Oct 17, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants