GLEF1X / glQiwiApi

🥝 The ultrarapid and multifunctional wrapper over QIWI and YooMoney
https://glqiwiapi.readthedocs.io/en/latest/
MIT License
82 stars 11 forks source link

Optimize classes by adding `__slots__` #102

Open GLEF1X opened 1 year ago

GLEF1X commented 1 year ago

Benchmarks show that adding __slots__ to the classes reduce memory usage by 4-6%.

Without __slots__:

old

With it:

new

lgtm-com[bot] commented 1 year ago

This pull request fixes 17 alerts when merging e6d24ebecb57d08addbd94009398f20d1df3ab9f into fcb9a93d12a15b37a95e485f861a72025b571180 - view on LGTM.com

fixed alerts:

Heads-up: LGTM.com's PR analysis will be disabled on the 5th of December, and LGTM.com will be shut down ⏻ completely on the 16th of December 2022. It looks like GitHub code scanning with CodeQL is already set up for this repo, so no further action is needed :rocket:. For more information, please check out our post on the GitHub blog.