Skip to content

Commit 26da617

Browse files
committed
Merge pull request #17574 from ydb-platform/merge-libs-250423-0050
2 parents f200790 + 993139c commit 26da617

File tree

114 files changed

+1512
-544
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

114 files changed

+1512
-544
lines changed

build/mapping.conf.json

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1373,6 +1373,7 @@
13731373
"8367004015": "{registry_endpoint}/8367004015",
13741374
"8418036683": "{registry_endpoint}/8418036683",
13751375
"8435535653": "{registry_endpoint}/8435535653",
1376+
"8559585510": "{registry_endpoint}/8559585510",
13761377
"2980468199": "{registry_endpoint}/2980468199",
13771378
"5562224408": "{registry_endpoint}/5562224408",
13781379
"7663495611": "{registry_endpoint}/7663495611"
@@ -2747,6 +2748,7 @@
27472748
"8367004015": "yt/go/ytrecipe/cmd/ytexec for linux",
27482749
"8418036683": "yt/go/ytrecipe/cmd/ytexec for linux",
27492750
"8435535653": "yt/go/ytrecipe/cmd/ytexec for linux",
2751+
"8559585510": "yt/go/ytrecipe/cmd/ytexec for linux",
27502752
"2980468199": "ytexec for linux",
27512753
"5562224408": "ytexec for linux",
27522754
"7663495611": "ytexec for linux"

contrib/libs/simdjson/.yandex_meta/devtools.licenses.report

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ BELONGS ya.make
4242
Match type : REFERENCE
4343
Links : http://www.boost.org/LICENSE_1_0.txt, http://www.boost.org/users/license.html, https://spdx.org/licenses/BSL-1.0
4444
Files with this license:
45-
README.md [234:234]
45+
README.md [235:235]
4646

4747
KEEP MIT 0a00f0d66f4f37595306dd8c6a25c63c
4848
BELONGS ya.make
@@ -54,7 +54,7 @@ BELONGS ya.make
5454
Match type : NOTICE
5555
Links : http://opensource.org/licenses/mit-license.php, https://spdx.org/licenses/MIT
5656
Files with this license:
57-
README.md [230:230]
57+
README.md [231:231]
5858

5959
SKIP LicenseRef-scancode-unknown-license-reference 0d48e0b09865a98a90db20ea37b36bb8
6060
BELONGS ya.make
@@ -66,7 +66,7 @@ BELONGS ya.make
6666
Match type : INTRO
6767
Links : https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/unknown-license-reference.LICENSE
6868
Files with this license:
69-
README.md [238:238]
69+
README.md [239:239]
7070

7171
KEEP Apache-2.0 13ec3cccf3036f38df47d2051a825972
7272
BELONGS ya.make
@@ -102,7 +102,7 @@ BELONGS ya.make
102102
Match type : REFERENCE
103103
Links : http://www.apache.org/licenses/, http://www.apache.org/licenses/LICENSE-2.0, https://spdx.org/licenses/Apache-2.0
104104
Files with this license:
105-
README.md [214:214]
105+
README.md [215:215]
106106

107107
SKIP BSL-1.0 2a9212d785cde4078c2f6803e544de21
108108
BELONGS ya.make
@@ -113,7 +113,7 @@ BELONGS ya.make
113113
Match type : REFERENCE
114114
Links : http://www.boost.org/LICENSE_1_0.txt, http://www.boost.org/users/license.html, https://spdx.org/licenses/BSL-1.0
115115
Files with this license:
116-
README.md [234:234]
116+
README.md [235:235]
117117

118118
KEEP MIT 3e1ede6948a97e7ee3d75e0204a567f3
119119
BELONGS ya.make
@@ -125,7 +125,7 @@ BELONGS ya.make
125125
Match type : TAG
126126
Links : http://opensource.org/licenses/mit-license.php, https://spdx.org/licenses/MIT
127127
Files with this license:
128-
README.md [218:218]
128+
README.md [219:219]
129129

130130
SKIP Apache-2.0 500a503129337bb5adf5977ce11879cd
131131
BELONGS ya.make
@@ -137,7 +137,7 @@ BELONGS ya.make
137137
Match type : NOTICE
138138
Links : http://www.apache.org/licenses/, http://www.apache.org/licenses/LICENSE-2.0, https://spdx.org/licenses/Apache-2.0
139139
Files with this license:
140-
README.md [230:230]
140+
README.md [231:231]
141141

142142
SKIP BSL-1.0 77dd56e30840a227692d435b4aecdb95
143143
BELONGS ya.make
@@ -148,11 +148,11 @@ BELONGS ya.make
148148
Match type : REFERENCE
149149
Links : http://www.boost.org/LICENSE_1_0.txt, http://www.boost.org/users/license.html, https://spdx.org/licenses/BSL-1.0
150150
Files with this license:
151-
README.md [234:234]
151+
README.md [235:235]
152152

153153
KEEP MIT 7f0bdbc0a0545831259b66259ac6b604
154154
BELONGS ya.make
155-
FILE_INCLUDE LICENSE-MIT found in files: README.md at line 217
155+
FILE_INCLUDE LICENSE-MIT found in files: README.md at line 218
156156
License text:
157157
[licensemit]: LICENSE-MIT
158158
Scancode info:
@@ -161,7 +161,7 @@ FILE_INCLUDE LICENSE-MIT found in files: README.md at line 217
161161
Match type : TAG
162162
Links : http://opensource.org/licenses/mit-license.php, https://spdx.org/licenses/MIT
163163
Files with this license:
164-
README.md [217:217]
164+
README.md [218:218]
165165

166166
KEEP Apache-2.0 82e76bbc1841bd5886297e795c72bfa5
167167
BELONGS ya.make
@@ -173,7 +173,7 @@ BELONGS ya.make
173173
Match type : REFERENCE
174174
Links : http://www.apache.org/licenses/, http://www.apache.org/licenses/LICENSE-2.0, https://spdx.org/licenses/Apache-2.0
175175
Files with this license:
176-
README.md [230:230]
176+
README.md [231:231]
177177

178178
KEEP MIT a6e9f2d79eb73e6e422759b53da6152a
179179
BELONGS ya.make
@@ -208,7 +208,7 @@ BELONGS ya.make
208208
Match type : NOTICE
209209
Links : http://opensource.org/licenses/mit-license.php, https://spdx.org/licenses/MIT
210210
Files with this license:
211-
README.md [236:236]
211+
README.md [237:237]
212212

213213
SKIP Apache-2.0 c23a044f4165feb9568f486ca3b30fc8
214214
BELONGS ya.make
@@ -219,7 +219,7 @@ BELONGS ya.make
219219
Match type : NOTICE
220220
Links : http://www.apache.org/licenses/, http://www.apache.org/licenses/LICENSE-2.0, https://spdx.org/licenses/Apache-2.0
221221
Files with this license:
222-
README.md [234:234]
222+
README.md [235:235]
223223

224224
SKIP BSD-3-Clause d77bd60dc7ee5f9c3b221f6edd94bbac
225225
BELONGS ya.make
@@ -231,7 +231,7 @@ BELONGS ya.make
231231
Match type : REFERENCE
232232
Links : http://www.opensource.org/licenses/BSD-3-Clause, https://spdx.org/licenses/BSD-3-Clause
233233
Files with this license:
234-
README.md [238:238]
234+
README.md [239:239]
235235

236236
SKIP MIT dd09705e3ec59af63c705c8f5f3eadb2
237237
BELONGS ya.make
@@ -243,7 +243,7 @@ BELONGS ya.make
243243
Match type : REFERENCE
244244
Links : http://opensource.org/licenses/mit-license.php, https://spdx.org/licenses/MIT
245245
Files with this license:
246-
README.md [232:232]
246+
README.md [233:233]
247247

248248
KEEP MIT f0fe4686586f118327c3bc63fe4027de
249249
BELONGS ya.make

contrib/libs/simdjson/.yandex_meta/override.nix

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
pkgs: attrs: with pkgs; rec {
2-
version = "3.12.2";
2+
version = "3.12.3";
33

44
src = fetchFromGitHub {
55
owner = "simdjson";
66
repo = "simdjson";
77
rev = "v${version}";
8-
hash = "sha256-TjUPySFwwTlD4fLpHoUywAeWvVvi7Hg1wxzgE9vohrs=";
8+
hash = "sha256-/FfaM5BTWKrt2m70+VcUXz//RiZuzxnUOaHOjPJWsGw=";
99
};
1010

1111
cmakeFlags = attrs.cmakeFlags ++ [

contrib/libs/simdjson/CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -92,7 +92,7 @@ We welcome contributions from women and less represented groups. If you need hel
9292

9393
Consider the following points when engaging with the project:
9494

95-
- We discourage arguments from authority: ideas are discusssed on their own merits and not based on who stated it.
95+
- We discourage arguments from authority: ideas are discussed on their own merits and not based on who stated it.
9696
- Be mindful that what you may view as an aggression is maybe merely a difference of opinion or a misunderstanding.
9797
- Be mindful that a collection of small aggressions, even if mild in isolation, can become harmful.
9898

contrib/libs/simdjson/README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,8 @@ We distinguish between "bindings" (which just wrap the C++ code) and a port to a
173173
- [simdjsone](https://github.com/saleyn/simdjsone): erlang bindings.
174174
- [lua-simdjson](https://github.com/FourierTransformer/lua-simdjson): lua bindings.
175175
- [hermes-json](https://hackage.haskell.org/package/hermes-json): haskell bindings.
176-
- [simdjzon](https://github.com/travisstaloch/simdjzon): zig port.
176+
- [zimdjson](https://github.com/EzequielRamis/zimdjson): Zig port.
177+
- [simdjzon](https://github.com/travisstaloch/simdjzon): Zig port.
177178
- [JSON-Simd](https://github.com/rawleyfowler/JSON-simd): Raku bindings.
178179
- [JSON::SIMD](https://metacpan.org/pod/JSON::SIMD): Perl bindings; fully-featured JSON module that uses simdjson for decoding.
179180
- [gemmaJSON](https://github.com/sainttttt/gemmaJSON): Nim JSON parser based on simdjson bindings.

contrib/libs/simdjson/include/simdjson/concepts.h

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,30 @@ SIMDJSON_IMPL_CONCEPT(op_append, operator+=)
3232
#undef SIMDJSON_IMPL_CONCEPT
3333
} // namespace details
3434

35+
36+
template <typename T>
37+
concept string_view_like = std::is_convertible_v<T, std::string_view> &&
38+
!std::is_convertible_v<T, const char*>;
39+
40+
template<typename T>
41+
concept constructible_from_string_view = std::is_constructible_v<T, std::string_view>
42+
&& !std::is_same_v<T, std::string_view>
43+
&& std::is_default_constructible_v<T>;
44+
45+
template<typename M>
46+
concept string_view_keyed_map = string_view_like<typename M::key_type>
47+
&& requires(std::remove_cvref_t<M>& m, typename M::key_type sv, typename M::mapped_type v) {
48+
{ m.emplace(sv, v) } -> std::same_as<std::pair<typename M::iterator, bool>>;
49+
};
50+
3551
/// Check if T is a container that we can append to, including:
3652
/// std::vector, std::deque, std::list, std::string, ...
3753
template <typename T>
3854
concept appendable_containers =
39-
details::supports_emplace_back<T> || details::supports_emplace<T> ||
55+
(details::supports_emplace_back<T> || details::supports_emplace<T> ||
4056
details::supports_push_back<T> || details::supports_push<T> ||
4157
details::supports_add<T> || details::supports_append<T> ||
42-
details::supports_insert<T>;
58+
details::supports_insert<T>) && !string_view_keyed_map<T>;
4359

4460
/// Insert into the container however possible
4561
template <appendable_containers T, typename... Args>
@@ -107,6 +123,8 @@ concept optional_type = requires(std::remove_cvref_t<T> obj) {
107123
{ static_cast<bool>(obj) } -> std::same_as<bool>; // convertible to bool
108124
};
109125

126+
127+
110128
} // namespace concepts
111129
} // namespace simdjson
112130
#endif // SIMDJSON_SUPPORTS_DESERIALIZATION

contrib/libs/simdjson/include/simdjson/dom/document.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ class document {
7070
* The memory allocation is strict: you
7171
* can you use this function to increase
7272
* or lower the amount of allocated memory.
73-
* Passsing zero clears the memory.
73+
* Passing zero clears the memory.
7474
*/
7575
error_code allocate(size_t len) noexcept;
7676
/** @private Capacity in bytes, in terms

contrib/libs/simdjson/include/simdjson/dom/parser.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,7 @@ class parser {
340340
* arrays or objects) MUST be separated with whitespace.
341341
*
342342
* The documents must not exceed batch_size bytes (by default 1MB) or they will fail to parse.
343-
* Setting batch_size to excessively large or excesively small values may impact negatively the
343+
* Setting batch_size to excessively large or excessively small values may impact negatively the
344344
* performance.
345345
*
346346
* ### Error Handling
@@ -434,7 +434,7 @@ class parser {
434434
* arrays or objects) MUST be separated with whitespace.
435435
*
436436
* The documents must not exceed batch_size bytes (by default 1MB) or they will fail to parse.
437-
* Setting batch_size to excessively large or excesively small values may impact negatively the
437+
* Setting batch_size to excessively large or excessively small values may impact negatively the
438438
* performance.
439439
*
440440
* ### Error Handling

contrib/libs/simdjson/include/simdjson/error-inl.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,11 @@
66
#include <iostream>
77

88
namespace simdjson {
9+
10+
inline bool is_fatal(error_code error) noexcept {
11+
return error == TAPE_ERROR || error == INCOMPLETE_ARRAY_OR_OBJECT;
12+
}
13+
914
namespace internal {
1015
// We store the error code so we can validate the error message is associated with the right code
1116
struct error_code_info {

contrib/libs/simdjson/include/simdjson/error.h

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ enum error_code {
2020
SUCCESS = 0, ///< No error
2121
CAPACITY, ///< This parser can't support a document that big
2222
MEMALLOC, ///< Error allocating memory, most likely out of memory
23-
TAPE_ERROR, ///< Something went wrong, this is a generic error
23+
TAPE_ERROR, ///< Something went wrong, this is a generic error. Fatal/unrecoverable error.
2424
DEPTH_ERROR, ///< Your document exceeds the user-specified depth limitation
2525
STRING_ERROR, ///< Problem while parsing a string
2626
T_ATOM_ERROR, ///< Problem while parsing an atom starting with the letter 't'
@@ -45,13 +45,21 @@ enum error_code {
4545
PARSER_IN_USE, ///< parser is already in use.
4646
OUT_OF_ORDER_ITERATION, ///< tried to iterate an array or object out of order (checked when SIMDJSON_DEVELOPMENT_CHECKS=1)
4747
INSUFFICIENT_PADDING, ///< The JSON doesn't have enough padding for simdjson to safely parse it.
48-
INCOMPLETE_ARRAY_OR_OBJECT, ///< The document ends early.
48+
INCOMPLETE_ARRAY_OR_OBJECT, ///< The document ends early. Fatal/unrecoverable error.
4949
SCALAR_DOCUMENT_AS_VALUE, ///< A scalar document is treated as a value.
5050
OUT_OF_BOUNDS, ///< Attempted to access location outside of document.
5151
TRAILING_CONTENT, ///< Unexpected trailing content in the JSON input
5252
NUM_ERROR_CODES
5353
};
5454

55+
/**
56+
* Some errors are fatal and invalidate the document. This function returns true if the
57+
* error is fatal. It returns true for TAPE_ERROR and INCOMPLETE_ARRAY_OR_OBJECT.
58+
* Once a fatal error is encountered, the on-demand document is no longer valid and
59+
* processing should stop.
60+
*/
61+
inline bool is_fatal(error_code error) noexcept;
62+
5563
/**
5664
* It is the convention throughout the code that the macro SIMDJSON_DEVELOPMENT_CHECKS determines whether
5765
* we check for OUT_OF_ORDER_ITERATION. The logic behind it is that these errors only occurs when the code

contrib/libs/simdjson/include/simdjson/generic/numberparsing.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -137,7 +137,7 @@ simdjson_inline bool compute_float_64(int64_t power, uint64_t i, bool negative,
137137
// floor(log(5**power)/log(2))
138138
//
139139
// Note that this is not magic: 152170/(1<<16) is
140-
// approximatively equal to log(5)/log(2).
140+
// approximately equal to log(5)/log(2).
141141
// The 1<<16 value is a power of two; we could use a
142142
// larger power of 2 if we wanted to.
143143
//

contrib/libs/simdjson/include/simdjson/generic/ondemand/document.h

Lines changed: 34 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -239,20 +239,27 @@ class document {
239239
if constexpr (custom_deserializable<T, document>) {
240240
return deserialize(*this, out);
241241
} else {
242-
#endif // SIMDJSON_SUPPORTS_DESERIALIZATION
243-
// Unless the simdjson library or the user provides an inline implementation, calling this method should
244-
// immediately fail.
245-
static_assert(!sizeof(T), "The get method with given type is not implemented by the simdjson library. "
246-
"The supported types are ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
247-
"int64_t, double, and bool. We recommend you use get_double(), get_bool(), get_uint64(), get_int64(), "
248-
" get_object(), get_array(), get_raw_json_string(), or get_string() instead of the get template."
249-
" You may also add support for custom types, see our documentation.");
242+
static_assert(!sizeof(T), "The get<T> method with type T is not implemented by the simdjson library. "
243+
"And you do not seem to have added support for it. Indeed, we have that "
244+
"simdjson::custom_deserializable<T> is false and the type T is not a default type "
245+
"such as ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
246+
"int64_t, double, or bool.");
250247
static_cast<void>(out); // to get rid of unused errors
251248
return UNINITIALIZED;
252-
#if SIMDJSON_SUPPORTS_DESERIALIZATION
253249
}
254-
#endif
250+
#else // SIMDJSON_SUPPORTS_DESERIALIZATION
251+
// Unless the simdjson library or the user provides an inline implementation, calling this method should
252+
// immediately fail.
253+
static_assert(!sizeof(T), "The get method with given type is not implemented by the simdjson library. "
254+
"The supported types are ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
255+
"int64_t, double, and bool. We recommend you use get_double(), get_bool(), get_uint64(), get_int64(), "
256+
" get_object(), get_array(), get_raw_json_string(), or get_string() instead of the get template."
257+
" You may also add support for custom types, see our documentation.");
258+
static_cast<void>(out); // to get rid of unused errors
259+
return UNINITIALIZED;
260+
#endif // SIMDJSON_SUPPORTS_DESERIALIZATION
255261
}
262+
256263
/** @overload template<typename T> error_code get(T &out) & noexcept */
257264
template<typename T> simdjson_deprecated simdjson_inline error_code get(T &out) && noexcept;
258265

@@ -814,20 +821,27 @@ class document_reference {
814821
if constexpr (custom_deserializable<T, document_reference>) {
815822
return deserialize(*this, out);
816823
} else {
817-
#endif // SIMDJSON_SUPPORTS_DESERIALIZATION
818-
// Unless the simdjson library or the user provides an inline implementation, calling this method should
819-
// immediately fail.
820-
static_assert(!sizeof(T), "The get method with given type is not implemented by the simdjson library. "
821-
"The supported types are ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
822-
"int64_t, double, and bool. We recommend you use get_double(), get_bool(), get_uint64(), get_int64(), "
823-
" get_object(), get_array(), get_raw_json_string(), or get_string() instead of the get template."
824-
" You may also add support for custom types, see our documentation.");
824+
static_assert(!sizeof(T), "The get<T> method with type T is not implemented by the simdjson library. "
825+
"And you do not seem to have added support for it. Indeed, we have that "
826+
"simdjson::custom_deserializable<T> is false and the type T is not a default type "
827+
"such as ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
828+
"int64_t, double, or bool.");
825829
static_cast<void>(out); // to get rid of unused errors
826830
return UNINITIALIZED;
827-
#if SIMDJSON_SUPPORTS_DESERIALIZATION
828831
}
829-
#endif
832+
#else // SIMDJSON_SUPPORTS_DESERIALIZATION
833+
// Unless the simdjson library or the user provides an inline implementation, calling this method should
834+
// immediately fail.
835+
static_assert(!sizeof(T), "The get method with given type is not implemented by the simdjson library. "
836+
"The supported types are ondemand::object, ondemand::array, raw_json_string, std::string_view, uint64_t, "
837+
"int64_t, double, and bool. We recommend you use get_double(), get_bool(), get_uint64(), get_int64(), "
838+
" get_object(), get_array(), get_raw_json_string(), or get_string() instead of the get template."
839+
" You may also add support for custom types, see our documentation.");
840+
static_cast<void>(out); // to get rid of unused errors
841+
return UNINITIALIZED;
842+
#endif // SIMDJSON_SUPPORTS_DESERIALIZATION
830843
}
844+
831845
/** @overload template<typename T> error_code get(T &out) & noexcept */
832846
template<typename T> simdjson_inline error_code get(T &out) && noexcept;
833847
simdjson_inline simdjson_result<std::string_view> raw_json() noexcept;

0 commit comments

Comments
 (0)