Closed mosesliao closed 6 years ago
Yes. Will come back to this soon.
On 28 Feb 2018, at 12:58 PM, Liao Gangzheng Moses notifications@github.com wrote:
I tried to run lizard --ignore_warnings 2 to a project that has more than 2 warnings but it still goes through. Can you look into it? I need this to work.
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/terryyin/lizard/issues/223, or mute the thread https://github.com/notifications/unsubscribe-auth/AAwJYgM6YkAitHhjJweoKDSNw6BYOMyjks5tZNzcgaJpZM4SWE-C.
it seems the status code is 1 for me here. Can you give a bit more information for me to reproduce this?
I run lizard -l swift --ignore_warnings 2 jarvis
. it produce the following warning
!!!! Warnings (cyclomatic_complexity > 15 or length > 1000 or parameter_count > 100) !!!!
================================================
NLOC CCN token PARAM length location
------------------------------------------------
129 19 914 1 170 validateAll@187-356@jarvis/OpenAccountPremiseViewController.swift
60 16 405 1 77 textFieldDidEndEditing@451-527@jarvis/OpenAccountAccountInformationViewController.swift
64 20 306 0 84 toJSON@181-264@jarvis/AccountOpeningRequest.swift
75 34 353 0 76 get@253-328@jarvis/APIClientRouter.swift
100 32 1089 0 116 asURLRequest@343-458@jarvis/APIClientRouter.swift
44 17 292 2 48 cell@162-209@jarvis/SubmitMeterSectionController.swift
==========================================================================================
Still the script goes through without throwing an error
then I run this in irb it throws an error which I wanted
irb(main):017:0> `lizard -l swift --ignore_warnings a jarvis`
usage: lizard [options] [PATH or FILE] [PATH] ...
/usr/local/bin/lizard: error: argument -i/--ignore_warnings: invalid int value: 'a'
=> ""
Ok I know what is the problem now. closing issue
I tried to run
lizard --ignore_warnings 2
to a project that has more than 2 warnings but it still goes through. Can you look into it? I need this to work.I cannot force my CI to stop if this feature is not working