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

Cache files #265

Closed
wants to merge 0 commits into from
Closed

Cache files #265

wants to merge 0 commits into from

Conversation

tdejong00
Copy link

This pull request adds an interface for modifying cache files, which is located in the kernel_tuner/cache directory. This directory contains the following modules:

  • cache (main module): contains a Cache class through which cache files can be created, read and written. This should be the only python module that needs to be used for modifying cache files.
  • cli_tools: contains functions used in the ktcache command.
  • convert: contains functions for converting (older) cache files to newer cache files.
  • file: contains functions for reading JSON from and writing JSON to cache files.
  • json: contains TypeDict type hints for typing code.
  • json_encoder: contains a custom instance of JSONEncoder that automatically serializes data into JSON in a readable format.
  • paths: contains useful paths within the project.
  • versions: exports useful Semver version constants.

Furthermore the following test modules have been added:

  • test_cachefile_class.py: tests whether the class integrates the functionalities of the other cache modules in the correct way and the additional logic in the Cache class.
  • test_cachefile_encoder.py: tests whether the JSON is encoded in the right way.
  • test_cachefile_read_write.py: tests whether cache is read and written in the correct format.
  • test_cachefile_schema.py: tests the correctness of the schema.
  • test_script_ktcache.py: tests the ktcache CLI command.

We have not yet added an entry to the CHANGELOG.md, because we are not sure in what version these changes will be introduced.

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
No data about Duplication

See analysis details on SonarCloud

@benvanwerkhoven
Copy link
Collaborator

@tdejong00 Thanks a lot for this pull request! I currently can't push new commits to this pull because the pull request is created from the master branch of your fork which is protected. Could you either unprotect your master branch or create a new branch and create the pull request from that branch?

@tdejong00
Copy link
Author

@tdejong00 Thanks a lot for this pull request! I currently can't push new commits to this pull because the pull request is created from the master branch of your fork which is protected. Could you either unprotect your master branch or create a new branch and create the pull request from that branch?

@benvanwerkhoven I have unprotected our master branch. Let me know if this solved the problem!

@benvanwerkhoven
Copy link
Collaborator

Hmm, that wasn't intentional..

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.

2 participants