You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Cache doesn't work properly, when the project root exists, but it is found by the non-first entry of projectile-project-root-functions.
Steps to reproduce the problem
The cited part of the code doesn't use the cache properly. The problem is, if a function in projectile-project-root-functions returns nil, then this information will be lost (because there is no differentiation between "cache-entry-doesn't exist yet" and "root-not-found"). For example, suppose that the 3rd function in projectile-project-root-functions finds the root, the 1st and 2nd function returns nil. This means that the result of the 3rd function will be stored properly, but the 1st and 2nd function's result won't. Next time when projectile-project-root is called, it will try the 1st and 2nd function again (because the cache returns nil. That's a problem), and it will use the cached result for the 3rd function (this is right).
Expected behavior
Cache should work properly
Actual behavior
Cache doesn't work properly, when the project root exists, but it is found by the non-first entry of
projectile-project-root-functions
.Steps to reproduce the problem
The cited part of the code doesn't use the cache properly. The problem is, if a function in
projectile-project-root-functions
returnsnil
, then this information will be lost (because there is no differentiation between "cache-entry-doesn't exist yet" and "root-not-found"). For example, suppose that the 3rd function inprojectile-project-root-functions
finds the root, the 1st and 2nd function returnsnil
. This means that the result of the 3rd function will be stored properly, but the 1st and 2nd function's result won't. Next time whenprojectile-project-root
is called, it will try the 1st and 2nd function again (because the cache returnsnil
. That's a problem), and it will use the cached result for the 3rd function (this is right).Environment & Version information
Projectile version information
The text was updated successfully, but these errors were encountered: