Skip to content

fix: fixes #76, adding more error checking and unifying calculation returns #86

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

Merged
merged 1 commit into from
Sep 9, 2021

Conversation

LouisBrunner
Copy link
Contributor

Remove the FK's fk_type, add more error checking following 4.0.0's new calculation error format, make nudge/rotate/IK consistent in their return format.

This is a breaking change.

@LouisBrunner LouisBrunner force-pushed the feature/better_calc branch 2 times, most recently from 56189a8 to 7972d44 Compare August 18, 2021 15:43
Copy link
Contributor

@tallpress tallpress left a comment

Choose a reason for hiding this comment

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

LGTM, one nit/small suggestion

@@ -500,8 +526,7 @@ def calc_inverse_kinematics(self, guess, target_position, target_orientation, tc

if r.status_code != 200:
eva_error('inverse_kinematics error', r)
return r.json()

return self.__check_calculation(r, 'calc_inverse_kinematics', 'ik')['joints']
Copy link
Contributor

Choose a reason for hiding this comment

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

for this 'calc_inverse_kinematics' and similar 'calc_forward_kinematics', 'calc_nudge' and 'calc_rotate' could use <function>.__name__?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

You mean like this?

return self.__check_calculation(r, self.calc_inverse_kinematics.__name__, 'ik')['joints']

Copy link
Contributor

Choose a reason for hiding this comment

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

I meant like that yea, but now you typed it out seems a bit much ado about nothing... lol. Maybe enum would be nicer 🤷‍♂️. But I don't think this is important

tallpress
tallpress previously approved these changes Sep 9, 2021
@codecov-commenter
Copy link

codecov-commenter commented Sep 9, 2021

Codecov Report

Merging #86 (53d747d) into development (4ecbc82) will decrease coverage by 0.00%.
The diff coverage is 16.66%.

Impacted file tree graph

@@               Coverage Diff               @@
##           development      #86      +/-   ##
===============================================
- Coverage        34.40%   34.40%   -0.01%     
===============================================
  Files               11       11              
  Lines              805      808       +3     
  Branches           126      126              
===============================================
+ Hits               277      278       +1     
- Misses             520      522       +2     
  Partials             8        8              
Impacted Files Coverage Δ
evasdk/eva_http_client.py 19.94% <16.66%> (+0.11%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 4ecbc82...53d747d. Read the comment docs.

@LouisBrunner LouisBrunner merged commit 32ea050 into development Sep 9, 2021
@LouisBrunner LouisBrunner deleted the feature/better_calc branch September 9, 2021 12:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants