Skip to content

build: add _tools/lint/manifest-json-deps#11169

Draft
Planeshifter wants to merge 1 commit intodevelopfrom
philipp/lint-manifest-json-deps
Draft

build: add _tools/lint/manifest-json-deps#11169
Planeshifter wants to merge 1 commit intodevelopfrom
philipp/lint-manifest-json-deps

Conversation

@Planeshifter
Copy link
Copy Markdown
Member

Description

What is the purpose of this pull request?

This pull request:

  • Adds a new lint tool (@stdlib/_tools/lint/manifest-json-deps) that validates manifest.json dependencies by cross-referencing C source file #include directives against declared dependencies.

The tool:

  • Parses C source files for #include "stdlib/..." directives
  • Maps include paths to @stdlib package names (handling underscore-to-hyphen conversion and sub-header resolution)
  • Scans src/addon.c for non-WASM build configurations (since addon.c is compiled but not listed in manifest src arrays)
  • Excludes self-references and skips Fortran files
  • Reports any missing dependencies per configuration

This is part 1 of a series adding manifest.json validation tooling (see Related Issues).

Related Issues

Does this pull request have any related issues?

No.

Questions

Any questions for reviewers of this pull request?

No.

Other

Any other information relevant to this pull request? This may include screenshots, references, and/or implementation notes.

This is the first in a series of PRs adding manifest.json tooling parity with the existing package.json tooling:

  1. This PR: _tools/lint/manifest-json-deps (dependency linter — highest priority)
  2. _tools/manifest-json/validate + _tools/lint/manifest-json (schema validation)
  3. _tools/manifest-json/standardize + auto-fix scripts (standardization)
  4. Makefile integration (make lint-manifest-json, make lint-manifest-json-deps)

Checklist

Please ensure the following tasks are completed before submitting this pull request.

AI Assistance

When authoring the changes proposed in this PR, did you use any kind of AI assistance?

  • Yes
  • No

If you answered "yes" above, how did you use AI assistance?

  • Code generation (e.g., when writing an implementation or fixing a bug)
  • Test/benchmark generation
  • Documentation (including examples)
  • Research and understanding

Disclosure

This PR was written primarily by Claude Code with direction and review from the author.


@stdlib-js/reviewers

Add a lint tool that validates manifest.json dependencies by
cross-referencing C source file `#include` directives against
declared dependencies. The tool maps include paths to package
names (handling underscore-to-hyphen conversion and sub-header
resolution), scans addon.c for non-WASM build configurations,
and reports any missing dependencies.

---
type: pre_commit_static_analysis_report
description: Results of running static analysis checks when committing changes.
report:
  - task: lint_filenames
    status: passed
  - task: lint_editorconfig
    status: passed
  - task: lint_markdown
    status: na
  - task: lint_package_json
    status: na
  - task: lint_repl_help
    status: na
  - task: lint_javascript_src
    status: na
  - task: lint_javascript_cli
    status: na
  - task: lint_javascript_examples
    status: na
  - task: lint_javascript_tests
    status: na
  - task: lint_javascript_benchmarks
    status: na
  - task: lint_python
    status: na
  - task: lint_r
    status: na
  - task: lint_c_src
    status: na
  - task: lint_c_examples
    status: na
  - task: lint_c_benchmarks
    status: na
  - task: lint_c_tests_fixtures
    status: na
  - task: lint_shell
    status: na
  - task: lint_typescript_declarations
    status: passed
  - task: lint_typescript_tests
    status: na
  - task: lint_license_headers
    status: passed
---
@Planeshifter Planeshifter force-pushed the philipp/lint-manifest-json-deps branch from c2c1dbc to bcbd736 Compare March 27, 2026 06:35
@Planeshifter Planeshifter changed the title feat: add _tools/lint/manifest-json-deps build: add _tools/lint/manifest-json-deps Mar 27, 2026
@github-actions github-actions bot mentioned this pull request Mar 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Tools Issue or pull request related to project tooling.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants