atlas icon indicating copy to clipboard operation
atlas copied to clipboard

Add Linting Step/Check in Travis CI

Open anirudhRowjee opened this issue 4 years ago • 11 comments

that's pretty much it. Check for code formatting using black, along with a linting tool that is the best choice.

anirudhRowjee avatar Dec 12 '20 20:12 anirudhRowjee

A suggestion for this Instead of checking black linting in Travis You could add a pre-commit to the repo So everytime a contributor commits then the black check is automatically fulfilled

roysti10 avatar Dec 13 '20 04:12 roysti10

Yeah, this seems to be the recommended course of action. I'll look into it

anirudhRowjee avatar Dec 13 '20 05:12 anirudhRowjee

Precommit is a good method to check for lint errors but CI is also needed. I would recommend using github actions for this instead of Travis CI

RohanJnr avatar Dec 13 '20 12:12 RohanJnr

I can work on this if you can assign me :p

RohanJnr avatar Dec 13 '20 12:12 RohanJnr

@RohanJnr Sure, I'll assign you. Why Github Actions over Travis CI though? Just want to weigh the pros and cons :smile:

anirudhRowjee avatar Dec 13 '20 14:12 anirudhRowjee

github actions is simply available on github, its one of their products so why go for a third party CI tool like travis

RohanJnr avatar Dec 13 '20 14:12 RohanJnr

while that would simply be more convenient, I'd just like to know if we're missing out on anything in terms of features by choosing github actions as opposed to Travis. I'd appreciate any more information on this :D

anirudhRowjee avatar Dec 13 '20 14:12 anirudhRowjee

there are a bunch of resources online about that and actions is mostly the choice for most application. you should be able to accomplish the same using both. Github Actions is just convenient as you said.

RohanJnr avatar Dec 13 '20 16:12 RohanJnr

I would suggest flake8 as a linting tool. Since you're using it with black you'll have to create a compatible configuration. (ref)

Samyak2 avatar Dec 14 '20 04:12 Samyak2

If you're going to use a 3rd party CI, I wouldn't recommend Travis, there were a lot of weird issues which popped up for us while using Travis, go with CircleCI or Jenkins

MadhavJivrajani avatar Dec 14 '20 05:12 MadhavJivrajani

GitHub actions?

anirudhRowjee avatar Dec 16 '20 07:12 anirudhRowjee