Skip to content
Snippets Groups Projects
  1. Sep 22, 2023
  2. Sep 21, 2023
    • Vladimir Davydov's avatar
      test: fix flaky replication/gh_9049_schema_downgrade test · d72a50bc
      Vladimir Davydov authored
      When a replica is restarted, it doesn't immediately switch to the
      'follow' state. First it needs to sync. Let's wait for the 'follow'
      state a bit to fix the following failure:
      
      NO_WRAP
      [039] replication-luatest/gh_9049_schema_downgrade_t>                 [ fail ]
      [039] Test failed! Output from reject file /tmp/t/rejects/replication-luatest/gh_9049_schema_downgrade.reject:
      [039] Tarantool version is 3.0.0-alpha3-18-g6892907bad9d
      [039] TAP version 13
      [039] 1..1
      [039] # Started on Thu Sep 21 13:55:09 2023
      [039] # Starting group: replication-luatest.gh_9049_schema_downgrade
      [039] not ok 1  replication-luatest.gh_9049_schema_downgrade.test_schema_downgrade
      [039] #   ...st/replication-luatest/gh_9049_schema_downgrade_test.lua:33: expected: "follow"
      [039] #   actual: "sync"
      [039] #   stack traceback:
      [039] #         ...st/replication-luatest/gh_9049_schema_downgrade_test.lua:31: in function 'replication-luatest.gh_9049_schema_downgrade.test_schema_downgrade'
      [039] #         ...
      [039] #         [C]: in function 'xpcall'
      [039] #   artifacts:
      [039] #   replica -> /tmp/t/039_replication-luatest/artifacts/replica-AgoXGWUXxvnc
      [039] #   master -> /tmp/t/039_replication-luatest/artifacts/master-ZUTtyXyAX9YF
      [039] # Ran 1 tests in 1.768 seconds, 0 succeeded, 1 failed
      NO_WRAP
      
      Fixes commit 71de4b2c ("box: fix schema downgrade replication").
      
      NO_DOC=test fix
      NO_CHANGELOG=test fix
      
      (cherry picked from commit c903b61b)
      d72a50bc
  3. Sep 18, 2023
    • Vladimir Davydov's avatar
      tools/gen-release-notes: update for enterprise edition · 4c3c3ffb
      Vladimir Davydov authored
      We decided not to merge entries from Tarantool CE changelog to
      Tarantool EE changelog. Instead we now add a link to CE release notes
      to EE release notes. Update the script accordingly.
      
      NO_DOC=tools
      NO_TEST=tools
      NO_CHANGELOG=tools
      
      (cherry picked from commit 3dd1cffe)
      4c3c3ffb
    • Ilya Verbin's avatar
      box: fix NULL pointer dereference in error_unpack_unsafe · bd759c2d
      Ilya Verbin authored
      If MP_ERROR map contains two MP_ERROR_STACK keys, then the second call to
      `error_set_prev(effect, cur)' will crash, because `effect' is NULL, but
      `err == NULL' is false, because it is assigned on the first iteration.
      This patch raises an error if more than one MP_ERROR_STACK key is present.
      
      NO_DOC=bugfix
      
      Closes #9136
      
      (cherry picked from commit 990aeee9)
      bd759c2d
  4. Sep 15, 2023
    • Yaroslav Lobankov's avatar
      ci: convert shallow submodules to complete ones · 5f34d2a1
      Yaroslav Lobankov authored
      This patch is intended to resolve the following issue that appears while
      calling `cmake` for submodules from time to time:
      
          fatal: No tags can describe '<sha>'.
          Try --always, or create some tags.
      
      This happens because the `actions/checkout` GitHub action fetches the
      repository with the `--unshallow` option, but it doesn't do the same for
      submodules. So this leads to the error above while using `git describe`
      for submodules.
      
      This is fixed by converting a shallow submodule to a complete one.
      
      NO_DOC=ci
      NO_TEST=circuit
      NO_CHANGELOG=ci
      
      (cherry picked from commit 5be8268a)
      Unverified
      5f34d2a1
  5. Sep 14, 2023
    • Sergey Bronnikov's avatar
      third_party: update libcurl from 7.87.0 to 8.3.0 · 83ddadb4
      Sergey Bronnikov authored
      The patch updates curl module to the version 8.3.0 [1] and updates a
      CMake module for building curl library.
      
      Changes in CMake module:
      
      - Option `CURL_STATICLIB` is gone and replaced with `BUILD_STATIC_LIBS`.
      - Option `CURL_USE_GNUTLS` was added and disabled by default.
      - NSS library support was removed and option `CURL_USE_NSS` has been
        removed as well.
      - Option `CMAKE_UNITY_BUILD` was added and disabled by default.
      - Option `CURL_DISABLE_FORM_API` was added and disabled by default. It is
        in fact depends on `CURL_DISABLE_MIME`, but anyway disabled explicitly.
      
      Changelog: https://curl.se/changes.html#8_3_0
      
      1. https://github.com/curl/curl/releases/tag/curl-8_3_0
      
      NO_DOC=libcurl submodule bump
      NO_TEST=libcurl submodule bump
      
      Fixes #9086
      
      (cherry picked from commit 979b4adb)
      83ddadb4
  6. Sep 12, 2023
    • Sergey Bronnikov's avatar
      test/fuzz: add fuzzing test for xrow_decode_error · 36026980
      Sergey Bronnikov authored
      The patch adds a fuzzing test for IPROTO decoding function
      xrow_decode_error().
      
      Follows up #8921
      Follows up #9098
      
      NO_DOC=testing
      NO_CHANGELOG=testing
      
      (cherry picked from commit 2c700aab)
      36026980
    • Vladimir Davydov's avatar
      box: fix schema downgrade replication · b24eade3
      Vladimir Davydov authored
      Some downgrade operations are performed with disabled system space
      triggers because they were prohibited recently (creation of SQL built-in
      functions) or never allowed (dropping a system space). This works fine
      on the instance running downgrade but apparently fails on replicas.
      
      To fix this issue, let's disable the checks the operations that prevent
      downgrade in the following scenarios:
       - in the fiber that is currently running a schema upgrade or downgrade;
       - in the applier fiber so that it can replicate changes done by upgrade
         or downgrade on the master;
       - during recovery so that DDL records written to the WAL can be
         replayed.
      
      We already have all the necessary infrastructure in-place - we use it
      for allowing DDL operations with an old schema for upgrade.
      
      Closes #9049
      
      NO_DOC=bug fix
      
      (cherry picked from commit 71de4b2c)
      
      NOTE: We don't have the commit that disables DDL operations with an old
      schema in 2.11 so we have to backport bits of it from 3.0, see commit
      97c2c9a4 ("box: disable DDL with old schema").
      b24eade3
  7. Sep 11, 2023
    • Ilya Verbin's avatar
      box: fix out of bound write in error_payload_destroy() · fb4e8ddc
      Ilya Verbin authored
      If `strlen(name)` is 1, `value_size` is 1, and `extra` is 0, then 15 bytes
      are allocated for `struct error_field` in error_payload_prepare(). However,
      the size of this structure is 16 because of the padding for the alignment.
      Thus TRASH() in error_payload_destroy() writes 1 byte beyond the structure.
      
      Closes #9098
      
      NO_DOC=bugfix
      
      (cherry picked from commit 454ffd13)
      fb4e8ddc
  8. Sep 08, 2023
  9. Sep 07, 2023
    • Ilya Verbin's avatar
      lua/fiber: do not raise on printing a dead fiber · 114a542a
      Ilya Verbin authored
      An attempt to print a dead fiber raised a fatal error, which is quite
      unexpected. This patch updates __tostring metamethod of fiber_object so
      that it pushes the "fiber: <fid> (dead)" string instead of the error.
      The __serialize metamethod is patched similarly.
      
      Closes #4265
      
      NO_DOC=bugfix
      
      (cherry picked from commit 3421a3bd)
      114a542a
  10. Sep 05, 2023
    • Rimma Tolkacheva's avatar
      test/fuzz: fixed ElseIfBlock serialization · 5c375314
      Rimma Tolkacheva authored
      Changed `else if` to `elseif`. There was a typo in the
      serializer that led to unclosed `if` statements.
      
      On a set of 50000 protobuf struct samples generates 863
      (3% of all errors) fewer errors.
      
      NO_CHANGELOG=internal
      NO_DOC=fuzzer fix
      
      (cherry picked from commit 8c1e75e7)
      Unverified
      5c375314
    • Rimma Tolkacheva's avatar
      test/fuzz: add return and break checks · 02522e96
      Rimma Tolkacheva authored
      Added checks before serializing return and break to program if
      inside returnable or breakable code block.
      
      On a set of 50000 protobuf struct samples generates 11749
      (42% of all errors) fewer errors.
      
      NO_CHANGELOG=internal
      NO_DOC=fuzzer fix
      
      (cherry picked from commit 8df690b8)
      Unverified
      02522e96
    • Rimma Tolkacheva's avatar
      test/fuzz: introduce class Context · b816e7fb
      Rimma Tolkacheva authored
      The context object is created to manage the context of Lua program.
      It will be used in the next commit to check if `break` or `return` is
      inside a breakable or returnable code block.
      
      NO_CHANGELOG=internal
      NO_DOC=fuzzer fix
      
      (cherry picked from commit b7c65039)
      Unverified
      b816e7fb
  11. Sep 04, 2023
  12. Sep 01, 2023
    • Vladimir Davydov's avatar
      yaml: don't encode unprintable strings as binary blobs · 8caf1fff
      Vladimir Davydov authored
      Historically, we encode strings that contain invalid or non-printable
      utf-8 sequences in YAML as binary base64 blobs. We do that because of
      limitations/bugs of the YAML encoder, which refuses to encode invalid
      utf-8 strings. To work around this issue, we introduced the helper
      utf8_check_printable, which is basically a copy of yaml_check_utf8,
      and treat strings for which it fails as binary data (MP_BIN).
      
      This commit updates the YAML submodule to the version where all known
      issues with encoding invalid/unprintable utf-8 strings are fixed and
      removes special treatment of such strings (drops utf8_check_printable).
      Now unprintable or invalid utf-8 sequences are emitted as code points,
      e.g. '\xFF' or '\uFFFF'. This change is a pre-requisite for introducing
      the new varbinary type to Lua. Without it plain strings would be
      implicitly converted to varbinary after decoding/encoding them in YAML,
      which would be confusing.
      
      Closes #8756
      
      NO_DOC=bug fix
      
      (cherry picked from commit 890a821c)
      8caf1fff
    • Vladimir Davydov's avatar
      box: don't use zero-width space in fselect · a0d06970
      Vladimir Davydov authored
      Currently, the zero-width space Unicode character is silently ignored by
      the YAML encoder but with commit https://github.com/tarantool/libyaml/commit/351108e1ffd5c6296349fa9ab87f91ef8a84c4e7
      ("Allow to emit invalid utf-8 scalar strings"), it will print it as
      a unicode code point, as it should. The fselect helper uses this
      character to prevent the YAML encoder from quoting the output string.
      Actually, quoting is triggered by usage of spaces and vertical bars.
      We already replace spaces with NBSP (U+00A0). Let's also replace
      vertical bars with Latin Letter Dental Click (U+01C0). It looks the
      same but has no special meaning to YAML.
      
      In the master branch this issue was fixed by removing the use_nbsp
      option of fselect completely and using multi-line strings instead,
      see commit f76d3c69 ("box: make fselect return a multi-line string
      instead of a table"). We can't do that in 2.11 because there the
      yaml_pretty_multiline compat option is disabled by default and without
      it multi-line strings look ugly in YAML.
      
      Needed for #8756
      
      NO_DOC=no user-visible changes
      NO_CHANGELOG=no user-visible changes
      a0d06970
  13. Aug 30, 2023
    • Yaroslav Lobankov's avatar
      ci: fix artifact names in Clang related workflows · 65835ffe
      Yaroslav Lobankov authored
      NO_DOC=ci
      NO_TEST=ci
      NO_CHANGELOG=ci
      
      (cherry picked from commit 44bc3675)
      65835ffe
    • Yaroslav Lobankov's avatar
      ci: bump Clang version to 16 in release build ASAN testing · b0f83ed2
      Yaroslav Lobankov authored
      Run release build ASAN testing inside a Docker container created from
      the `tarantool/testing:ubuntu-jammy-clang16` Docker image with Clang 16
      installed.
      
      Closes tarantool/tarantool-qa#319
      
      NO_DOC=ci
      NO_TEST=ci
      NO_CHANGELOG=ci
      
      (cherry picked from commit e3ff3d5c)
      b0f83ed2
    • Ilya Verbin's avatar
      test: disable ASAN for box/tx_man.test.lua · fe6a44b0
      Ilya Verbin authored
      For some unknown reason ASAN crashes with SIGSEGV on this test during
      shutdown. See tarantool/tarantool-qa#324 for details.
      
      NO_DOC=test
      NO_CHANGELOG=test
      
      (cherry picked from commit 8c7da931)
      fe6a44b0
    • Igor Munkin's avatar
      luajit: bump new version · 2c171e43
      Igor Munkin authored
      * Fix maxslots when recording BC_TSETM.
      * Fix TDUP load forwarding after table rehash.
      * Fix binary number literal parsing.
      * Fix maxslots when recording BC_VARG, part 3.
      * test: fix flaky <unit-jit-parse.test.lua> again
      * Fix predict_next() in parser.
      * Revert to trivial pow() optimizations to prevent inaccuracies.
      * Fix pow() optimization inconsistencies.
      * Improve assertions.
      * Remove pow() splitting and cleanup backends.
      * test: introduce `samevalues()` TAP checker
      * MIPS: Add MIPS64 R6 port.
      * DynASM/MIPS: Fix shadowed variable.
      * MIPS64: Fix register allocation in assembly of HREF.
      * Prevent integer overflow while parsing long strings.
      * Fix LJ_MAX_JSLOTS assertion in rec_check_slots().
      * Fix debug.getinfo() argument check.
      * ARM: Fix GCC 7 -Wimplicit-fallthrough warnings.
      * DynASM: Fix warning.
      * Fix GCC 7 -Wimplicit-fallthrough warnings.
      * Cleanup math function compilation and fix inconsistencies.
      * FFI: Eliminate hardcoded string hashes.
      * Windows: Add UWP support, part 1.
      * build: fix non-Linux/macOS builds
      * PPC: Add soft-float support to JIT compiler backend.
      * PPC: Add soft-float support to interpreter.
      * MIPS64: Add soft-float support to JIT compiler backend.
      * MIPS: Fix handling of spare long-range jump slots.
      * test: introduce mcode generator for tests
      * MIPS: Use precise search for exit jump patching.
      * sysprof: improve parser's memory footprint
      * tools: add execution permission to sysprof parser
      * sysprof: remove `split by vmstate` option
      
      Part of #8825
      
      NO_DOC=LuaJIT submodule bump
      NO_TEST=LuaJIT submodule bump
      2c171e43
  14. Aug 29, 2023
    • Alexander Turenko's avatar
      test: fix flaky box.cfg() env vars test · 99568619
      Alexander Turenko authored
      The test starts a child tarantool instance in the current working
      directory and run box.cfg(). The current working directory is a source
      directory. test-run.py runs many tests from it in parallel and in some
      circumstances it appears that the directory is locked by some other
      box.cfg() call from some other tarantool instance (maybe another test is
      doing the same).
      
      The test is rewritten to use a temporary directory for such runs.
      
      The test.interactive_tarantool helper is used for convenience instead of
      a popen wrapper that is written specifically for the test.
      
      NO_DOC=It is a fix of a test.
      NO_CHANGELOG=see NO_DOC
      
      (cherry picked from commit dfa67ae6)
      99568619
    • Gleb Kashkin's avatar
      test: add error rethrow to :read_response() in `it` · 40aa4df6
      Gleb Kashkin authored
      Before this patch interactive_tarantool `:read_response()` helper used
      to just deserialise Lua errors as tables like `[{error = 'msg'}]`.
      Now it checks if response is actually an error and rethrows it.
      This provides additional verification for many tests that use
      interactive_tarantool.
      
      This patch is a followup to commit 261a21bd ("test/config: adjust
      initial permissions in a test"). It provides additional output checks
      to prevent similar issues.
      
      Part of #8967
      
      NO_DOC=test helper update
      NO_CHANGELOG=test helper update
      NO_TEST=test helper update
      
      (cherry picked from commit 793713e6)
      40aa4df6
    • Alexander Turenko's avatar
      test: accept env in interactive_tarantool.new() · 2ecabd56
      Alexander Turenko authored
      It is needed to fix a problem in the
      `config-luatest/credentials_applier` test. See the next commit.
      
      NO_DOC=It is a testing helper improvement.
      NO_CHANGELOG=see NO_DOC
      NO_TEST=see NO_DOC
      
      (cherry picked from commit 130335e4)
      2ecabd56
    • Gleb Kashkin's avatar
      test: add roundtrip() to interactive_tarantool · 8f5242b8
      Gleb Kashkin authored
      Sometimes it is useful to have one function to execute command,
      read and compare response.
      This patch introduces such function - `roundtrip()` to
      interactive_tarantool helper.
      
      NO_CHANGELOG=test helper change
      NO_TEST=test helper change
      NO_DOC=test helper change
      
      (cherry picked from commit 5053f286)
      8f5242b8
    • Oleg Chaplashkin's avatar
      test: bump test-run to new version · 9f24332b
      Oleg Chaplashkin authored
      Bump test-run to new version with the following improvements:
      
      - Fix non-supported character in log file name [1]
      - luatest: bump luatest to 0.5.7-43-g251b35f [2]
      - luatest: bump luatest to 0.5.7-44-g2d51155 [3]
      
      [1] tarantool/test-run@c8465a5
      [2] tarantool/test-run@e84fd00
      [3] tarantool/test-run@22951e0
      
      NO_DOC=test
      NO_TEST=test
      NO_CHANGELOG=test
      
      (cherry picked from commit 6c825cb7)
      Unverified
      9f24332b
  15. Aug 28, 2023
  16. Aug 25, 2023
  17. Aug 24, 2023
    • Sergey Bronnikov's avatar
      ci: update paths in a publish module api doc workflow · 1d53fda6
      Sergey Bronnikov authored
      Module API documentation is described in Doxygen comments in C/C++ files
      in src/ directory. No sense to run this job for other changes. The patch
      changes paths in workflow accordingly.
      
      NO_CHANGELOG=ci
      NO_DOC=ci
      NO_TEST=ci
      
      (cherry picked from commit 9af36ae1)
      Unverified
      1d53fda6
    • Sergey Bronnikov's avatar
      ci: update paths in a fuzzing workflow · 7da94b5c
      Sergey Bronnikov authored
      Fuzzing is a heavyweight job, we can reduce a set of paths used for
      triggering this job and therefore reduce an overall time of testing in
      some cases.
      
      The patch replaces `.github/workflows/**` to
      `.github/workflows/fuzzing.yml` because workflows are independent and
      changes in other workflows does not affect fuzzing at all and patch adds
      Lua files (`**.lua`) to ignores because fuzzing focused on C/C++ code.
      
      NO_CHANGELOG=ci
      NO_DOC=ci
      NO_TEST=ci
      
      (cherry picked from commit f14cb97d)
      Unverified
      7da94b5c
    • Ilya Verbin's avatar
      box: fix memory leak on error_unpack_unsafe() failure · c7b6e3b5
      Ilya Verbin authored
      Memory is leaked in the following scenario:
      - MP_ERROR_STACK with 2 errors is passed to error_unpack_unsafe():
        1. A correct MP_MAP with MP_ERROR_* fields;
        2. Something unexpected, e.g. MP_INT;
      - This first call to mp_decode_error_one() allocates memory for the first
        error in error_build_xc() -> `new ClientError()`;
      - The second call to mp_decode_error_one() returns NULL, and
        error_unpack_unsafe() returns NULL too. Memory from the previous step
        is leaked.
      
      Closes #8921
      
      NO_DOC=bugfix
      
      (cherry picked from commit b367fb98)
      c7b6e3b5
Loading