Prefer static_format over format with static assets #17

Merged
Astrea49 merged 1 commits from 2.0 into 2.0 2021-09-01 02:26:32 +00:00
Astrea49 commented 2021-08-28 22:28:23 +00:00 (Migrated from github.com)

Summary

In short: something like Asset.replace(format='gif',static_format='png') would break if it encountered a static asset, as static avatars cannot be stored in a GIF format and d.py preferred to use the format format vs. the static_format format, even with static assets. According to Danny, this was an intentional feature, but I personally do not see how keeping the old behavior would be beneficial to anyone at all.
Link to old issue: #7345

Checklist

  • If code changes were made then they have been tested.
    • I have updated the documentation to reflect the changes.
  • This PR fixes an issue.
  • This PR adds something new (e.g. new method or parameters).
  • This PR is a breaking change (e.g. methods or parameters removed/renamed)
  • This PR is not a code change (e.g. documentation, README, ...)
## Summary In short: something like `Asset.replace(format='gif',static_format='png')` would break if it encountered a static asset, as static avatars cannot be stored in a GIF format and d.py preferred to use the `format` format vs. the `static_format` format, even with static assets. According to Danny, this was an intentional feature, but I personally do not see how keeping the old behavior would be beneficial to anyone at all. Link to old issue: [#7345](https://github.com/Rapptz/discord.py/issues/7345) ## Checklist <!-- Put an x inside [ ] to check it, like so: [x] --> - [x] If code changes were made then they have been tested. - [ ] I have updated the documentation to reflect the changes. - [ ] This PR fixes an issue. - [ ] This PR adds something new (e.g. new method or parameters). - [x] This PR is a breaking change (e.g. methods or parameters removed/renamed) - [ ] This PR is **not** a code change (e.g. documentation, README, ...)
paris-ci commented 2021-08-28 22:33:12 +00:00 (Migrated from github.com)

Sounds good to me!

Sounds good to me!
paris-ci (Migrated from github.com) approved these changes 2021-08-28 22:34:29 +00:00
WhoTheOOF (Migrated from github.com) approved these changes 2021-08-28 22:56:17 +00:00
WhoTheOOF (Migrated from github.com) left a comment

Looks good.

Looks good.
Sign in to join this conversation.
No description provided.