GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — [java] InvalidLogMessageFormat does not detect extra parameters when no placeholders · Issue #2196 · pmd/pmd

[java] InvalidLogMessageFormat does not detect extra parameters when no placeholders #2196

New issue
Copy link
New issue
Copy link
Closed
#2200
Closed
[java] InvalidLogMessageFormat does not detect extra parameters when no placeholders#2196
#2200
Copy link
Labels
a:false-negativePMD doesn't flag a problematic piece of code
Milestone
6.21.0

Description

@jogu
jogu
opened on Jan 4, 2020
Issue body actions

Affects PMD Version: 6.20.0

Rule: InvalidLogMessageFormat

Description:

If the format string has no placeholders, PMD does not detect extra parameters.

Code Sample demonstrating the issue:

logger.warn("foo {}", "flibble", "moo", "blah", "blah"); // PMD flags this
logger.warn("foo", "flibble", "moo", "blah", "blah"); // PMD doesn't flag this

Running PMD through: Maven

Activity

  1. jogu
    added 3 commits that reference this issue on Jan 4, 2020

    Add a basic integration to pmd, a static analysis tool

    260d415

    Add a basic integration to pmd, a static analysis tool

    4c37456

    Add a basic integration to pmd, a static analysis tool

    0f36fd0
  2. oowekyala
    added
    a:false-negativePMD doesn't flag a problematic piece of code
    on Jan 5, 2020
  3. linusjf commented on Jan 6, 2020

    @linusjf
    linusjf
    on Jan 6, 2020
    More actions

    #2187
    Added similar issue with request for new rule .

  4. jogu
    added a commit that references this issue on Jan 6, 2020

    Add a basic integration to pmd, a static analysis tool

    634f0f4
  5. adangel
    added a commit that references this issue on Jan 6, 2020

    [java] InvalidLogMessageFormat: handle zero placeholders correctly

    This issue will close once commit 6bea1e6 is merged into the 'main' branch.
    6bea1e6
  6. adangel
    added this to the 6.21.0 milestone on Jan 6, 2020
  7. adangel
    added
    has:pr
    on Jan 6, 2020
  8. adangel
    closed this as completedin 6bea1e6on Jan 16, 2020
  9. jogu
    added a commit that references this issue on Feb 16, 2020

    Upgrade to PMD 6.21.0

    10da818
  10. jogu
    added a commit that references this issue on Feb 25, 2020

    Upgrade to PMD 6.21.0

    544c3f5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    a:false-negativePMD doesn't flag a problematic piece of code

    Type

    No type

    Projects

    No projects

      Milestone

      • 6.21.0

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions

      You are visitor 01402775 — GeezerVison does not store the pages you look up.
      Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.