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

Fix issue #249 #250

Merged
merged 4 commits into from
Oct 29, 2024
Merged

Fix issue #249 #250

merged 4 commits into from
Oct 29, 2024

Conversation

lohedges
Copy link
Contributor

This PR closes #249 and OpenBioSim/somd2#60.

  • I confirm that I have merged the latest version of devel into this branch before issuing this pull request (e.g. by running git pull origin devel): [y]
  • I confirm that I have added a changelog entry to the changelog (we will add a link to this PR as part of the review): [y]
  • I confirm that I have permission to release this code under the GPL3 license: [y]

chryswoods
chryswoods previously approved these changes Oct 29, 2024
Copy link
Contributor

@chryswoods chryswoods left a comment

Choose a reason for hiding this comment

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

Thanks for catching this - looks great :-)

@lohedges
Copy link
Contributor Author

No problem. It's one of those where you wonder how it ever worked in the first place. It's also quite surprising (and dangerous) that QByteArray appears to be one of the few Qt data structures that doesn't have an aliased .count() method, i.e. as an alias for .size(). I find it so easy to use .count() by mistake since I'm used to using it for QVector and QList, etc. Perhaps we should be careful to use .size() throughout in future.

I've just pushed a minor update to increase the wait period before terminating QThread objects when cleaning the PageCache. On my machine, this stops the random FATAL: exception not rethrown seen on interpreter exit, although it might not be a 100% reliable solution on all platforms. (I also didn't see any crashes if I just commented this part of the code, i.e. didn't attempt to wait for threads to stop at all.)

@chryswoods
Copy link
Contributor

I agree about size versus count, but this is so ingrained in my subconscious that the change would be difficult... ;-)

@lohedges lohedges merged commit 146632e into devel Oct 29, 2024
@lohedges lohedges deleted the fix_249 branch October 29, 2024 13:47
lohedges added a commit that referenced this pull request Oct 29, 2024
lohedges added a commit that referenced this pull request Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] Sire::Mol::Frame::toByteArray initialises QByteArray incorrectly
2 participants