Skip to content

fix💥: don't pass kwargs to modal callbacks #1584

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

Closed

Conversation

AstreaTSS
Copy link
Member

Pull Request Type

  • Feature addition
  • Bugfix
  • Documentation update
  • Code refactor
  • Tests improvement
  • CI/CD pipeline enhancement
  • Other: [Replace with a description]

Description

This PR fixes #1517 by making sure ctx.kwargs is not passed into modal callbacks. While this behavior was unintended, this change is breaking, hence the draft status.

Changes

  • Override call_callback in ModalCommand so that the actual callback does not receive **ctx.kwargs.

Related Issues

Fixes #1517.

Test Scenarios

See bug report.

Python Compatibility

  • I've ensured my code works on Python 3.10.x
  • I've ensured my code works on Python 3.11.x

Checklist

  • I've run the pre-commit code linter over all edited files
  • I've tested my changes on supported Python versions
  • I've added tests for my code, if applicable
  • I've updated / added documentation, where applicable

@AstreaTSS AstreaTSS changed the base branch from stable to unstable November 30, 2023 23:11
@i0bs i0bs requested a review from Developer89899 December 1, 2023 01:18
@eightween eightween added enhancement New feature or request breaking This contains breaking changes on hold This issue/PR is on hold pending higher priority issues/PRs labels Dec 9, 2023
AstreaTSS added a commit to AstreaTSS/interactions-py-library that referenced this pull request Feb 21, 2024
@AstreaTSS
Copy link
Member Author

Closing as #1619 supersedes this as a non-breaking change. That being said, this should be done at some time.

@AstreaTSS AstreaTSS closed this Feb 21, 2024
@AstreaTSS AstreaTSS deleted the modal-callback-fix branch March 17, 2024 04:49
eightween pushed a commit that referenced this pull request Apr 24, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking This contains breaking changes enhancement New feature or request on hold This issue/PR is on hold pending higher priority issues/PRs
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[BUG] modal_callback
2 participants