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

Fixed CollectBasicObject test#1313

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
filmor merged 3 commits intopythonnet:masterfromlosttech:bugs/1309
Dec 12, 2020
Merged

Conversation

@lostmsu
Copy link
Member

@lostmsulostmsu commentedDec 10, 2020
edited
Loading

This contains two fixes, that must go along for the tests to pass:

  1. Fixed theCollectBasicObject andCollectOnShutdown tests for Mono by fixingMakeAGarbage function to not keep the garbage on the stack during a conservative roots scan (looks like Mono scans some variables, that are already gone).
  2. Fixed the crash during runtime shutdown by further simplifyingFinalizer to only store raw pointers to python objects instead of instances ofIPyDisposable and thus replacing Dispose with reliable and simpleDecRef.

This removes some functions fromFinalizer, which previously were public, but should not have been.

@lostmsulostmsuforce-pushed thebugs/1309 branch 10 times, most recently from8d89411 to45c370aCompareDecember 11, 2020 00:31
@lostmsulostmsu marked this pull request as ready for reviewDecember 11, 2020 02:50
Copy link
Member

@filmorfilmor left a comment

Choose a reason for hiding this comment

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

Can't you use one of the*Reference types instead ofIntPtr? It would be good to see at least in the code that we are talking about Python objects here.


[Test]
[Ignore("Ignore temporarily")]
[Obsolete("GC tests are not guaranteed")]
Copy link
Member

Choose a reason for hiding this comment

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

Is NUnit aware of this attribute or does this just generate yet another compile-time warning? Does it help to retry the test usinghttps://docs.nunit.org/articles/nunit/writing-tests/attributes/retry.html?

Copy link
MemberAuthor

Choose a reason for hiding this comment

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

NUnit is not aware. This actually removes warning from the usage of other[Obsolete] code.

@lostmsu
Copy link
MemberAuthor

@filmor not for the finalizer.*Reference types can not be stored.

@filmorfilmor merged commit6bc85ff intopythonnet:masterDec 12, 2020
@lostmsulostmsu mentioned this pull requestDec 12, 2020
4 tasks
@lostmsulostmsu deleted the bugs/1309 branchDecember 12, 2020 20:02
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@filmorfilmorfilmor 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.

2 participants

@lostmsu@filmor

[8]ページ先頭

©2009-2025 Movatter.jp