LuaLS / LuaLS/lua-language-server
Documentation export is missing information
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 4.4k
- Forks
- 442
- PR merge metrics
- No merged PRs in 30d
Description
How are you using the lua-language-server?
Command Line
Which OS are you using?
Windows
What is the issue affecting?
Other
Expected Behaviour
After generating documentation with --doc, I expected to have access to the all of the information available in the annotations that is presented or used by the language server.
Actual Behaviour
There were a few things that are missing or strange:
@seeannotations are absent.- Access levels (
@protected,@private,@package) are absent. - Aliases that extend other aliases include the documentation of the alias that they extend, which makes it difficult to tell which documentation belongs to only the extended alias.
- The
startandfinishfields seem odd; they're very large numbers (e.g., 5490009, 5490021) that clearly don't refer to character ranges within the files. What are these numbers?
For the purpose of generating documentation, the first two problems seem significant—it would be difficult to filter out private fields and methods, for example.
Reproduction steps
- Create a Lua file that uses access modifiers,
@see, and an alias that extends another alias. I've provided a minimal example of such a file below. - Observe the missing data and oddities.
Additional Notes
Example for reproduction:
---@class C
---@field private z integer
local C = {}
---Base alias doc comment.
---@alias Base
---| 'A'
---| 'B'
---Extended alias doc comment.
---@alias Derived
---| Base
---| 'C'
---@protected
function C.x()
end
---@see C.x
function C.y()
end
Log File
No response
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the --doc export against the Lua reproduction in the issue and inspect how its output represents @see, access modifiers, inherited alias documentation, and start/finish. Trace the documentation-export entry point and compare its output with the annotation information used by the language server. Done means the exported data preserves the requested annotation details and explains or corrects the range values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- documentation, tooling
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100