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

~/Library/Preferences should not be used on macOS #380

Closed
kidonng opened this issue Apr 15, 2021 · 3 comments
Closed

~/Library/Preferences should not be used on macOS #380

kidonng opened this issue Apr 15, 2021 · 3 comments
Labels

Comments

@kidonng
Copy link

kidonng commented Apr 15, 2021

please complete the following information:

  • OS version: macOS 11.3
  • Editor: vscode
  • Editor version: 1.55.2
  • TabNine extension version: 3.4.1
  • Engine version (could be located within Tabnine Hub): 3.3.108

Issue Details:

This is not really an issue, but I'd like to bring it up in hope of a change. Pardon me if there's any duplicate, since this title not easy to check.

About the title, this has been discussed in other places, like dirs-dev/directories-rs#62.
The basic idea is that this folder should only be interacted via macOS's native API, otherwise apps should use ~/Library/Application Support.
I'm aware that TabNine data is already stored in ~/Library/Application Support, but perhaps it can coexist with preferences (since most likely you are using a library to handle this), or ~/.config (XDG_CONFIG_HOME) could also be used as it's common for developer tools on macOS.


There are two other questions about TabNine that I don't feel like opening separate issues for them:

  • I noticed in recent VSCode extension updates, location of TabNine binaries has been moved to VSCode's global storage (<VSCode data directory>/User/globalStorage/tabnine.tabnine-vscode/binaries) from the extension directory (<VSCode extension directory>/binaries).
    This is a welcoming change, but does this mean the VSCode extension will start to clean up old versions of binaries? Before the change, they would stack up in the extension directory, but it's not a problem since VSCode will clean old versions of extensions.
  • Obsolete lock files are stacking up in preferences directory. This won't cause any space shortage, but it would be good if they would also be cleaned up.
    (However there maybe different versions of TabNine running across different editors/extensions, which may cause implementation issues for cleaning. If this is the case then it's fine!)
    $ ls ~/Library/Preferences/TabNine
    3.3.101  3.3.103  3.3.104  3.3.108  cloud.settings  last_heartbeat  local.settings  tabnine_config.json  TabNineExample.toml
    

That's all, thanks for you amazing work on TabNine. 😃

@boazberman
Copy link

Regarding the general issue, thank you for bringing it to our attention, we will look into it.

Regarding the 1st point, we've implemented a delete mechanism for old versions a while ago, so it will only ever keep the last 3 versions of Tabnine locally.

Regarding the 2nd point, you are right, we need to make sure old lock files are removed as well.

@kidonng
Copy link
Author

kidonng commented Apr 18, 2021

Thanks for your reply! Feel free to close the issue when you find it appropriate.

@stale
Copy link

stale bot commented Oct 3, 2022

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@stale stale bot added the wontfix label Oct 3, 2022
@stale stale bot closed this as completed Oct 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants