Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Remove unnecessary CheckExceptionOccurred calls #1175

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 11 commits into from
Aug 15, 2020

Conversation

amos402
Copy link
Member

@amos402 amos402 commented Jul 2, 2020

What does this implement/fix? Explain your changes.

Fro saving unnecessary costs.

Does this close any currently open issues?

...

Any other comments?

...

Checklist

Check all those that are applicable and complete.

  • Make sure to include one or more tests for your change
  • If an enhancement PR, please create docs and at best an example
  • Add yourself to AUTHORS
  • Updated the CHANGELOG

@dnfadmin
Copy link

dnfadmin commented Jul 2, 2020

CLA assistant check
All CLA requirements met.

@codecov-commenter
Copy link

codecov-commenter commented Jul 2, 2020

Codecov Report

Merging #1175 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1175   +/-   ##
=======================================
  Coverage   86.25%   86.25%           
=======================================
  Files           1        1           
  Lines         291      291           
=======================================
  Hits          251      251           
  Misses         40       40           
Flag Coverage Δ
#setup_linux 64.94% <ø> (ø)
#setup_windows 72.50% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


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 2d2b297...8ca0a62. Read the comment docs.

@@ -758,7 +758,10 @@ private static bool ToPrimitive(IntPtr value, Type obType, out object result, bo
goto type_error;
}
double dd = Runtime.PyFloat_AsDouble(op);
Runtime.CheckExceptionOccurred();
if (dd == -1.0)
Copy link
Member

Choose a reason for hiding this comment

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

Knowing the funny behavior of floating-point comparisons, it would be good to have two test cases for this conversion passing and failing.

appveyor.yml Outdated
@@ -40,6 +40,7 @@ init:
install:
- python -m pip install -U pip
- pip install --upgrade -r requirements.txt --quiet
- pip install install pycparser --quiet
Copy link
Member

Choose a reason for hiding this comment

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

This looks wrong.

Copy link
Member Author

Choose a reason for hiding this comment

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

Yes, apparently it's wrong, never thought it works.😂
This line is due to requirements.txt declared won't pycparser be install on windows, but setup process need it.

@lostmsu
Copy link
Member

lostmsu commented Jul 30, 2020

I'd prefer the --no-index part to be a separate PR

@amos402
Copy link
Member Author

amos402 commented Aug 10, 2020

I'd prefer the --no-index part to be a separate PR

#1200

@filmor filmor merged commit 3e1fc2e into pythonnet:master Aug 15, 2020
@amos402 amos402 deleted the remove-redundant-calls branch August 19, 2020 17:26
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.

5 participants