Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Update removes Annotations/Lua from Lua.workspace.library setting #181

Open
emmericp opened this issue Jan 4, 2025 · 2 comments
Open

Update removes Annotations/Lua from Lua.workspace.library setting #181

emmericp opened this issue Jan 4, 2025 · 2 comments

Comments

@emmericp
Copy link
Contributor

emmericp commented Jan 4, 2025

my user settings.json prior to updating the vscode extension:

	"Lua.workspace.library": [
(...)
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Data",
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Interface",
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Libraries",
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Type",
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Widget",
		"~\\.vscode\\extensions\\ketho.wow-api-0.17.6\\Annotations\\Lua"
	],
	"wowAPI.luals.configurationScope": "User",
	"wowAPI.luals.setLuaRuntime": false,

after updating to 18.2:

	"Lua.workspace.library": [
(..)
		"~\\.vscode\\extensions\\ketho.wow-api-0.18.2\\Annotations\\Data",
		"~\\.vscode\\extensions\\ketho.wow-api-0.18.2\\Annotations\\Interface",
		"~\\.vscode\\extensions\\ketho.wow-api-0.18.2\\Annotations\\Libraries",
		"~\\.vscode\\extensions\\ketho.wow-api-0.18.2\\Annotations\\Type",
		"~\\.vscode\\extensions\\ketho.wow-api-0.18.2\\Annotations\\Widget"
	],
	"wowAPI.luals.configurationScope": "User",
	"wowAPI.luals.setLuaRuntime": false,

Which made it complain about missing all those WoW-specific Lua functions

@Ketho
Copy link
Owner

Ketho commented Jan 5, 2025

Isn't this related to #159 (comment) where you wanted the extension to not replace the Lua runtime? I remember you didn't really mind the warnings about them.

Or do you mean that the Wow-specific Lua functions like wipe and strjoin should always be loaded regardless of that option? Maybe that would be a better solution and stop the warnings.

There wasn't anything that changed between 0.17.6 and 0.18.2 with regards to the LuaLS library path iirc. Although I'm not sure why on 0.17.6 the Annotations/Lua folder still was included when wowAPI.luals.setLuaRuntime is set to false.

@emmericp
Copy link
Contributor Author

emmericp commented Jan 6, 2025

There wasn't anything that changed between 0.17.6 and 0.18.

I haven't updated in quite some time, and I've probably hand-maintained the include paths.
I do want to have the extra WoW Lua functions defined, but I also want non-WoW things like "io" and "os" defined; without the setLuaRuntime option this just gets force-disabled.

Anyhow, overall the situation is a mess because of us mixing non-WoW and WoW code in a repo, and it's obviously not ideal and unless LuaLS adds proper supports for environments (unlikely) it's likely not fully fixable :/

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants