Skip to content

Commit

Permalink
Add common symbols to safe param symbols (#14)
Browse files Browse the repository at this point in the history
* Add common symbols to safe param symbols

Closes #13

* Add #13 patch to generate.sh
  • Loading branch information
Katistic authored Jan 11, 2024
1 parent e421f0b commit 3795aff
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 2 deletions.
5 changes: 4 additions & 1 deletion generate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -32,4 +32,7 @@ find vrchatapi -type f -exec sed -i '/VRChat API Banner/d' {} \;
patch ./vrchatapi/rest.py < ./patches/cookiejar.patch

# Make 2fa required error readable
patch ./vrchatapi/rest.py < ./patches/error_2fa_verify_readable.patch
patch ./vrchatapi/rest.py < ./patches/error_2fa_verify_readable.patch

# Add common symbols to safe path parameter symbols
patch ./vrchatapi/configuration.py < ./patches/safe_param_symbols.patch.patch
13 changes: 13 additions & 0 deletions patches/safe_param_symbols.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
diff --git a/vrchatapi/configuration.py b/vrchatapi/configuration.py
index 4d594f94..70354d29 100644
--- a/vrchatapi/configuration.py
+++ b/vrchatapi/configuration.py
@@ -221,7 +221,7 @@ conf = vrchatapi.Configuration(
self.proxy_headers = None
"""Proxy headers
"""
- self.safe_chars_for_path_param = ''
+ self.safe_chars_for_path_param = '~()'
"""Safe chars for path_param
"""
self.retries = None
2 changes: 1 addition & 1 deletion vrchatapi/configuration.py
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,7 @@ def __init__(self, host=None,
self.proxy_headers = None
"""Proxy headers
"""
self.safe_chars_for_path_param = ''
self.safe_chars_for_path_param = '~()'
"""Safe chars for path_param
"""
self.retries = None
Expand Down

0 comments on commit 3795aff

Please sign in to comment.