Skip to content

Mult-line underlining not working properly in plain renderer #529

Open

Description

@ericwb

Describe the bug
The plain renderer doesn't work properly when the location is a multi-line string.

To Reproduce
Steps to reproduce the behavior:

$ .tox/py312/bin/precli tests/unit/rules/python/stdlib/argparse/examples/argparse_add_argument_password.py --plain
PY027: Invocation of Process Using Visible Sensitive Information
  File "tests/unit/rules/python/stdlib/argparse/examples/argparse_add_argument_password.py", line 
20, in <module>
    parser.add_argument(                                                                            
    ^                                                                                               
Error: Secrets in CLI arguments are leaked to command history, logs, ps output, etc.

Found 1 errors, 0 warnings, and 0 notes in 1 files and 26 lines of code.

Expected behavior
Should underline entire multi-line

Version

precli 0.5.12.dev8
Copyright 2024 Secure Sauce LLC
License BUSL-1.1: Business Source License 1.1 <https://spdx.org/licenses/BUSL-1.1.html>
  Python 3.12.4 (main, Jun 25 2024, 11:01:48) [Clang 15.0.0 (clang-1500.3.9.4)]

Additional context

Activity

  1. added
    bug
    on Jul 19, 2024
  2. changed the title [-]Mult-line underlining no working properly in plain renderer[/-] [+]Mult-line underlining not working properly in plain renderer[/+] on Jul 22, 2024
  3. added theissue type on May 5, 2025
  4. removed
    bug
    on May 5, 2025
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

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions