[LTP] metadata: add linter for JSON file

linuxtestproject.agent@gmail.com linuxtestproject.agent@gmail.com
Wed Jun 24 18:24:11 CEST 2026


Hi Andrea,

On Wed, 24 Jun 2026 16:27:21 +0200, Andrea Cervesato wrote:
> metadata: add linter for JSON file

> +    parser.add_argument(
> +        "--check-cve-online",
> +        action="store_true",
> +        help="verify CVE existence against the online CVE database",
> +    )
> +    args = parser.parse_args()

> +    errors: List[str] = lint_tests(tests, args.check_cve_exists)

argparse stores --check-cve-online as check_cve_online, but the code
reads check_cve_exists. This raises AttributeError every time main()
runs, even when the flag is not passed (the attribute simply does not
exist on the Namespace object).

Should this be args.check_cve_online?

Verdict - Needs revision

---
Note:

The agent can sometimes produce false positives although often its
findings are genuine. If you find issues with the review, please
comment this email or ignore the suggestions.

Regards,
LTP AI Reviewer


More information about the ltp mailing list