Skip to content

fix: Allow int keys in extra dict#426

Merged
untitaker merged 1 commit into
getsentry:masterfrom
vladlutkov:fix/int-in-extra
Jul 11, 2019
Merged

fix: Allow int keys in extra dict#426
untitaker merged 1 commit into
getsentry:masterfrom
vladlutkov:fix/int-in-extra

Conversation

@vladlutkov
Copy link
Copy Markdown
Contributor

If I pass dict with int keys in extra keyword argument

logger.warning('test', extra={1:1})

I'll get an exception and event will not be sent.

Copy link
Copy Markdown
Member

@untitaker untitaker left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch!

Could you add one test in test_logging.py?

Comment thread sentry_sdk/integrations/logging.py Outdated
@vladlutkov
Copy link
Copy Markdown
Contributor Author

I added a test

@untitaker
Copy link
Copy Markdown
Member

Sorry but could you run make format and make lint on this? It's not properly formatted. For more information see CONTRIBUTING.md

@untitaker untitaker self-assigned this Jul 11, 2019
@untitaker untitaker merged commit 880b860 into getsentry:master Jul 11, 2019
@untitaker
Copy link
Copy Markdown
Member

Thanks! Do you need a release for this right now or is this just something you happened to come by?

@vladlutkov
Copy link
Copy Markdown
Contributor Author

vladlutkov commented Jul 12, 2019

Thanks, I'm ready to wait until the next release.
Off-topic
Does the library only support python 3 and higher?
I did not find it in the documentation.

@untitaker
Copy link
Copy Markdown
Member

untitaker commented Jul 12, 2019 via email

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

Successfully merging this pull request may close these issues.

2 participants