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

[ServiceBus] Fix mktime overflow and milliseconds miscalculation issue #19437

Merged
merged 3 commits into from
Jun 29, 2021

Conversation

yunhaoling
Copy link
Contributor

@yunhaoling yunhaoling commented Jun 24, 2021

fixing issue: #19297

  • on ubuntu 20.04, mktime(datetime.now(msrest.serialization.UTC()).timetuple()) would trigger Overflow. we should use msrest.serialization.TZ_UTC instead which will use the python built-in timezone info to avoid the issue.
  • according to the AMQP spec, creation_time and absoulate_expiry_time should be calculated in the unit of millisecond.

@yunhaoling
Copy link
Contributor Author

/azp run python - servicebus - tests

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Member

@swathipil swathipil left a comment

Choose a reason for hiding this comment

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

LG(great)TM

@yunhaoling
Copy link
Contributor Author

/azp run python - servicebus - tests

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@yunhaoling
Copy link
Contributor Author

/azp run python - servicebus - tests

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@yunhaoling yunhaoling merged commit 293c121 into Azure:main Jun 29, 2021
@yunhaoling yunhaoling deleted the yuling/sb/mktime-issue branch June 29, 2021 08:20
rakshith91 pushed a commit to rakshith91/azure-sdk-for-python that referenced this pull request Jul 16, 2021
Azure#19437)

* fix utc and milliseconds issue

* fix python2.7

* update uamqp dependency to 1.4.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants