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

Prevent crash when cache shrink fails #1336

Merged
merged 1 commit into from
Jul 19, 2017
Merged

Prevent crash when cache shrink fails #1336

merged 1 commit into from
Jul 19, 2017

Conversation

jgosmann
Copy link
Collaborator

@jgosmann jgosmann commented Jul 13, 2017

Motivation and context:
This prevents from Nengo crashing (exiting with an exception) when the cache shrink fails because of an unavailable lock.

Fixes #1335.

Interactions with other PRs:
none

How has this been tested?

Added a test. It needs to access some cache internals which might not be the best style, but it seems to be the easiest way to test it and I don't think the index or lock should be public.

How long should this take to review?

  • Quick (less than 40 lines changed or changes are straightforward)

Where should a reviewer start?

Types of changes:

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have read the CONTRIBUTING.rst document.
  • [n/a] I have updated the documentation accordingly.
  • I have included a changelog entry.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

@jgosmann
Copy link
Collaborator Author

@tbekolay, it would be nice to have this in the release.

Copy link
Member

@tbekolay tbekolay left a comment

Choose a reason for hiding this comment

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

Added a fixup with some minor wording changes. Will merge shortly unless someone stops me!

because of an unavailable lock.

Fixes #1335.
@tbekolay tbekolay merged commit 4aeae47 into master Jul 19, 2017
@tbekolay tbekolay deleted the fix-cache-shrink branch July 19, 2017 17:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Failure to acquire cache log can still crash simulation
3 participants