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

Cryptic error when there is no issue in the given line #67

Closed
adamniedzielski opened this issue Apr 21, 2016 · 1 comment
Closed

Cryptic error when there is no issue in the given line #67

adamniedzielski opened this issue Apr 21, 2016 · 1 comment
Assignees

Comments

@adamniedzielski
Copy link

Thank you for an amazing piece of software! I have a bug to report:

Description

When you run:

mix credo lib/chapter_sampler.ex:6

and there is no issue in the given line, you will get quite a cryptic error:

Checking 1 source file ...
** (UndefinedFunctionError) undefined function nil.scope/0
    nil.scope()
    Credo.CLI.Output.Explain.print_issues/7
    lib/credo/cli/command/explain.ex:22: Credo.CLI.Command.Explain.run/2
    lib/credo/cli.ex:53: Credo.CLI.main/1
    (mix) lib/mix/cli.ex:58: Mix.CLI.run_task/2
Real life case

First I run mix credo --strict and it reported an issue in lib/chapter_sampler.ex:6. Then I wanted to get the details of this issue, but I didn't specify the --strict switch and I got the above error. The issue was one of these "strict" ones.

@rrrene
Copy link
Owner

rrrene commented Apr 21, 2016

Ah, very good! I mean, not "good" good, but a good error report 👍 😁

@rrrene rrrene self-assigned this Apr 21, 2016
ericworkman added a commit to ericworkman/credo that referenced this issue Apr 27, 2016
ericworkman added a commit to ericworkman/credo that referenced this issue Apr 27, 2016
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

2 participants