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

Does not work properly with Sentry onpremise 20.9.0 #40

Open
kona-automacon opened this issue Sep 8, 2020 · 4 comments
Open

Does not work properly with Sentry onpremise 20.9.0 #40

kona-automacon opened this issue Sep 8, 2020 · 4 comments

Comments

@kona-automacon
Copy link

After migrating from version 8.22 to 20.9.0 sentry-telegram plugin no longer inserts {message} from issues into message body.
Messages sent by "Test Plugin" button are delivered correctly with {message}.
But messages from "real" alerts are delivered with empty {message} name.
As I understand it, this problem is related to changes in Sentry SDK.

def build_message(self, group, event):
the_tags = defaultdict(lambda: '[NA]')
the_tags.update({k:v for k, v in event.tags})
names = {
'title': event.title,
'tag': the_tags,
'message': event.message, <---- no longer work for issues in last versions.
'project_name': group.project.name,
'url': group.get_absolute_url(),
}

@gituser
Copy link

gituser commented Dec 21, 2020

Try installing sentry by using Python2 instead of Python3 (which is default for some time):

SENTRY_PYTHON2=1 ./install.sh

Then the plugin should work.

Or try this fix - #41

@kona-automacon
Copy link
Author

I have not tested solution with Python2.
But I'm afraid it doesn't make sense anymore, because: "Sentry uses Python 3 by default since December 4th, 2020 and Sentry 21.1.0 is the last version to support Python 2."

@Olegt0rr
Copy link

Try installing sentry by using Python2 instead of Python3 (which is default for some time):

Python 2 R.I.P

@gituser
Copy link

gituser commented Feb 25, 2021

@Olegt0rr in this case telegram plugin won't work for you.

There is a fix for python 3.6+ - #41

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

No branches or pull requests

3 participants