Repository navigation
5.0.0 - #59
Merged
Merged
5.0.0#59
Conversation
The default generated db.conf now sets KEY_SIZE=8 (CRC64), but test_kb
covers the MD5 (16-byte key) mode and relied on that generated default.
Its fixtures use 32-hex-char keys, so every table was created with an
8-byte key and the whole suite failed with E073 (test_6 additionally
segfaulted while collating the mismatched KB).
setup_suite now generates the config explicitly and pins KEY_SIZE=16
before importing: both the setup import and test_6 ("ldb -u") take their
key size from that file. teardown_suite removes it, since both suites
share the "test_kb" database name and a leftover config from one run
leaked into the next.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
E060 was raised for two unrelated conditions: "Table name format should be dbname/tablename" (command parsing, in ldb_string.c) and "Unsupported node_length size" (node serialization, in node.c), the latter also backed by LDB_ERROR_NODE_SIZE_INVALID. A caller could not tell them apart from the code alone. Move the node_length case to E077, which was unused, and change LDB_ERROR_NODE_SIZE_INVALID from -60 to -77. The constant is only consumed inside ldb_node_write(), so nothing downstream depends on its value. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
First official release of the CRC64-compatible line. Both release lines now coexist: the traditional one on "main" (4.x, MD5 only) and this one on "crc64" (5.x, CRC64 and MD5). Compatibility note: - README states that a knowledge base built with LDB 5.x requires SCANOSS engine v6.0.0 or later, which is released from the "crc64" branch of scanoss/engine. The constraint comes from the on-disk table layout and the library API, so it applies in both hash modes. Versioning: - LDB_VERSION and the Doxyfile move to 5.0.0-crc64. Releases of this line carry a mandatory "-crc64" suffix, since both lines are tagged in the same repository and "ldb -v" is what identifies a binary's line. - CONTRIBUTING documents the branch/tag scheme for both lines. - package.sh translates the suffix to '_' for the RPM spec, since RPM rejects '-' in the Version field. Debian keeps the tag spelling. Documentation fixes (README and the shell help text, which had drifted apart from each other and from the code): - SKIP_SORT / SKIP_FIELDS_CHECK do not exist; the real parameters are SORT and VALIDATE_FIELDS, with inverted meaning. - KEY_SIZE and THREADS were undocumented. KEY_SIZE now also states its two defaults: 16 built-in, 8 in the generated db.conf. - "create table" was documented without the mandatory "seckey N" clause, so the documented form returned E066. - Prerequisites named openssl/libssl-dev; the build links libgcrypt. Same error in the deb package Depends (libssl1.1 -> libgcrypt20). - Config path is /usr/local/etc/scanoss/ldb/ and the file is DBNAME.conf. - Restored commands missing from the README: delete ... record, delete ... records from, dump keys from, dump ... sector N, cat KEY from, create config, version, and the -q/-V flags. - "dump keys" outputs hex, one key per line, not binary. - New sections: key size / hash mode (the primitive is derived from the table's stored key_ln) and the import configuration file. - MAX_RECORD documents that it sizes the collate's fixed per-record slot and that exceeding the cap discards records with E078. - doc/errors.txt stopped at E074; added E058, E065, E073, E075, E076, E077 and E078. CI: - build.yml also runs on pull requests targeting crc64. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The build job has been failing on this line since before the 5.0.0 work: GitHub now fails any run using actions/upload-artifact@v3, so the job died in "Set up job" after a few seconds without ever compiling. The same maintenance had already been applied on master and was never ported here. - build.yml: upload-artifact v3 -> v4, which is what actually unblocks the PR checks. - release.yml: ubuntu-20.04 -> ubuntu-22.04. That runner image was retired, so the tagged-release job would have failed the moment v5.0.0-crc64 was pushed. The remaining differences against master are the intentional ones of this line: the crc64 pull_request trigger and shipping LICENSE in the artifacts. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.