Skip to content

better document StripeObject's to_dict behavior - #1879

Merged
xavdid merged 2 commits into
masterfrom
RUN_DEVSDK-2736
Aug 18, 2026
Merged

better document StripeObject's to_dict behavior#1879
xavdid merged 2 commits into
masterfrom
RUN_DEVSDK-2736

Conversation

@xavdid

@xavdid xavdid commented Aug 18, 2026

Copy link
Copy Markdown
Member

Why?

While the transition away from dict as the base class for StripeObject has gone well, there have been a few small papercuts using the new objects that we could improve. Specifically, we could steer users towards the correct method if they try to use a StripeObject as a dict.

This PR doesn't raise errors where there weren't any before, but it does provide better guidance in the error messages.

What?

  • update readme
  • add docstrings
  • throw more specific error when a dict method is accessed

See Also

@xavdid xavdid changed the title better document stripeobject's to_dict behavior better document StripeObject's to_dict behavior Aug 18, 2026
@xavdid
xavdid marked this pull request as ready for review August 18, 2026 22:38
@xavdid
xavdid requested a review from a team as a code owner August 18, 2026 22:38
@xavdid
xavdid requested review from jar-stripe and zacchua-stripe and removed request for a team and jar-stripe August 18, 2026 22:38
@xavdid
xavdid enabled auto-merge (squash) August 18, 2026 22:39
@xavdid
xavdid merged commit 7496611 into master Aug 18, 2026
18 checks passed
@xavdid
xavdid deleted the RUN_DEVSDK-2736 branch August 18, 2026 23:44
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