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

Add built in server error retry handlers #1367

Merged
merged 3 commits into from
May 17, 2023

Conversation

digitalnomd
Copy link
Contributor

Summary

This pull request resolves #1364

Category (place an x in each of the [ ])

  • slack_sdk.web.WebClient (sync/async) (Web API client)
  • slack_sdk.webhook.WebhookClient (sync/async) (Incoming Webhook, response_url sender)
  • slack_sdk.socket_mode (Socket Mode client)
  • slack_sdk.signature (Request Signature Verifier)
  • slack_sdk.oauth (OAuth Flow Utilities)
  • slack_sdk.models (UI component builders)
  • slack_sdk.scim (SCIM API client)
  • slack_sdk.audit_logs (Audit Logs API client)
  • slack_sdk.rtm_v2 (RTM client)
  • /docs-src (Documents, have you run ./scripts/docs.sh?)
  • /docs-src-v2 (Documents, have you run ./scripts/docs-v2.sh?)
  • /tutorial (PythOnBoardingBot tutorial)
  • tests/integration_tests (Automated tests for this library)

Requirements (place an x in each [ ])

  • I've read and understood the Contributing Guidelines and have done my best effort to follow them.
  • I've read and agree to the Code of Conduct.
  • I've run python3 -m venv .venv && source .venv/bin/activate && ./scripts/run_validation.sh after making the changes.

@salesforce-cla
Copy link

Thanks for the contribution! Before we can merge this, we need @digitalnomd to sign the Salesforce Inc. Contributor License Agreement.

@seratch seratch self-assigned this May 11, 2023
@seratch seratch added enhancement M-T: A feature request for new functionality web-client Version: 3x labels May 11, 2023
@seratch seratch added this to the 3.22.0 milestone May 11, 2023
digitalnomd and others added 2 commits May 11, 2023 14:32
Co-authored-by: Kazuhiro Sera <seratch@gmail.com>
Co-authored-by: Kazuhiro Sera <seratch@gmail.com>
@seratch
Copy link
Member

seratch commented May 11, 2023

We already have a few unit tests for the built-in retry handlers. If you could add some for the new handler, it'd be greatly appreciated. Otherwise, I can add some tests when merging your changes.

@codecov
Copy link

codecov bot commented May 11, 2023

Codecov Report

Merging #1367 (485a33e) into main (7eec685) will decrease coverage by 0.04%.
The diff coverage is 60.00%.

❗ Current head 485a33e differs from pull request most recent head 3738060. Consider uploading reports for the commit 3738060 to get more accurate results

@@            Coverage Diff             @@
##             main    #1367      +/-   ##
==========================================
- Coverage   85.58%   85.55%   -0.04%     
==========================================
  Files         111      111              
  Lines       11559    11569      +10     
==========================================
+ Hits         9893     9898       +5     
- Misses       1666     1671       +5     
Impacted Files Coverage Δ
slack_sdk/http_retry/builtin_async_handlers.py 91.30% <60.00%> (-3.82%) ⬇️
slack_sdk/http_retry/builtin_handlers.py 91.48% <60.00%> (-3.75%) ⬇️

... and 1 file with indirect coverage changes

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

@seratch
Copy link
Member

seratch commented May 17, 2023

Thanks for taking your time to make this PR! After merging the changes, I will add a few unit tests for them

@seratch seratch merged commit ad37094 into slackapi:main May 17, 2023
maximkir-fl added a commit to maximkir-fl/python-slack-sdk that referenced this pull request May 23, 2023
Co-authored-by: Kazuhiro Sera <seratch@gmail.com>
seratch added a commit to seratch/python-slack-sdk that referenced this pull request May 29, 2023
seratch added a commit that referenced this pull request May 29, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cla:signed enhancement M-T: A feature request for new functionality Version: 3x web-client
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add retry handler for 500s to WebClient by default
2 participants