Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

exclude_paths does not work as expected (if at all.) #19

Closed
envygeeks opened this issue Jan 5, 2016 · 9 comments
Closed

exclude_paths does not work as expected (if at all.) #19

envygeeks opened this issue Jan 5, 2016 · 9 comments

Comments

@envygeeks
Copy link

Given the following configuration:

engines:
  rubocop: { enabled: true }
  fixme:   { enabled: true }
ratings:
  paths:
  - "lib/**.rb"
exclude_paths:
- "vendor/**"

I get:

== vendor/*/rubocop-*/spec/rubocop/cop/style/documentation_spec.rb (4 issues) ==
9: TODO found [fixme]
9: FIXME found [fixme]
9: HACK found [fixme]
95: FIXME found [fixme]
@ABaldwinHunter
Copy link
Contributor

@envygeeks I'm curious what version of codeclimate and the fixme engine you're running?

Fixme was updated in November to respect include_paths (derived from exclude_paths), which are now sent by codeclimate to the engine.

Can you try running

brew update && brew upgrade codeclimate

then

codeclimate engines:enable fixme`

and let me know how it goes?

* edited for clarity

@envygeeks
Copy link
Author

I don't use OS X. I use Linux, and that image was just pulled today fresh from the CodeClimate docker command.

@ABaldwinHunter
Copy link
Contributor

@envygeeks Got it, thanks.

Can you check what version of Code Climate you're running?

codeclimate --version

@envygeeks
Copy link
Author

jordon ~ % docker images |grep codeclimate
codeclimate/codeclimate           latest              5ce5cee6c453        6 days ago          95.83 MB
codeclimate/codeclimate-rubocop   latest              43f030ce3c75        7 days ago          66.69 MB
codeclimate/codeclimate-fixme     latest              bd56ec36de0a        3 weeks ago         647.9 MB

@ABaldwinHunter
Copy link
Contributor

@envygeeks Thanks for the output.

I experimented in CLI, and think the issue might be related to the naming of your path.

Could you try removing the quotes from your exclude path, so that it's:

exclude_paths:
- vendor/**

And let me know how it goes?

You can also run docker pull codeclimate/codeclimate-fixme to make sure you have the most up to date engine version.

Appreciate the reporting of this issue.

@envygeeks
Copy link
Author

We've already tried all that Microsoft debugging, we've tried it with quotes, without quotes, with **/* without **/* with ** and with *, we've tried to pull. This is not a problem with an outdated version and if it is, that's still a bug because it was CodeClimate that pulled the image in the first place, this morning, as our CI does not leave Docker images on it, which means every time it builds and tests this app, it's a brand new CodeClimate instance on a brand new CodeClimate pull.

Thanks.

@ABaldwinHunter
Copy link
Contributor

@envygeeks Got it. Sorry that didn't work for you.

Thanks for the feedback. We're aware of the issue and investigating the root cause.

@ABaldwinHunter
Copy link
Contributor

@envygeeks We recently updated the way the Code Climate handles exclude_paths: https://github.com/codeclimate/codeclimate/releases/tag/v0.18.0

Can you try updating to see if the new release fixes your issue?

If not, please feel free to go ahead and open a new issue on the codeclimate repo.

Thanks!

Closing this one for now.

@kkartch
Copy link

kkartch commented Feb 17, 2016

I'm experiencing this same issue. I'm currently evaluating this for our private repos on a trial, but not getting good results due to this issue. My .codeclimate.yml:

engines:
  duplication:
    enabled: true
    config:
      languages:
      - go
  fixme:
    enabled: true
  gofmt:
    enabled: true
  golint:
    enabled: true
  govet:
    enabled: true
ratings:
  paths:
  - "**.go"
exclude_paths:
- Godeps/**/*

Trimmed output is:

Starting analysis

== Godeps/_workspace/src/github.com/ajg/form/decode.go (2 issues) ==
18: exported func NewDecoder returns unexported type *form.decoder, which can be annoying to use [golint]
282: TODO found [fixme]

== Godeps/_workspace/src/github.com/ajg/form/encode.go (1 issue) ==
20: exported func NewEncoder returns unexported type *form.encoder, which can be annoying to use [golint]

== Godeps/_workspace/src/github.com/ajg/form/node.go (2 issues) ==
34: TODO found [fixme]
39: TODO found [fixme]

== Godeps/_workspace/src/github.com/ajg/form/pre-commit.sh (2 issues) ==
3: TODO found [fixme]
4: FIXME found [fixme]

I have also tried the many different variants of the exclude_paths selection with Godeps/, Godeps/, Godeps//*. With quotes/without quotes.

Latest version of codeclimate and latest docker images:

codeclimate --version
0.20.0
docker images | grep codeclimate
codeclimate/codeclimate-csslint       latest              468d26f5e706        24 hours ago        133.5 MB
codeclimate/codeclimate-eslint        latest              bba6f4524ffe        4 days ago          90.44 MB
codeclimate/codeclimate               latest              62eca8db5a53        4 days ago          95.09 MB
codeclimate/codeclimate-fixme         latest              868840c0a743        5 days ago          211 MB
codeclimate/codeclimate-duplication   latest              04e9cc6b0cc7        8 days ago          811 MB
codeclimate/codeclimate-govet         latest              88185bc0e1b0        5 weeks ago         217.6 MB
codeclimate/codeclimate-golint        latest              964303486d6d        5 weeks ago         11.22 MB
codeclimate/codeclimate-gofmt         latest              acae6da3479b        5 weeks ago         218.3 MB

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants