Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Detect missing arguments in logging format strings #9999

Open
sam-s opened this issue Oct 2, 2024 · 0 comments
Open

Detect missing arguments in logging format strings #9999

sam-s opened this issue Oct 2, 2024 · 0 comments
Labels
Needs triage 📥 Just created, needs acknowledgment, triage, and proper labelling

Comments

@sam-s
Copy link

sam-s commented Oct 2, 2024

Current problem

The following error should be easily detectable:

import logging
logging.info("foo %s")  # missing format arg

the missing arguments should be easily detectable, like we already get too-many-format-args on

logging.warning("foo",1,2,3) # extra format args

Desired solution

I want pylint to issue the too-few-format-args error on the above code.

Additional context

No response

@sam-s sam-s added the Needs triage 📥 Just created, needs acknowledgment, triage, and proper labelling label Oct 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs triage 📥 Just created, needs acknowledgment, triage, and proper labelling
Projects
None yet
Development

No branches or pull requests

1 participant