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

Tests should clear (or not use) local repo caches #329

Open
andyk opened this issue Mar 19, 2022 · 1 comment
Open

Tests should clear (or not use) local repo caches #329

andyk opened this issue Mar 19, 2022 · 1 comment

Comments

@andyk
Copy link
Contributor

andyk commented Mar 19, 2022

See discussion in #310

andyk added a commit that referenced this issue Mar 20, 2022
…not sure there are other tests besides the 2 that I updated in this commit that need to clear the local repo cache as well.
andyk added a commit that referenced this issue Mar 20, 2022
…not sure there are other tests besides the 2 that I updated in this commit that need to clear the local repo cache as well.
@andyk andyk moved this to In Progress in Sprint 0.2.0 Mar 20, 2022
andyk added a commit to andyk/agentos that referenced this issue Mar 20, 2022
…django webapp, add local repo cache clearing to webapp tests which further addresses agentos-project#329.
@andyk andyk moved this from In Progress to Todo in Sprint 0.2.0 Mar 22, 2022
@andyk
Copy link
Contributor Author

andyk commented Mar 22, 2022

Copying this text over from a comment in #310:

Clearing these caches can be tricky if modules that live in them have already been loaded into a python process. Just ran into this when trying to update the tests to clear the repo cache, but then Windows (though not Linux or MacOs) threw an exception during test_component_from_github_no_venv when trying to clear the cache because test_component_from_github_with_venv had already run and loaded some modules from that same local github repo.

I now think perhaps we should only cache repos locally into directories that have the name of the github hash, and then we can also separately cache the mapping between branch names and repos.

Dulwich might also have a better way of handling these things.

@andyk andyk removed this from Sprint 0.2.0 Mar 22, 2022
@andyk andyk moved this to Todo in Sprint 0.2.2 Mar 22, 2022
@andyk andyk removed this from Sprint 0.2.2 Mar 22, 2022
@andyk andyk removed this from Sprint 0.2.0 Mar 22, 2022
@andyk andyk moved this to Todo in Sprint 0.2.2 Mar 22, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

1 participant