Repository navigation
fix(api): playFile prepends the language path, fix volume example - #36
Merged
Merged
Conversation
A relative filename gets the current language's sound directory put in front of it, so the language is prepended, not appended. The first example passes volume 5 but its comment said 2. Patched the playFile entry in the committed API model to match the upstream luadoc fix (EdgeTX/edgetx#7936) and regenerated with `docs_pipeline.py build`. The only outputs that change are the playFile page, its review page and the LuaLS stubs. Supersedes #10. Co-Authored-By: Alex K <arkarkark@users.noreply.github.com> Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 23, 2026
Contributor
|
📖 Docs preview: https://pr-36-edgetx-lua-reference-guide.edgetx.workers.dev/2.12/ Built from c716825 as the |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Ports the fix from @arkarkark's #10 to the MkDocs 2.12 docs:
luaPlayFile()writes the language path into the buffer first (getAudioPath()) and copies the filename after it.playFile("armed.wav", 5)comment said "use Wav volume 2". It now says 5. This example only appears in the LuaLS stubs and the internal review page.How
The 2.12 API pages are generated from the firmware's luadoc comments. The upstream fix is EdgeTX/edgetx#7936. To avoid waiting for that PR and a full re-extract, which would also pull in unrelated firmware drift, I edited the
playFileentry in the committeddocs-system/generated/api-model.local.jsonto match the upstream fix and regenerated:Rebuilding from the unmodified model reproduces the committed tree exactly, so the only outputs that change are:
playFilepage;runtime.d.luastub copies.mkdocs build --strictpasses.The next real re-extract from firmware produces the same text once EdgeTX/edgetx#7936 is in. That covers
main/dev, and 2.12 too if the firmware fix is backported to the 2.12 branch.Supersedes #10, credited as co-author.
🤖 Generated with Claude Code