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

Add Try-catch for Framing element design properties ensuring Bar pull does not crash #487

Merged

Conversation

Martian42
Copy link
Contributor

@Martian42 Martian42 commented Feb 23, 2022

Try catch is added around the if statement that causes the pulling method to crash in Grasshopper when pulling Robot model.

It is encouraged to review and update FramingElementDesignProperties in the future.

NOTE: Depends on

Issues addressed by this PR

Closes #

Test files

Changelog

Additional comments

See issue in LINK

First issue.

This is to avoid crashing when pulling Robot model
@Martian42 Martian42 added the type:bug Error or unexpected behaviour label Feb 23, 2022
@Martian42 Martian42 self-assigned this Feb 23, 2022
Copy link
Contributor

@IsakNaslundBh IsakNaslundBh left a comment

Choose a reason for hiding this comment

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

Would put the try catch around all the contents of this for loop, not just this part, to make sure we do not end up with a similar situation for other framing properties. This is, from line 45 all the way down to line 155.

@IsakNaslundBh
Copy link
Contributor

IsakNaslundBh commented Feb 23, 2022

Or, actually, at least covering all that are trying to extract the properties. This is from current position down to line 148

Try and catch moved to include the entire script
@Martian42
Copy link
Contributor Author

Or, actually, at least covering all that are trying to extract the properties. This is from current position down to line 148

@IsakNaslundBh try and catch has been updated as suggested.

Copy link
Contributor

@IsakNaslundBh IsakNaslundBh left a comment

Choose a reason for hiding this comment

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

LGTM as an initial fix to make sure things does not crash.

For #486 to be resolved properly in upcoming PRs.

@IsakNaslundBh
Copy link
Contributor

@BHoMBot check compliance
@BHoMBot check required

@bhombot-ci
Copy link

bhombot-ci bot commented Feb 24, 2022

@IsakNaslundBh to confirm, the following checks are now queued:

  • code-compliance
  • documentation-compliance
  • project-compliance
  • branch-compliance
  • dataset-compliance
  • copyright-compliance
  • code-compliance
  • documentation-compliance
  • project-compliance
  • core
  • null-handling
  • serialisation
  • versioning
  • installer

@bhombot-ci
Copy link

bhombot-ci bot commented Feb 24, 2022

The check code-compliance has already been run previously and recorded as a successful check. This check has not been run again at this time.

@IsakNaslundBh IsakNaslundBh changed the title Update FramingElementDesignProperties.cs Add Try-catch for Framing element design properties ensuring Bar pull does not crash Feb 24, 2022
@IsakNaslundBh
Copy link
Contributor

@BHoMBot check ready-to-merge

@bhombot-ci
Copy link

bhombot-ci bot commented Feb 24, 2022

@IsakNaslundBh to confirm, the following checks are now queued:

  • ready-to-merge

There are 11 requests in the queue ahead of you.

@IsakNaslundBh IsakNaslundBh merged commit 4424494 into main Feb 24, 2022
@IsakNaslundBh IsakNaslundBh deleted the Add-try-and-catch-around-FramingElementDesignProperties branch February 24, 2022 12:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug Error or unexpected behaviour
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants