chronoscio / backend

Backend repository for the ChronoScio project
GNU General Public License v3.0
5 stars 0 forks source link

Remote pylint/autopep8 broken #32

Open quorth0n opened 5 years ago

quorth0n commented 5 years ago

The executables run fine when executed manually but the functionality does not integrate with vscode. I'll have to try logging the exact flags, etc. that vscode passes to the executables.

dwaxe commented 5 years ago

I think I got this working with the following VSCode Workspace Settings (.vscode/settings.json):

{
    "python.pythonPath": "${workspaceFolder}/venv/bin/python3",
    "python.linting.pylintArgs": [
        "--load-plugins=pylint_django"
    ],
    "python.formatting.provider": "black",
    "python.formatting.blackArgs": [
        "-l 120",
        "-S"
    ],
}

First, I created a virtualenv directly under the backend folder: cd backend; virtualenv venv Then installed all the packages in requirements.txt: pip install -r config/requirements.txt (Optional) I installed black as my autoformatter and made it ignore quotes (-S) and default to a line length of 120

quorth0n commented 5 years ago

Nice work, but most of us use docker and your solution will not work with remote containers. If/when we add #25 however this will be something to consider, maybe we could have two settings.json templates or just omit the files as a whole and document the process instead.

wtokumaru commented 5 years ago

Why exactly do we use Docker? I assume to make open source development easier but I am worried about that motivation if it ends up not working for half the developers. I think that we should choose whichever is easier for new people to get working, which SHOULD be Docker. Until we have documentation that actually makes it work through we probably want to support both.

quorth0n commented 5 years ago

I've never experienced any issues with Docker on machines that fit its system requirements. Dockerless setup is ultimately a personal choice but really should be treated and maintained as only a fallback due to how greatly docker simplifies the deployment process across both development and production machines.