Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix Re-initialization#343

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
vmuriart merged 2 commits intopythonnet:masterfromfilmor:fix-shutdown
Jan 31, 2017
Merged

Conversation

filmor
Copy link
Member

What does this implement/fix? Explain your changes.

Fixes issue#262 by countering two memory corruption issues.

Does this close any currently open issues?

#262.

Any other comments?

Is currently based on my other PR, but doesn't strictly need it, I could rebase.

@codecov-io
Copy link

codecov-io commentedJan 30, 2017
edited by codecovbot
Loading

Codecov Report

❗ No coverage uploaded for pull request head (fix-shutdown@af6d37f).


Continue to review full report at Codecov.

Legend -Click here to learn more
Δ = absolute <relative> (impact),ø = not affected,? = missing data
Powered byCodecov. Last update2d1da5d...af6d37f. Read thecomment docs.

@vmuriart
Copy link
Contributor

Is this branch contain the same changes from#341? I'm reading it from my phone so hard to tell.

@vmuriart
Copy link
Contributor

To answer my own question, it is. I'm testing this now but its looking good!

@vmuriart
Copy link
Contributor

@vmuriart
Copy link
Contributor

@filmor you ok with me rebasing your work ontop of the master branch and push it here?

throw new PythonException();
}

return new PyObject(result);
Copy link
Contributor

Choose a reason for hiding this comment

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

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

I don't really see the issue here.

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

To elaborate, the link that you posted warns against relying ontry {} finally {} as thefinally may not be executed, but in such a case the problem has either exited already or is in the process of doing so, so we don't have to worry about dereferencing the Python resources anyhow.

Copy link
Contributor

Choose a reason for hiding this comment

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

It was more of a caveat, return statements withintry statements confuse me at times.

@filmorfilmorforce-pushed thefix-shutdown branch 2 times, most recently from7e26298 to3e1a313CompareJanuary 31, 2017 06:44
Runtime.XDecref(py_import);
}
}

internal static void Cleanup()
Copy link
Contributor

Choose a reason for hiding this comment

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

Is there a call toCleanup missing?

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

That part is not used anymore as there is only a single ModuleDef instance that is kept for the whole run time, I'll remove it.

Copy link
Contributor

Choose a reason for hiding this comment

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

Cool, after it's removed I'm ok merging it. This fixes the issue for Python2.7, but it still occassionally fails on Python3 but it seems to be due to a different section of code

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

Yeah, I noticed that too, I'll try to reproduce the issue, for me it happens (after these patches) not anymore on Shutdown but only on Initialize.

@vmuriart
Copy link
Contributor

Cool, will merge after CI completes. Thanks!

@vmuriartvmuriart merged commitaf6d37f intopythonnet:masterJan 31, 2017
vmuriart added a commit that referenced this pull requestJan 31, 2017
@filmorfilmor deleted the fix-shutdown branchJanuary 31, 2017 20:52
@vmuriartvmuriart changed the titleFix shutdownFix Re-initializationFeb 8, 2017
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@vmuriartvmuriartvmuriart left review comments

Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

3 participants
@filmor@codecov-io@vmuriart

[8]ページ先頭

©2009-2025 Movatter.jp