rdbpython 0.2.3__tar.gz → 0.2.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 (56) hide show
  1. {rdbpython-0.2.3 → rdbpython-0.2.4}/PKG-INFO +7 -7
  2. {rdbpython-0.2.3 → rdbpython-0.2.4}/README.md +2 -2
  3. {rdbpython-0.2.3 → rdbpython-0.2.4}/pyproject.toml +5 -5
  4. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/lib_rocksdb.pyx +21 -8
  5. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/PKG-INFO +7 -7
  6. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/conftest.py +0 -2
  7. {rdbpython-0.2.3 → rdbpython-0.2.4}/LICENSE.md +0 -0
  8. {rdbpython-0.2.3 → rdbpython-0.2.4}/MANIFEST.in +0 -0
  9. {rdbpython-0.2.3 → rdbpython-0.2.4}/scripts/build-rocksdb-linux.sh +0 -0
  10. {rdbpython-0.2.3 → rdbpython-0.2.4}/scripts/build-rocksdb-macos.sh +0 -0
  11. {rdbpython-0.2.3 → rdbpython-0.2.4}/scripts/rocksdb-cstdint.patch +0 -0
  12. {rdbpython-0.2.3 → rdbpython-0.2.4}/setup.cfg +0 -0
  13. {rdbpython-0.2.3 → rdbpython-0.2.4}/setup.py +0 -0
  14. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/__init__.py +0 -0
  15. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/backup.pxd +0 -0
  16. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/cache.pxd +0 -0
  17. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/comparator.pxd +0 -0
  18. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/db.pxd +0 -0
  19. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/env.pxd +0 -0
  20. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/errors.py +0 -0
  21. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/filter_policy.pxd +0 -0
  22. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/comparator_wrapper.hpp +0 -0
  23. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/filter_policy_wrapper.hpp +0 -0
  24. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/memtable_factories.hpp +0 -0
  25. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/merge_operator_wrapper.hpp +0 -0
  26. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/slice_transform_wrapper.hpp +0 -0
  27. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/utils.hpp +0 -0
  28. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/include/rdb_include/write_batch_iter_helper.hpp +0 -0
  29. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/interfaces.py +0 -0
  30. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/iterator.pxd +0 -0
  31. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/lib_rocksdb.pxd +0 -0
  32. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/lib_rocksdb.pyi +0 -0
  33. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/lib_utils.py +0 -0
  34. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/logger.pxd +0 -0
  35. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/memtablerep.pxd +0 -0
  36. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/merge_operator.pxd +0 -0
  37. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/merge_operators.py +0 -0
  38. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/options.pxd +0 -0
  39. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/slice_.pxd +0 -0
  40. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/slice_transform.pxd +0 -0
  41. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/snapshot.pxd +0 -0
  42. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/status.pxd +0 -0
  43. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/std_memory.pxd +0 -0
  44. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/table_factory.pxd +0 -0
  45. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/transaction.pxd +0 -0
  46. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpy/universal_compaction.pxd +0 -0
  47. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/SOURCES.txt +0 -0
  48. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/dependency_links.txt +0 -0
  49. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/not-zip-safe +0 -0
  50. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/requires.txt +0 -0
  51. {rdbpython-0.2.3 → rdbpython-0.2.4}/src/rdbpython.egg-info/top_level.txt +0 -0
  52. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/functional/__init__.py +0 -0
  53. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/functional/test_db.py +0 -0
  54. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/functional/test_memtable.py +0 -0
  55. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/functional/test_options.py +0 -0
  56. {rdbpython-0.2.3 → rdbpython-0.2.4}/tests/functional/test_transaction.py +0 -0
@@ -1,14 +1,14 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rdbpython
3
- Version: 0.2.3
3
+ Version: 0.2.4
4
4
  Summary: Python bindings for RocksDB with Cython
5
5
  Author-email: Gor Arakelyan <gorarkln@gmail.com>
6
6
  Maintainer-email: Gor Arakelyan <gorarkln@gmail.com>
7
7
  License-Expression: MIT
8
- Project-URL: Homepage, https://github.com/everyabc/rdbpy
9
- Project-URL: Documentation, https://github.com/everyabc/rdbpy#readme
10
- Project-URL: Repository, https://github.com/everyabc/rdbpy
11
- Project-URL: Issues, https://github.com/everyabc/rdbpy/issues
8
+ Project-URL: Homepage, https://github.com/nustackdev/rdbpy
9
+ Project-URL: Documentation, https://github.com/nustackdev/rdbpy#readme
10
+ Project-URL: Repository, https://github.com/nustackdev/rdbpy
11
+ Project-URL: Issues, https://github.com/nustackdev/rdbpy/issues
12
12
  Project-URL: PyPI, https://pypi.org/project/rdbpython/
13
13
  Keywords: rocksdb,database,key-value,storage,embedded,cython
14
14
  Classifier: Development Status :: 3 - Alpha
@@ -46,8 +46,8 @@ Dynamic: license-file
46
46
 
47
47
  # rdbpy
48
48
 
49
- [![Build Wheels](https://github.com/everyabc/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/build.yml)
50
- [![Tests](https://github.com/everyabc/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/test.yml)
49
+ [![Build Wheels](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml)
50
+ [![Tests](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml)
51
51
  [![PyPI version](https://badge.fury.io/py/rdbpython.svg)](https://pypi.org/project/rdbpython/)
52
52
  [![Python Versions](https://img.shields.io/pypi/pyversions/rdbpython.svg)](https://pypi.org/project/rdbpython/)
53
53
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
@@ -1,7 +1,7 @@
1
1
  # rdbpy
2
2
 
3
- [![Build Wheels](https://github.com/everyabc/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/build.yml)
4
- [![Tests](https://github.com/everyabc/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/test.yml)
3
+ [![Build Wheels](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml)
4
+ [![Tests](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml)
5
5
  [![PyPI version](https://badge.fury.io/py/rdbpython.svg)](https://pypi.org/project/rdbpython/)
6
6
  [![Python Versions](https://img.shields.io/pypi/pyversions/rdbpython.svg)](https://pypi.org/project/rdbpython/)
7
7
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
@@ -10,7 +10,7 @@ build-backend = "setuptools.build_meta"
10
10
  # ============================================================================
11
11
  [project]
12
12
  name = "rdbpython"
13
- version = "0.2.3"
13
+ version = "0.2.4"
14
14
  description = "Python bindings for RocksDB with Cython"
15
15
  readme = "README.md"
16
16
  license = "MIT"
@@ -47,10 +47,10 @@ requires-python = ">=3.9"
47
47
  dependencies = []
48
48
 
49
49
  [project.urls]
50
- Homepage = "https://github.com/everyabc/rdbpy"
51
- Documentation = "https://github.com/everyabc/rdbpy#readme"
52
- Repository = "https://github.com/everyabc/rdbpy"
53
- Issues = "https://github.com/everyabc/rdbpy/issues"
50
+ Homepage = "https://github.com/nustackdev/rdbpy"
51
+ Documentation = "https://github.com/nustackdev/rdbpy#readme"
52
+ Repository = "https://github.com/nustackdev/rdbpy"
53
+ Issues = "https://github.com/nustackdev/rdbpy/issues"
54
54
  PyPI = "https://pypi.org/project/rdbpython/"
55
55
 
56
56
  [project.optional-dependencies]
@@ -2682,10 +2682,19 @@ cdef class Transaction(object):
2682
2682
  self.closed = True
2683
2683
 
2684
2684
  def __dealloc__(self):
2685
- # If still open, rollback. RocksDB handles deletion after rollback.
2686
- if self.txn != NULL and not self.closed:
2687
- self.txn.Rollback()
2688
- self.txn = NULL
2685
+ # RocksDB's BeginTransaction returns a heap-allocated Transaction*
2686
+ # that the caller owns. Commit() and Rollback() do NOT delete the
2687
+ # object - we must `del` it explicitly. Without this, every
2688
+ # committed/rolled-back transaction leaks its WriteBatch and
2689
+ # tracking state.
2690
+ cdef transaction.Transaction* tmp = self.txn
2691
+ if tmp != NULL:
2692
+ if not self.closed:
2693
+ with nogil:
2694
+ tmp.Rollback()
2695
+ with nogil:
2696
+ del tmp
2697
+ self.txn = NULL
2689
2698
 
2690
2699
  cpdef void close(self):
2691
2700
  """Close the transaction by rolling it back."""
@@ -2702,10 +2711,12 @@ cdef class Transaction(object):
2702
2711
  cpdef void commit(self):
2703
2712
  self._ensure_open()
2704
2713
  cdef Status st
2714
+ cdef transaction.Transaction* tmp = self.txn
2705
2715
  with nogil:
2706
- st = self.txn.Commit()
2716
+ st = tmp.Commit()
2717
+ del tmp
2707
2718
  self.closed = True
2708
- self.txn = NULL # Pointer invalid after commit
2719
+ self.txn = NULL
2709
2720
  check_status(st)
2710
2721
 
2711
2722
  cpdef void rollback(self):
@@ -2714,10 +2725,12 @@ cdef class Transaction(object):
2714
2725
  if self.txn == NULL:
2715
2726
  return
2716
2727
  cdef Status st
2728
+ cdef transaction.Transaction* tmp = self.txn
2717
2729
  with nogil:
2718
- st = self.txn.Rollback()
2730
+ st = tmp.Rollback()
2731
+ del tmp
2719
2732
  self.closed = True
2720
- self.txn = NULL # Pointer invalid after rollback
2733
+ self.txn = NULL
2721
2734
  check_status(st)
2722
2735
 
2723
2736
  cpdef void prepare(self):
@@ -1,14 +1,14 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: rdbpython
3
- Version: 0.2.3
3
+ Version: 0.2.4
4
4
  Summary: Python bindings for RocksDB with Cython
5
5
  Author-email: Gor Arakelyan <gorarkln@gmail.com>
6
6
  Maintainer-email: Gor Arakelyan <gorarkln@gmail.com>
7
7
  License-Expression: MIT
8
- Project-URL: Homepage, https://github.com/everyabc/rdbpy
9
- Project-URL: Documentation, https://github.com/everyabc/rdbpy#readme
10
- Project-URL: Repository, https://github.com/everyabc/rdbpy
11
- Project-URL: Issues, https://github.com/everyabc/rdbpy/issues
8
+ Project-URL: Homepage, https://github.com/nustackdev/rdbpy
9
+ Project-URL: Documentation, https://github.com/nustackdev/rdbpy#readme
10
+ Project-URL: Repository, https://github.com/nustackdev/rdbpy
11
+ Project-URL: Issues, https://github.com/nustackdev/rdbpy/issues
12
12
  Project-URL: PyPI, https://pypi.org/project/rdbpython/
13
13
  Keywords: rocksdb,database,key-value,storage,embedded,cython
14
14
  Classifier: Development Status :: 3 - Alpha
@@ -46,8 +46,8 @@ Dynamic: license-file
46
46
 
47
47
  # rdbpy
48
48
 
49
- [![Build Wheels](https://github.com/everyabc/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/build.yml)
50
- [![Tests](https://github.com/everyabc/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/everyabc/rdbpy/actions/workflows/test.yml)
49
+ [![Build Wheels](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/build.yml)
50
+ [![Tests](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml/badge.svg)](https://github.com/nustackdev/rdbpy/actions/workflows/test.yml)
51
51
  [![PyPI version](https://badge.fury.io/py/rdbpython.svg)](https://pypi.org/project/rdbpython/)
52
52
  [![Python Versions](https://img.shields.io/pypi/pyversions/rdbpython.svg)](https://pypi.org/project/rdbpython/)
53
53
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
@@ -6,6 +6,4 @@ import pytest
6
6
  def pytest_configure(config: pytest.Config) -> None:
7
7
  """Register custom markers."""
8
8
  # Package markers
9
- config.addinivalue_line("markers", "everyshape: Tests for core everyshape package")
10
9
  config.addinivalue_line("markers", "rdbpy: Tests for RocksDB bindings")
11
- config.addinivalue_line("markers", "estup: Tests for tuple codec")
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes