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

"unknown file" reported as module when exceptions raised by sensor #5061

Open
amanda11 opened this issue Oct 15, 2020 · 1 comment
Open

"unknown file" reported as module when exceptions raised by sensor #5061

amanda11 opened this issue Oct 15, 2020 · 1 comment
Labels

Comments

@amanda11
Copy link
Contributor

amanda11 commented Oct 15, 2020

SUMMARY

Error messages generated by sensor result in "unknown file" instead of module names on python 3 systems, e.g.

2020-10-15 08:22:43,653 139699041297216 ERROR (unknown file) [-] File "/opt/stackstorm/packs/openstack/sensors/messaging_sensor.py", line 52, in poll

STACKSTORM VERSION

3.3dev and 3.2.0

OS, environment, install method

Ubuntu 18.04, Single node install from ansible.

Steps to reproduce the problem

One easy way to get an exception from sensor:

  1. Install StackStorm
  2. Install OpenStack pack - but don't configure it's config file
  3. The openstack sensor will raise an exception as it can't locate the OS parametrs.
  4. Examine the /var/log/st2/st2sensorcontainer.log

Expected Results

Log the exception message in the test should not report "unknown file" for module.

Actual Results

"unknown file" is reported on the ERROR lines, eg


2020-10-15 08:22:43,653 139699041297216 ERROR (unknown file) [-] File "/opt/stackstorm/packs/openstack/sensors/messaging_sensor.py", line 52, in poll
@amanda11 amanda11 added the bug label Oct 15, 2020
@amanda11
Copy link
Contributor Author

A similar problems was seen on all messages in the st2 logs on python 3, and the fix was #5058. It is therefore probable that it is a similar problem whereby a logger method that is over-ridden has different return tuples for python3 and python 2.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant