New issue
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
msgpackffi does not respect msgpack.cfg options #4499
Comments
Gerold103
added
bug
Something isn't working
app
good first issue
Good for newcomers
labels
Sep 13, 2019
MariaHajdic
added a commit
that referenced
this issue
Sep 25, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Sep 25, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Sep 25, 2019
… of https://github.com/tarantool/tarantool into eljashm/gh-4499-msgpackffi-ignores-msgpack.cfg-options
MariaHajdic
added a commit
that referenced
this issue
Nov 6, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 20, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 20, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 25, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 29, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 29, 2019
Lua serializers have common configuration options that mostly were not respected in msgpackffi module. This patch fixes that for several configurations: encode_use_tostring, encode_invalid_as_nil and encode_load_metatables. Options encode/decode_invalid_numbers are suggested to not be considered in msgpackffi module since lua processed them properly without this check so adding it would mean cutting functionality provided by the language in case this field was set to be false. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Nov 29, 2019
Msgpack.cfg options changes did not affect msgpackffi serializer state. This patch fixes it for options encode_load_metatables, decode_ and encode_invalid_numbers, encode_use_tostring and encode_invalid_as_nil. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Dec 24, 2019
Msgpack.cfg options changes did not affect msgpackffi serializer state. This patch fixes it for options encode_load_metatables, decode_ and encode_invalid_numbers, encode_use_tostring and encode_invalid_as_nil. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Jan 18, 2020
Msgpack.cfg options changes did not affect msgpackffi serializer state. This patch fixes it for options encode_load_metatables, decode_ and encode_invalid_numbers, encode_use_tostring and encode_invalid_as_nil. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Jan 24, 2020
Msgpack.cfg reconfiguration did not affect ffi module behavior. This patch fixes it for all the options that were not yet covered elsewhere: encode_sparse_convert, encode_sparse_ratio, encode_sparse_safe, encode_invalid_numbers & decode_invalid_numbers, encode_load_metatables & decode_save_metatables, encode_use_tostring, encode_invalid_as_nil. Most of common serializers' test were not applicable to msgpackffi since it has no cfg field of its own. This issue was also solved. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Jan 24, 2020
Msgpack.cfg reconfiguration did not affect ffi module behavior. This patch fixes it for all the options that were not yet covered elsewhere: encode_sparse_convert, encode_sparse_ratio, encode_sparse_safe, encode_invalid_numbers & decode_invalid_numbers, encode_load_metatables & decode_save_metatables, encode_use_tostring, encode_invalid_as_nil. Most of common serializers' test were not applicable to msgpackffi since it has no cfg field of its own. This issue was also solved. Closes #4499
MariaHajdic
added a commit
that referenced
this issue
Jan 27, 2020
Msgpack.cfg reconfiguration did not affect ffi module behavior. This patch fixes it for all the options that were not yet covered elsewhere: encode_sparse_convert, encode_sparse_ratio, encode_sparse_safe, encode_invalid_numbers & decode_invalid_numbers, encode_load_metatables & decode_save_metatables, encode_use_tostring, encode_invalid_as_nil. Most of common serializers' test were not applicable to msgpackffi since it has no cfg field of its own. This issue was also solved. Closes #4499
I propose to consider this issue as blocked and solve the following questions first:
|
Totktonada
added
blocked
Not ready to be implemented
and removed
good first issue
Good for newcomers
labels
Jul 20, 2021
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 14, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 14, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 15, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 16, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 16, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
to locker/tarantool
that referenced
this issue
Sep 17, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see tarantool#4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes tarantool#6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
locker
added a commit
that referenced
this issue
Sep 17, 2021
This patch adds a new msgpack.cfg: encode_error_as_ext. Setting it makes msgpack and msgpackffi modules encode errors as the MP_ERROR msgpack extension. If the flag is unset, msgpack.encode behavior depends on encode_load_metatables, encode_use_tostring, and encode_invalid_as_nil options, see luaL_convertfield(), while msgpackffi.encode() will always encode errors as strings. The latter needs to be fixed, but it's out of the scope of this work and tracked separately, see #4499. The new option is enabled by default. Interaction with box.session.settings.error_marshaling_enabled: errors are encoded as the MP_ERROR msgpack extension when returned via IPROTO iff both error_marshaling_enabled and encode_error_as_ext are set. Closes #6433 @TarantoolBot document Title: Document msgpack.cfg.encode_error_as_ext The new option determines how error objects (see box.error.new) are encoded in the msgpack format: - If it's set, errors are encoded as the MP_ERROR msgpack extension. This is the default behavior. - If it's unset, the encoded format depends on other msgpack configuration options (encode_load_metatables, encode_use_tostring, encode_invalid_as_nil). With the otherwise default configuration, they are encoded as strings (see error.message). Functions affected by the default configuration (msgpack.cfg): - msgpack and msgpackffi modules - Storing errors in tuples and spaces (box.tuple.new) - Returning errors from IPROTO CALL/EVAL
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
#4434 fixes it for
encode_max_depth
, but other options are still ignored. It should be either fixed or documented. I think, a fix is better.The text was updated successfully, but these errors were encountered: