Merge pull request #2098 from faizanrashid/issue-1741

[BUG] [MINOR] Use buffer for specific py versions