id: unchecked-numeric-parse-python
valid:
  - |
    # #3211: already-converted-by-construction — Decimal raises
    # decimal.InvalidOperation, not ValueError, and is excluded here.
    x = float(Decimal("1.5"))
  - |
    # #3211: a numeric literal argument can never raise ValueError.
    x = int(3.7)
  - |
    try:
        g = int(s)
    except ValueError:
        pass
invalid:
  - 'int("42")'
  - 'float("3.14")'
  - 'int(user_input)'
