-
1. Re: VizAlert Error - ScannerError()
Matt ColesNov 6, 2015 3:40 PM (in response to Jose Alberto Salazar Reyna)
2 of 2 people found this helpfulHi Jose. The vizalerts.config file is mangled and no longer valid YAML format. I recommend running it through http://codebeautify.org/yaml-validator . Common issues are tabs accidentally being introduced (replace with spaces), or lines accidentally getting wrapped, quoted strings not being closed, and the like.
-
2. Re: VizAlert Error - ScannerError()
Matt ColesNov 9, 2015 3:33 PM (in response to Jose Alberto Salazar Reyna)
Were you able to get this resolved, Jose?
-
3. Re: VizAlert Error - ScannerError()
Jose Alberto Salazar Reyna Nov 9, 2015 4:34 PM (in response to Matt Coles)1 of 1 people found this helpfulYeah, when I edited the YAML file, probably I introduced some tab chars. It appears that tab chars are not allowed or wrong interpreted in these files.
thanks a lot Matt.
Regards
-
4. Re: VizAlert Error - ScannerError()
Toby ErksonNov 18, 2015 6:23 AM (in response to Jose Alberto Salazar Reyna)
Thanks for the answer, Jose This is good to know!
-
5. Re: VizAlert Error - ScannerError()
Sarah Slattery May 11, 2016 3:29 PM (in response to Matt Coles)Hi Matt,
I'm facing the same error. I ran it through the the yaml validator and it said it was valid. What's the best way to identify where the issues are occurring in the file?
Thanks,
Sarah
-
6. Re: VizAlert Error - ScannerError()
Matt ColesMay 11, 2016 3:40 PM (in response to Sarah Slattery)
It's odd how the yaml validators seem to be inconsistent with their ability to check for tab characters...I'm not sure why they aren't better. What I recommend is opening your yaml file in a text editor like Notepad++ and searching for the special character "\t" as a extended search (some call it regex):
Find all of the offenders and replace with spaces. 95% of the time, it fixes it every time.
-
7. Re: VizAlert Error - ScannerError()
Sarah Slattery May 12, 2016 10:19 AM (in response to Matt Coles) -
8. Re: VizAlert Error - ScannerError()
Matt ColesMay 12, 2016 10:22 AM (in response to Sarah Slattery)
Hmmm, not sure what else it might be off the top of my head. If you remove the sensitive info from your config file and attach it, I can take a look and see if I can figure it out.
-
9. Re: VizAlert Error - ScannerError()
gopinath.mukkapati May 12, 2016 11:10 AM (in response to Matt Coles)Hi Matt,
I'm also facing the same kind of issue. I have tried the above but could not see any issues in the file. Please let me know if you have any clue for me. I have attached my config file.
2016-05-11 14:35:15 - [INFO] - LoggerQuickSetup - Logging initialized, writing t
o .\logs\vizalerts.log_2016-05-11.log
An exception was raised loading the config file .\config\vizalerts.yaml: (<type
'exceptions.IOError'>, IOError(2, 'No such file or directory'), <traceback objec
t at 0x02A84620>) Stacktrace: <traceback object at 0x02A84620>
2016-05-11 14:35:15 - [ERROR] - validate_conf - An exception was raised loading
the config file .\config\vizalerts.yaml: (<type 'exceptions.IOError'>, IOError(2
, 'No such file or directory'), <traceback object at 0x02A84620>) Stacktrace: <t
raceback object at 0x02A84620>
2016-05-11 14:35:15 - [ERROR] - <module> - An unhandled exception occurred: Trac
eback (most recent call last):
File "E:\downloads\VizAlerts-master\vizalerts.py", line 1654, in <module>
main()
File "E:\downloads\VizAlerts-master\vizalerts.py", line 171, in main
configs = validate_conf(configfile, logger)
File "E:\downloads\VizAlerts-master\vizalerts.py", line 289, in validate_conf
sys.exit(1)
SystemExit: 1
Traceback (most recent call last):
File "E:\downloads\VizAlerts-master\vizalerts.py", line 1654, in <module>
main()
File "E:\downloads\VizAlerts-master\vizalerts.py", line 171, in main
configs = validate_conf(configfile, logger)
File "E:\downloads\VizAlerts-master\vizalerts.py", line 289, in validate_conf
sys.exit(1)
SystemExit: 1
Thanks,
Gopi
-
vizalerts.yaml.zip 4.0 KB
-
-
10. Re: VizAlert Error - ScannerError()
Sarah Slattery May 12, 2016 11:12 AM (in response to Matt Coles)Hi Matt,
I attached a copy of my yaml file with the sensitive data removed.
Thanks for your help!
Sarah
-
vizalerts-copy.yaml.zip 4.0 KB
-
-
11. Re: VizAlert Error - ScannerError()
Matt ColesMay 12, 2016 11:30 AM (in response to gopinath.mukkapati)
1 of 1 people found this helpfulGopi, your error appears to not be an issue with vizalerts.py not knowing where your config file is located, rather than a problem with the config file itself. Make sure that you are running VizAlerts from within the context of the root directory it lives in, as by default it uses a relative path to look for the config file. So if you have it in "E:\downloads\VizAlerts-master", make sure you're already working from that directory in your command shell:
cd E:\downloads\VizAlerts-master
python E:\downloads\VizAlerts-master\vizalerts.py
One thing I would say--change the server.version value in your config to just 9 rather than 9.2, as it only needs the major version, not the minor. Then I'd expect things to work.
-
12. Re: VizAlert Error - ScannerError()
Matt ColesMay 12, 2016 11:31 AM (in response to Sarah Slattery)
Thanks Sarah. I looked at yours and am baffled because everything looks fine to me. I'm going to do some troubleshooting to see if I can reproduce your problem, in the hopes I can figure out what is wrong.
-
13. Re: VizAlert Error - ScannerError()
Matt ColesMay 12, 2016 11:37 AM (in response to Sarah Slattery)
1 of 1 people found this helpfulOkay Sarah, I might have something. For smtp.alloweddomains , remove the "@" character from the beginning of "@xyz.com". It failed for me initially too, but I was able to get it to parse properly when I did that.
-
14. Re: VizAlert Error - ScannerError()
Sarah Slattery May 12, 2016 11:41 AM (in response to Matt Coles)This fixed the error! I'm getting other non-related error messages, but I might be able to work through those. Thanks!