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

✨ Add the concept of a (unique) container ID #97

Merged
merged 2 commits into from Oct 2, 2020

Conversation

giovannipizzi
Copy link
Member

This fixes #11
I also fixed a bug I discovered, where config values that
were cached but the cache was not cleared when re-initialising the
container.
To reduce the risk of such a problem, I am now only caching the whole
configuration dictionary (and not each value), and I don't need to
implement caching anymore for each single config value; and I just
need to clear one variable self._config rather than each newly-defined
configuration.

In addition, I add a test to check that re-initialising the container
creates a new container ID (container.container_id).

@giovannipizzi
Copy link
Member Author

This is a draft PR and is blocked because it builds upon the commits of #96 and can be merged only after #96 is merged

This fixes aiidateam#11
I also fixed a bug I discovered, where config values that
were cached but the cache was not cleared when re-initialising the
container.
To reduce the risk of such a problem, I am now only caching the *whole*
configuration dictionary (and not each value), and I don't need to
implement caching anymore for each single config value; and I just
need to clear one variable `self._config` rather than each newly-defined
configuration.

In addition, I add a test to check that re-initialising the container
creates a new container ID (`container.container_id`).
@codecov
Copy link

codecov bot commented Aug 27, 2020

Codecov Report

Merging #97 into develop will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##           develop       #97   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            7         7           
  Lines         1502      1502           
=========================================
  Hits          1502      1502           
Impacted Files Coverage Δ
disk_objectstore/container.py 100.00% <100.00%> (ø)

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 64326c7...aaa4f73. Read the comment docs.

@chrisjsewell chrisjsewell marked this pull request as ready for review October 2, 2020 04:03
@chrisjsewell chrisjsewell changed the title [BLOCKED] Add the concept of a container (unique) ID ✨ Add the concept of a (unique) container ID Oct 2, 2020
@chrisjsewell chrisjsewell merged commit 1d7c389 into aiidateam:develop Oct 2, 2020
@sphuber sphuber mentioned this pull request Nov 4, 2020
@giovannipizzi giovannipizzi deleted the fix_11_repo_id branch November 10, 2020 20:31
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.

Add the concept of an object-store UUID to identify it
2 participants