HyukjinKwon opened a new pull request, #61:
URL: https://github.com/apache/spark-connect-rust/pull/61
### What changes were proposed in this pull request?
Small CI/docs fixes for the coverage badges and the Rust-UDFs page:
- **Publish the coverage badge JSON at the `badges`-branch root** so the
shields.io endpoints the README references actually resolve (they were
written to a subdirectory before).
- **Fix the Rust coverage badge stuck at `0.0%`.** The parser read
`data[0]["line_coverage_percent"]` from `cargo llvm-cov --json`, a key that
does not exist; the llvm export format puts the summary under
`data[0]["totals"]["lines"]["percent"]`. It now reads that (falling back to
regions/functions), so the badge shows the real ~90% instead of 0.
- **Fix the UDFs guide rendering.** The ` ```rust,ignore ` fences never
rendered
(pymdownx.superfences rejects the comma, so the backticks printed
literally and
`#[...]` lines became H1 headings). Use ` ```{.rust .no-run} `, which
renders as
a Rust code block *and* is skipped by the doc-snippet compiler (documented
in
`check_doc_snippets.py`).
- **README:** lead the UDF section with the self-contained
(`#[spark_wasm_udf]`) define-and-call example and trim it to a short
snippet
plus a link to the guide; fold the API-parity note into a one-line clause.
### Why are the changes needed?
The Rust coverage badge showed `0.0%` (red) despite ~90% coverage, the
coverage
badges 404'd from the README, and the published UDFs page rendered its code
blocks as literal text with spurious headings.
### Does this PR introduce _any_ user-facing change?
No (CI badges and documentation only).
### How was this patch tested?
- Coverage parser: verified against real `cargo llvm-cov --json` output
locally -
it now yields the true line-coverage percentage instead of 0.
- UDFs page: rendered `docs/udfs.md` through the site's exact
mkdocs-material +
pymdownx extension set - proper highlighted Rust blocks, no literal
backticks,
no bogus headings; the docs snippet-compile check leaves the `{.rust
.no-run}`
blocks alone.
This pull request and its description were written by Isaac.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]