-
-
Notifications
You must be signed in to change notification settings - Fork 507
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
get_cached_default_environment should be invalidated if $VIRTUAL_ENV changes #1200
Comments
blueyed
added a commit
to blueyed/jedi-vim
that referenced
this issue
Aug 13, 2018
Note that you have to use e.g. `:py3 os.environ['VIRTUAL_ENV'] = 'foo'` to update this, `:let $VIRTUAL_ENV = 'foo'` is not enough (both in Neovim and Vim). Ref: davidhalter/jedi#1200
I agree. We could probably just make it possible to clean the cache, rename this function and create a function that checks if |
So it could be cached on the module, and a new function would be added to clear the cache? |
blueyed
added a commit
to blueyed/jedi
that referenced
this issue
Aug 14, 2018
davidhalter
added a commit
that referenced
this issue
Sep 30, 2018
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
jedi/jedi/api/environment.py
Lines 190 to 192 in 691a5b6
This is used by jedi-vim, but when a user changes
$VIRTUAL_ENV
it should not take 10 minutes to work.Not sure how to approach this best.
On the one hand a time based cache does not really make sense here, except for when you install a new version, but then it might still take up to 10 minutes to have an effect.
Therefore I suggest changing it to only cache it by the value of
$VIRTUAL_ENV
.The text was updated successfully, but these errors were encountered: