.. _misplaced-format-function:

misplaced-format-function / E0119
=================================

**Message emitted:**

format function is not called on str

**Description:**

*Emitted when format function is not called on str object. e.g doing print("value: {}").format(123) instead of print("value: {}".format(123)). This might not be what the user intended to do.*

**Problematic code:**

.. literalinclude:: /data/messages/m/misplaced-format-function/bad.py
   :language: python

**Correct code:**

.. literalinclude:: /data/messages/m/misplaced-format-function/good.py
   :language: python



Created by the `basic <https://github.com/PyCQA/pylint/blob/main/pylint/checkers/base/basic_checker.py>`__ checker.