LuaLS / LuaLS/lua-language-server

Documentation export is missing information

Đang mở
#2,322 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Ngôn ngữ chính
Lua
Star
4.4k
Fork
442
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Mô tả

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:

  • @see annotations 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 start and finish fields 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
  1. 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.
  2. 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

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Bắt đầu bằng cách chạy bản xuất --doc trên reproduction bằng Lua trong issue và kiểm tra cách đầu ra biểu diễn @see, các access modifier, tài liệu alias được kế thừa và start/finish. Truy vết entry point của việc xuất tài liệu và so sánh đầu ra của nó với thông tin annotation được language server sử dụng. Được xem là hoàn tất khi dữ liệu được xuất giữ lại các chi tiết annotation được yêu cầu và giải thích hoặc sửa các giá trị phạm vi.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
lua
Lĩnh vực
documentation, tooling
Loại issue
Lỗi
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.