We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Default encoding for JSON is UTF8 https://datatracker.ietf.org/doc/html/rfc7159#section-8.1
If you pass a file containing unicode chars to dollar_ref it will fail:
dollar_ref
/usr/local/lib/python3.6/dist-packages/dollar_ref/__init__.py:166: in resolve_file -- 51 | file_data = read_file(path) 52 | /usr/local/lib/python3.6/dist-packages/dollar_ref/__init__.py:197: in read_file 53 | raw = file.read() 54 | /usr/lib/python3.6/encodings/ascii.py:26: in decode 55 | return codecs.ascii_decode(input, self.errors)[0] 56 | E UnicodeDecodeError: 'ascii' codec can't decode byte 0xe2 in position 30017: ordinal not in range(128)
I guess the call to open needs encoding="utf8" here: https://github.com/bagrat/dollar-ref/blob/master/dollar_ref/__init__.py#L196
open
encoding="utf8"
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Default encoding for JSON is UTF8 https://datatracker.ietf.org/doc/html/rfc7159#section-8.1
If you pass a file containing unicode chars to
dollar_ref
it will fail:I guess the call to
open
needsencoding="utf8"
here: https://github.com/bagrat/dollar-ref/blob/master/dollar_ref/__init__.py#L196The text was updated successfully, but these errors were encountered: