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

option -w Complexity/Lines seems odd #370

Open
astrodidge opened this issue Jan 25, 2023 · 3 comments
Open

option -w Complexity/Lines seems odd #370

astrodidge opened this issue Jan 25, 2023 · 3 comments
Labels
bug Something isn't working

Comments

@astrodidge
Copy link

I made some tests with scc (still new to it) and got the following output using the -w option:

Language Files Lines Blanks Comments Code Complexity Complexity/Lines
───────────────────────────────────────────────────────────Go 14 3970 595 985 2390 128 126.86
YAML 1 16 0 0 16 0 0.00
License 1 21 4 0 17 0 0.00
Markdown 1 400 82 0 318 0 0.00
─────────────────────────────────────────────────────────────────────────────────────────────────────────────
Total 17 4407 681 985 2741 128 126.86

I expected the Complexity/Lines for the Go-Files to be 128 / 2390 * 100 (=5.36) not 126.86

Did I misunderstand the Complexity/Lines figure?

@boyter
Copy link
Owner

boyter commented Jan 26, 2023

You are probably correct. Its one of those options I don't use very often. If you want to investigate it and supply the fix feel free, (you will get the glory of the fix too!) otherwise I will have a look when I get around to it in a week or two.

@boyter boyter added the bug Something isn't working label Jan 26, 2023
@astrodidge
Copy link
Author

thanks for answering my question. Sorry to say that I currently don't have the resources to investigate it. Anyway, a fix is not pressing for me. Feel free to look at the issue any time it suits you well.

@boyter
Copy link
Owner

boyter commented Jan 30, 2023

No problem. I will have a look soon.

@boyter boyter added this to ToDo in Release 3.2.0 Nov 27, 2023
@boyter boyter added this to TODO in Release 3.4.0 May 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Development

No branches or pull requests

2 participants