Title: Fix case where string encoding overhead is larger than needed by nresare · Pull Request #108 · msgpack/msgpack-python · GitHub
Open Graph Title: Fix case where string encoding overhead is larger than needed by nresare · Pull Request #108 · msgpack/msgpack-python
X Title: Fix case where string encoding overhead is larger than needed by nresare · Pull Request #108 · msgpack/msgpack-python
Description: According to the spec "serializers SHOULD use the format which represents the data in the smallest number of bytes". This is not true for strings between 32 and (2^8)-1 bytes which has an encoding overhead of 3 bytes instead of the required 2. My guess is that the somewhat strange conditional in fallback.py:598 (and cython equivalent) is to make sure that old raw type test cases in test_case.py that test for encoding overhead succeeds. This commit updates the test case to test for the encoding overhead for both str and bin types of various lengths.
Open Graph Description: According to the spec "serializers SHOULD use the format which represents the data in the smallest number of bytes". This is not true for strings between 32 and (2^8)-1 bytes which has an...
X Description: According to the spec "serializers SHOULD use the format which represents the data in the smallest number of bytes". This is not true for strings between 32 and (2^8)-1 bytes whic...
Opengraph URL: https://github.com/msgpack/msgpack-python/pull/108
X: @github
Domain: patch-diff.githubusercontent.com
| route-pattern | /:user_id/:repository/pull/:id/files(.:format) |
| route-controller | pull_requests |
| route-action | files |
| fetch-nonce | v2:39885383-74c6-de80-068b-5bb460a84ad6 |
| current-catalog-service-hash | ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b |
| request-id | 83C8:16BD33:10B42AC:176307E:696FC718 |
| html-safe-nonce | 7ad2be7086879aef50bcd33a6e333b3338f041db08bd123f591609066450d0dd |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4M0M4OjE2QkQzMzoxMEI0MkFDOjE3NjMwN0U6Njk2RkM3MTgiLCJ2aXNpdG9yX2lkIjoiNTg1Mjg0Njg1NDgwNTM3NDc0NCIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 598ddb72dc3c34035b7323bc8135707d64eb5bf118902e49636e651811e0218c |
| hovercard-subject-tag | pull_request:22388124 |
| github-keyboard-shortcuts | repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/msgpack/msgpack-python/pull/108/files |
| twitter:image | https://avatars.githubusercontent.com/u/541939?s=400&v=4 |
| twitter:card | summary_large_image |
| og:image | https://avatars.githubusercontent.com/u/541939?s=400&v=4 |
| og:image:alt | According to the spec "serializers SHOULD use the format which represents the data in the smallest number of bytes". This is not true for strings between 32 and (2^8)-1 bytes which has an... |
| og:site_name | GitHub |
| og:type | object |
| hostname | github.com |
| expected-hostname | github.com |
| None | 330ca0f04ee8ecef1da04306a0dd49293f64679ee9a4bd5eaf2e1272bfdcf145 |
| turbo-cache-control | no-preview |
| diff-view | unified |
| go-import | github.com/msgpack/msgpack-python git https://github.com/msgpack/msgpack-python.git |
| octolytics-dimension-user_id | 198264 |
| octolytics-dimension-user_login | msgpack |
| octolytics-dimension-repository_id | 2242705 |
| octolytics-dimension-repository_nwo | msgpack/msgpack-python |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 2242705 |
| octolytics-dimension-repository_network_root_nwo | msgpack/msgpack-python |
| turbo-body-classes | logged-out env-production page-responsive full-width |
| disable-turbo | true |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 816ad575e27a390de2e2089ebe75261d12de9b37 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width