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

Do not fail if the method is not defined on the topology graph #1221

Merged
merged 1 commit into from May 2, 2017

Conversation

jkremser
Copy link
Member

@jkremser jkremser commented May 2, 2017

This is a hot-fix for https://bugzilla.redhat.com/show_bug.cgi?id=1446822

Before: 😹 😒 ☁️

screenshot from 2017-05-02 15-41-15

After: πŸ¦„ 🌈 β˜€οΈ

screenshot from 2017-05-02 15-44-01

If the model/relationships for topology graph is not specified well it might fail with this error:

[----] F, [2017-04-28T19:05:32.796056 #2206:3fe951523850] FATAL -- : Error caught: [NoMethodError] undefined method `host' for #<ManageIQ::Providers::Kubernetes::ContainerManager::Container:0x007fd2ad585098>
/opt/rubies/ruby-2.3.1/lib/ruby/gems/2.3.0/gems/activemodel-5.0.2/lib/active_model/attribute_methods.rb:433:in `method_missing'
/opt/rubies/ruby-2.3.1/lib/ruby/gems/2.3.0/bundler/gems/manageiq-ui-classic-70ba36ca1c67/app/services/topology_service.rb:69:in `block in map_to_graph'

Let's make it more robust.

@miq-bot assign @skateman
@miq_bot add_label bug, topology, blocker
/cc @abonas @theute

@miq-bot
Copy link
Member

miq-bot commented May 2, 2017

Checked commit jkremser@c1a1213 with ruby 2.2.6, rubocop 0.47.1, and haml-lint 0.20.0
1 file checked, 0 offenses detected
Everything looks fine. ⭐

Copy link
Member

@skateman skateman left a comment

Choose a reason for hiding this comment

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

LGTM

@dclarizio dclarizio assigned dclarizio and unassigned skateman May 2, 2017
@dclarizio dclarizio merged commit 4bb1d23 into ManageIQ:master May 2, 2017
@dclarizio dclarizio added this to the Sprint 60 Ending May 8, 2017 milestone May 2, 2017
@jkremser jkremser deleted the topology-safe-call branch May 2, 2017 15:58
@abonas
Copy link
Member

abonas commented May 2, 2017

@miq-bot add_label topology

@simaishi
Copy link
Contributor

simaishi commented May 2, 2017

@Jiri-Kremser This part of the code was refactored in #1171, which is fine/no, and there is conflict backporting. Please resolve conflict and create a Fine specific PR (referencing this one).

@Fryguy
Copy link
Member

Fryguy commented May 2, 2017

@skateman, this PR depends on #1171. Would you feel comfortable with that one being backported? cc @himdel

@skateman
Copy link
Member

skateman commented May 2, 2017

@Fryguy , I'd rather create a different darga PR, give me a sec.

skateman added a commit to skateman/manageiq-ui-classic that referenced this pull request May 2, 2017
@skateman
Copy link
Member

skateman commented May 2, 2017

@simaishi here it is #1226

@jkremser
Copy link
Member Author

jkremser commented May 2, 2017

@skateman thanks for the PR πŸ‘ , I was already afk

@simaishi
Copy link
Contributor

simaishi commented May 3, 2017

Backported to Fine via #1226

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants