Skip to content

Commit

Permalink
Trivial
Browse files Browse the repository at this point in the history
  • Loading branch information
kebwi committed Oct 3, 2024
1 parent 0df178c commit 499e906
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions caveclient/skeletonservice.py
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,7 @@ def compressStringToBytes(inputString):
"""
Shamelessly copied from SkeletonService to avoid importing the entire repo. Consider pushing these utilities to a separate module.
REF: https://stackoverflow.com/questions/15525837/which-is-the-best-way-to-compress-json-to-store-in-a-memory-based-store-like-red
read the given string, encode it in utf-8,
compress the data and return it as a byte array.
read the given string, encode it in utf-8, compress the data and return it as a byte array.
"""
bio = BytesIO()
bio.write(inputString.encode("utf-8"))
Expand Down Expand Up @@ -184,8 +183,7 @@ def decompressBytesToString(inputBytes):
"""
Shamelessly copied from SkeletonService to avoid importing the entire repo. Consider pushing these utilities to a separate module.
REF: https://stackoverflow.com/questions/15525837/which-is-the-best-way-to-compress-json-to-store-in-a-memory-based-store-like-red
decompress the given byte array (which must be valid
compressed gzip data) and return the decoded text (utf-8).
decompress the given byte array (which must be valid compressed gzip data) and return the decoded text (utf-8).
"""
bio = BytesIO()
stream = BytesIO(inputBytes)
Expand Down

0 comments on commit 499e906

Please sign in to comment.