pybcsv 1.5.2__tar.gz → 1.5.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (116) hide show
  1. {pybcsv-1.5.2 → pybcsv-1.5.4}/PKG-INFO +1 -1
  2. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/bitset.hpp +9 -0
  3. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/definitions.h +12 -8
  4. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/packet_header.h +8 -6
  5. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/writer.h +1 -1
  6. pybcsv-1.5.4/pybcsv/_version.py +24 -0
  7. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/bindings.cpp +2 -2
  8. pybcsv-1.5.2/pybcsv/_version.py +0 -34
  9. {pybcsv-1.5.2 → pybcsv-1.5.4}/BUILD_NOTES.md +0 -0
  10. {pybcsv-1.5.2 → pybcsv-1.5.4}/CMakeLists.txt +0 -0
  11. {pybcsv-1.5.2 → pybcsv-1.5.4}/LICENSE +0 -0
  12. {pybcsv-1.5.2 → pybcsv-1.5.4}/MANIFEST.in +0 -0
  13. {pybcsv-1.5.2 → pybcsv-1.5.4}/README.md +0 -0
  14. {pybcsv-1.5.2 → pybcsv-1.5.4}/benchmarks/README.md +0 -0
  15. {pybcsv-1.5.2 → pybcsv-1.5.4}/benchmarks/run_pybcsv_benchmarks.py +0 -0
  16. {pybcsv-1.5.2 → pybcsv-1.5.4}/examples/README.md +0 -0
  17. {pybcsv-1.5.2 → pybcsv-1.5.4}/examples/advanced_usage.py +0 -0
  18. {pybcsv-1.5.2 → pybcsv-1.5.4}/examples/basic_usage.py +0 -0
  19. {pybcsv-1.5.2 → pybcsv-1.5.4}/examples/pandas_integration.py +0 -0
  20. {pybcsv-1.5.2 → pybcsv-1.5.4}/examples/performance_benchmark.py +0 -0
  21. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/bcsv.h +0 -0
  22. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/bcsv.hpp +0 -0
  23. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/bcsv_c_api.h +0 -0
  24. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/bitset.h +0 -0
  25. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/byte_buffer.h +0 -0
  26. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/checksum.hpp +0 -0
  27. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_concept.h +0 -0
  28. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_dispatch.h +0 -0
  29. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_packet001.h +0 -0
  30. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_packet_lz4_001.h +0 -0
  31. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_packet_lz4_batch001.h +0 -0
  32. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_stream001.h +0 -0
  33. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_file/file_codec_stream_lz4_001.h +0 -0
  34. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_delta002.h +0 -0
  35. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_delta002.hpp +0 -0
  36. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_dispatch.h +0 -0
  37. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_flat001.h +0 -0
  38. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_flat001.hpp +0 -0
  39. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_zoh001.h +0 -0
  40. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/codec_row/row_codec_zoh001.hpp +0 -0
  41. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/column_name_index.h +0 -0
  42. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/column_name_index.hpp +0 -0
  43. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/csv_reader.h +0 -0
  44. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/csv_reader.hpp +0 -0
  45. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/csv_writer.h +0 -0
  46. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/csv_writer.hpp +0 -0
  47. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/file_footer.h +0 -0
  48. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/file_header.h +0 -0
  49. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/file_header.hpp +0 -0
  50. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/layout.h +0 -0
  51. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/layout.hpp +0 -0
  52. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/layout_guard.h +0 -0
  53. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/lz4_block.hpp +0 -0
  54. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/lz4_stream.hpp +0 -0
  55. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/reader.h +0 -0
  56. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/reader.hpp +0 -0
  57. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/reader_concept.h +0 -0
  58. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/row.h +0 -0
  59. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/row.hpp +0 -0
  60. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/row_visitors.h +0 -0
  61. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler.h +0 -0
  62. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler.hpp +0 -0
  63. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_ast.h +0 -0
  64. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_compiler.h +0 -0
  65. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_parser.h +0 -0
  66. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_tokenizer.h +0 -0
  67. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_types.h +0 -0
  68. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_vm.h +0 -0
  69. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_vm.hpp +0 -0
  70. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/sampler/sampler_window.h +0 -0
  71. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/std_charconv_compat.h +0 -0
  72. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/vle.hpp +0 -0
  73. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/writer.hpp +0 -0
  74. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/bcsv/writer_concept.h +0 -0
  75. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4.c +0 -0
  76. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4.h +0 -0
  77. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4file.c +0 -0
  78. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4file.h +0 -0
  79. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4frame.c +0 -0
  80. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4frame.h +0 -0
  81. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4frame_static.h +0 -0
  82. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4hc.c +0 -0
  83. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/lz4hc.h +0 -0
  84. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/xxhash.c +0 -0
  85. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/lz4-1.10.0/xxhash.h +0 -0
  86. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/xxHash-0.8.3/xxhash.c +0 -0
  87. {pybcsv-1.5.2 → pybcsv-1.5.4}/include/xxHash-0.8.3/xxhash.h +0 -0
  88. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/__init__.py +0 -0
  89. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/__init__.pyi +0 -0
  90. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/__version__.py +0 -0
  91. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/_bcsv.pyi +0 -0
  92. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/pandas_utils.py +0 -0
  93. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/polars_utils.py +0 -0
  94. {pybcsv-1.5.2 → pybcsv-1.5.4}/pybcsv/py.typed +0 -0
  95. {pybcsv-1.5.2 → pybcsv-1.5.4}/pyproject.toml +0 -0
  96. {pybcsv-1.5.2 → pybcsv-1.5.4}/sync_headers.py +0 -0
  97. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/README.md +0 -0
  98. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/conftest.py +0 -0
  99. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_basic_functionality.py +0 -0
  100. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_count_rows.py +0 -0
  101. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_csv_writer_reader.py +0 -0
  102. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_cycle4_python_hardening.py +0 -0
  103. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_data_types.py +0 -0
  104. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_interoperability.py +0 -0
  105. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_minimal_string.py +0 -0
  106. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_performance_edge_cases.py +0 -0
  107. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_arrow.py +0 -0
  108. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_codecs.py +0 -0
  109. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_columnar.py +0 -0
  110. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_core.py +0 -0
  111. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_direct_access.py +0 -0
  112. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_errors.py +0 -0
  113. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_pandas.py +0 -0
  114. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_performance.py +0 -0
  115. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_polars.py +0 -0
  116. {pybcsv-1.5.2 → pybcsv-1.5.4}/tests/test_pybcsv_sampler.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pybcsv
3
- Version: 1.5.2
3
+ Version: 1.5.4
4
4
  Summary: High-performance Python bindings for the BCSV (Binary CSV) library with pandas integration
5
5
  Keywords: csv,binary,data-science,compression,performance,pandas,numpy,big-data,data-processing
6
6
  Author-Email: Tobias Weber <weber.tobias.md@gmail.com>
@@ -1928,6 +1928,12 @@ constexpr Bitset<N>& Bitset<N>::assignRange(const Bitset<M>& src,
1928
1928
  // Fast path: destination is word-aligned
1929
1929
  if (dst_shift == 0) {
1930
1930
  const size_t base = offset / WORD_BITS;
1931
+ // GCC false-positive: bounds are verified by the asserts above, but
1932
+ // the compiler cannot prove it for dynamic (N=npos) specialisations.
1933
+ #if defined(__GNUC__) && !defined(__clang__)
1934
+ #pragma GCC diagnostic push
1935
+ #pragma GCC diagnostic ignored "-Warray-bounds"
1936
+ #endif
1931
1937
  for (size_t i = 0; i < full_words; ++i) {
1932
1938
  word_t s = (i < src_wc) ? src_data[i] : word_t{0};
1933
1939
  dst_data[base + i] = s;
@@ -1937,6 +1943,9 @@ constexpr Bitset<N>& Bitset<N>::assignRange(const Bitset<M>& src,
1937
1943
  word_t& d = dst_data[base + full_words];
1938
1944
  d = (d & ~tail_mask) | (s & tail_mask);
1939
1945
  }
1946
+ #if defined(__GNUC__) && !defined(__clang__)
1947
+ #pragma GCC diagnostic pop
1948
+ #endif
1940
1949
  clearUnusedBits();
1941
1950
  return *this;
1942
1951
  }
@@ -65,21 +65,25 @@ namespace bcsv {
65
65
  // See VERSIONING.md for compatibility rules (A/B/C).
66
66
 
67
67
  // Constants for the binary file format
68
+ // uint32 constants store magic as little-endian integers; char arrays hold the on-disk byte order.
69
+ constexpr uint32_t BCSV_MAGIC = 0x56534342; // LE bytes: "BCSV"
70
+ // NOTE: PCKT_MAGIC on-disk bytes read "PKCT" (K/C transposed vs the intended "PCKT").
71
+ // Kept as-is to avoid invalidating all existing files; correct in the next breaking change.
72
+ constexpr uint32_t PCKT_MAGIC = 0x54434B50; // LE bytes: "PKCT"
73
+ constexpr uint32_t FOOTER_BIDX_MAGIC = 0x58444942; // LE bytes: "BIDX"
74
+ constexpr uint32_t FOOTER_EIDX_MAGIC = 0x58444945; // LE bytes: "EIDX"
68
75
  constexpr char MAGIC_BYTES_BCSV[4] = { 'B', 'C', 'S', 'V' };
69
- constexpr char MAGIC_BYTES_PCKT[4] = { 'P', 'C', 'K', 'T' };
76
+ constexpr char MAGIC_BYTES_PCKT[4] = { 'P', 'K', 'C', 'T' }; // matches LE of PCKT_MAGIC
70
77
  constexpr char MAGIC_BYTES_FOOTER_BIDX[4] = { 'B', 'I', 'D', 'X' };
71
- constexpr char MAGIC_BYTES_FOOTER_EIDX[4] = { 'E', 'I', 'D', 'X' };
72
- constexpr uint32_t BCSV_MAGIC = 0x56534342; // "BCSV" in little-endian
73
- constexpr uint32_t PCKT_MAGIC = 0x54434B50; // "PCKT" in little-endian
74
- constexpr uint32_t FOOTER_BIDX_MAGIC = 0x58444942; // "BIDX" in little-endian
75
- constexpr uint32_t FOOTER_EIDX_MAGIC = 0x58444945; // "EIDX" in little-endian
78
+ constexpr char MAGIC_BYTES_FOOTER_EIDX[4] = { 'E', 'I', 'D', 'X' };
76
79
  constexpr uint32_t PCKT_TERMINATOR = 0x3FFFFFFF ; // Marker value to indicate end of packet data (no more rows to come)
77
80
  constexpr size_t MAX_COLUMN_COUNT = std::numeric_limits<uint16_t>::max(); // Maximum number of columns
78
81
  constexpr size_t MAX_COLUMN_LENGTH = std::numeric_limits<uint16_t>::max(); // Maximum width of column content
79
82
  constexpr size_t MAX_STRING_LENGTH = std::numeric_limits<uint16_t>::max(); // Maximum length of string data (wire format uses uint16_t lengths)
80
83
  constexpr size_t MAX_ROW_LENGTH = (1ULL << 24) - 2 ; // ~16 MB maximum row size, 4b BLE encoding (2 bits for length), reserve 0xFFFF for terminator.
81
- constexpr size_t MIN_PACKET_SIZE = 64 * 1024; // 64KB minimum packet size
82
- constexpr size_t MAX_PACKET_SIZE = 1024 * 1024 * 1024; // 1GB maximum packet size
84
+ constexpr size_t MIN_PACKET_SIZE = 64 * 1024; // 64KB minimum packet size
85
+ constexpr size_t DEFAULT_PACKET_SIZE_KB = 8192; // 8MB default packet size (in KB, for Writer::open blockSizeKB param)
86
+ constexpr size_t MAX_PACKET_SIZE = 1024 * 1024 * 1024; // 1GB maximum packet size
83
87
  /**
84
88
  * @brief Feature flag bit positions (Reserved for future optional features)
85
89
  *
@@ -35,7 +35,7 @@ namespace bcsv {
35
35
  * ```
36
36
  * Offset | Size | Field | Description
37
37
  * -------|------|------------------------|----------------------------------------
38
- * 0 | 4 | magic[4] | "PCKT" (0x50 0x43 0x4B 0x54)
38
+ * 0 | 4 | magic[4] | PCKT_MAGIC (0x50 0x4B 0x43 0x54 on disk)
39
39
  * 4 | 8 | firstRowIndex | Absolute row index (0-based, file-wide)
40
40
  * 12 | 4 | headerChecksum | xxHash32 of bytes 0-12 (magic + firstRowIndex)
41
41
  *
@@ -46,7 +46,7 @@ namespace bcsv {
46
46
  #pragma pack(push, 1)
47
47
  struct PacketHeader {
48
48
 
49
- uint32_t magic; ///< Magic number: "PCKT" (0x50 0x43 0x4B 0x54)
49
+ uint32_t magic; ///< Magic number: PCKT_MAGIC (0x50 0x4B 0x43 0x54 on disk)
50
50
  uint64_t first_row_index; ///< Absolute row index (0-based, file-wide)
51
51
  uint32_t checksum; ///< xxHash32 of bytes 0-19 (magic + firstRowIndex + prevPayloadChecksum)
52
52
 
@@ -73,7 +73,7 @@ namespace bcsv {
73
73
 
74
74
  /**
75
75
  * @brief Validate magic number
76
- * @return true if magic number is "PCKT"
76
+ * @return true if magic number matches PCKT_MAGIC
77
77
  */
78
78
  bool isValidMagic() const {
79
79
  return magic == PCKT_MAGIC;
@@ -168,9 +168,11 @@ namespace bcsv {
168
168
  break; // Not enough data for a complete header
169
169
  }
170
170
 
171
- // Search for "PCKT" in the buffer using string_view
171
+ // Search for PCKT_MAGIC bytes in the buffer
172
+ static constexpr auto pckt_le = std::bit_cast<std::array<char, 4>>(PCKT_MAGIC);
173
+ const std::string_view magic_sv(pckt_le.data(), 4);
172
174
  std::string_view view(buffer.data(), static_cast<size_t>(validBytes));
173
- size_t pos = view.find("PCKT");
175
+ size_t pos = view.find(magic_sv);
174
176
 
175
177
  while (pos != std::string_view::npos) {
176
178
  // Check if we have enough bytes for complete header
@@ -204,7 +206,7 @@ namespace bcsv {
204
206
  }
205
207
 
206
208
  // Invalid header, search for next occurrence after this position
207
- pos = view.find("PCKT", pos + 1);
209
+ pos = view.find(magic_sv, pos + 1);
208
210
  }
209
211
 
210
212
  // If no match found and we read a full chunk, prepare for next iteration
@@ -89,7 +89,7 @@ namespace bcsv {
89
89
  const FilePath& filePath() const { return file_path_; }
90
90
  const LayoutType& layout() const { return row_.layout(); }
91
91
  bool isOpen() const { return stream_.is_open(); }
92
- bool open(const FilePath& filepath, bool overwrite = false, size_t compressionLevel = 1, size_t blockSizeKB = 64, FileFlags flags = FileFlags::NONE);
92
+ bool open(const FilePath& filepath, bool overwrite = false, size_t compressionLevel = 1, size_t blockSizeKB = DEFAULT_PACKET_SIZE_KB, FileFlags flags = FileFlags::NONE);
93
93
  RowType& row() { return row_; }
94
94
  const RowType& row() const { return row_; }
95
95
  size_t rowCount() const { return row_cnt_; }
@@ -0,0 +1,24 @@
1
+ # file generated by vcs-versioning
2
+ # don't change, don't track in version control
3
+ from __future__ import annotations
4
+
5
+ __all__ = [
6
+ "__version__",
7
+ "__version_tuple__",
8
+ "version",
9
+ "version_tuple",
10
+ "__commit_id__",
11
+ "commit_id",
12
+ ]
13
+
14
+ version: str
15
+ __version__: str
16
+ __version_tuple__: tuple[int | str, ...]
17
+ version_tuple: tuple[int | str, ...]
18
+ commit_id: str | None
19
+ __commit_id__: str | None
20
+
21
+ __version__ = version = '1.5.4'
22
+ __version_tuple__ = version_tuple = (1, 5, 4)
23
+
24
+ __commit_id__ = commit_id = 'gc04e73b58'
@@ -278,7 +278,7 @@ namespace {
278
278
  PyWriter pw(layout, row_codec);
279
279
  pw.visit([&](auto& w) {
280
280
  nb::gil_scoped_release release;
281
- if (!w.open(filename, true, compression_level, 64, flags))
281
+ if (!w.open(filename, true, compression_level, bcsv::DEFAULT_PACKET_SIZE_KB, flags))
282
282
  throw std::runtime_error("Failed to open file for writing: " + filename);
283
283
  for (size_t r = 0; r < num_rows; ++r) {
284
284
  auto& row = w.row();
@@ -580,7 +580,7 @@ NB_MODULE(_bcsv, m) {
580
580
  }
581
581
  return success;
582
582
  }, nb::arg("filename"), nb::arg("overwrite") = false, nb::arg("compression_level") = 1,
583
- nb::arg("block_size_kb") = 64, nb::arg("flags") = DEFAULT_FILE_FLAGS)
583
+ nb::arg("block_size_kb") = bcsv::DEFAULT_PACKET_SIZE_KB, nb::arg("flags") = DEFAULT_FILE_FLAGS)
584
584
  .def("write_row", [](PyWriter& pw, const nb::list& values) {
585
585
  const auto& layout = pw.visit([](auto& w) -> const bcsv::Layout& { return w.layout(); });
586
586
  if (values.size() != layout.columnCount())
@@ -1,34 +0,0 @@
1
- # file generated by setuptools-scm
2
- # don't change, don't track in version control
3
-
4
- __all__ = [
5
- "__version__",
6
- "__version_tuple__",
7
- "version",
8
- "version_tuple",
9
- "__commit_id__",
10
- "commit_id",
11
- ]
12
-
13
- TYPE_CHECKING = False
14
- if TYPE_CHECKING:
15
- from typing import Tuple
16
- from typing import Union
17
-
18
- VERSION_TUPLE = Tuple[Union[int, str], ...]
19
- COMMIT_ID = Union[str, None]
20
- else:
21
- VERSION_TUPLE = object
22
- COMMIT_ID = object
23
-
24
- version: str
25
- __version__: str
26
- __version_tuple__: VERSION_TUPLE
27
- version_tuple: VERSION_TUPLE
28
- commit_id: COMMIT_ID
29
- __commit_id__: COMMIT_ID
30
-
31
- __version__ = version = '1.5.2'
32
- __version_tuple__ = version_tuple = (1, 5, 2)
33
-
34
- __commit_id__ = commit_id = 'ga084b947a'
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes