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

Update README.md #284

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
12 changes: 12 additions & 0 deletions README.md
Expand Up @@ -475,6 +475,18 @@ end
- When erlang version 17.3 is used, an error message `(MatchError) no match of right hand side value: ""` can be shown. Refer to issue #14 for the details.
- https://github.com/parroty/excoveralls/issues/14

### Silence OTP Cover Warnings
To remove OTP warnings about modules or specific logging, please open a GitHub issue in the Erlang OTP repository. Alternatively you can copy the `cover.erl` file under `src/` of your Elixir project and modify it to remove the warnings.
Copy link
Owner

@parroty parroty Jul 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the open a GitHub issue in the Erlang OTP repository is a separate discussion topic from the procedure itself. Can we exclude it this part? (may be like the following?)

To remove OTP warnings about modules or specific logging, you can copy the cover.erl file under src/ of your Elixir project and modify it to remove the warnings, as a tentative solution.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

sure, it might be easier for you to cherry pick what's needed and update README directly.

Copy link
Owner

@parroty parroty Jul 14, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK. I'll update the README separately (thank you for the contribution).
I tried to update the PR itself, but couldn't do that, maybe because it's coming from a fork.


- Remove the 2 lines below to remove the "WARNING: Module already imported from ..." log
https://github.com/erlang/otp/blob/131398b54cca5f1ae95ed268274936d2efde8c39/lib/tools/src/cover.erl#L1553-L1554

- If you do not want the imported info cluttering your test output, replace the function in https://github.com/erlang/otp/blob/131398b54cca5f1ae95ed268274936d2efde8c39/lib/tools/src/cover.erl#L1520-L1525 with
```
imported_info(_Text,_Module,_Imported) ->
ok.
```

### Todo
- It might not work well on projects which handle multiple project (Mix.Project) files.
- Needs improvement on file-path handling.
Expand Down