I am new to poetry and was trying ‘pytest’, ‘flake8’ and ‘bandit’
Following is the directory structure
Directory Structure
├── README.md
├── .github/workflows
│ ├── main.yml
├── library
│ ├── README.md
│ ├── action.yml
│ ├── config.py
│ ├── .flake8
I executed the following command from VSCode terminal and it error’ed as given below
sathish:~/analytics-example/library$ poetry run flake8
./config.py:49:66: E501 line too long (81 > 79 characters)
./config.py:56:66: E501 line too long (83 > 79 characters)
Following line was added to library/.flake8
files which resolved the issue
max-line-length = 125
However, when 'poetry run flake8'
was executed through Pipeline it resulted in same error
library/config.py:49:66: E501 line too long (81 > 79 characters)
library/config.py:56:66: E501 line too long (83 > 79 characters)
I tried the following solutions which actually resolved the issue but due to some reason library/.flake8 file was ignored
a) Added the flag to poetry run as follows in .github/workflows/main.yml
poetry run flake8 . --max-line-length=120
b) Created a new .flake8 file in the root of the project directory as given below
├── README.md
├── .flake8
├── .github/workflows
│ ├── main.yml
├── library
However, I just want to confirm whether .flake8
file should be created in the same level as that of .github
directory (or) am I missing some configuration so that library/.flake8 would be picked up?