Search code examples
configurationpycharmpylint

How to include file url in msg-template of pylint?


I would like to make the file paths of the pylint output clickable, so that I can open the corresponding file location. I tried to use following msg-template in the PyCharm terminal on Windows:

msg-template='(file:///{abspath}:{line}) :{column}: {msg_id}: {msg} ({symbol})'

enter image description here

However, on Windows I have backward \ instead of forward / slashes and the hyperlink does not work.

=> How can I include the file path as valid url/uri?


Solution

  • No need to specify file:/// on Windows. Try this:

    --msg-template="{abspath}:{line} :{column}: {msg_id}: {msg} {symbol}"
    

    enter image description here