Skip to content

Conversation

@harshil21
Copy link
Member

Moves the logic of TO.to_dict in subclasses to TelegramObject itself, which was mainly dealing with sequences and converting datetimes to timestamps.

Checklist for PRs

  • Added .. versionadded:: version, .. versionchanged:: version or .. deprecated:: version to the docstrings for user facing changes (for methods/class descriptions, arguments and attributes)
  • Created new or adapted existing unit tests
  • Documented code changes according to the CSI standard
  • Added new classes & modules to the docs and all suitable __all__ s

@harshil21 harshil21 added this to the v20.0a5 milestone Nov 9, 2022
@harshil21 harshil21 added the 🛠 refactor change type: refactor label Nov 9, 2022
Copy link
Member

@Bibo-Joshi Bibo-Joshi left a comment

Choose a reason for hiding this comment

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

Nice, and it's not even fridy 🥳 Could you also extend the to_dict tests to make sure that the recursive setting now properly extends to the (nested) lists?

@harshil21
Copy link
Member Author

Could you also extend the to_dict tests to make sure that the recursive setting now properly extends to the (nested) lists?

This is already tested in the classes which have those, e.g. test_to_dict in test_inlinekeyboardmarkup.

Copy link
Member

@Bibo-Joshi Bibo-Joshi left a comment

Choose a reason for hiding this comment

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

DS failure is unrelated. When the tests pass, this LGTM :)

@harshil21 harshil21 added the 📋 pending-merge work status: pending-merge label Nov 11, 2022
@Bibo-Joshi Bibo-Joshi merged commit e54c6a0 into master Nov 13, 2022
@Bibo-Joshi Bibo-Joshi deleted the rm-extra-to-dict branch November 13, 2022 20:28
@harshil21 harshil21 removed the 📋 pending-merge work status: pending-merge label Nov 18, 2022
@github-actions github-actions bot locked and limited conversation to collaborators Nov 26, 2022
@Bibo-Joshi Bibo-Joshi added 🔌 enhancement pr description: enhancement and removed enhancement labels Nov 3, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

🔌 enhancement pr description: enhancement 🛠 refactor change type: refactor

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants