vastdb 0.1.4__tar.gz → 0.1.5__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 (186) hide show
  1. {vastdb-0.1.4 → vastdb-0.1.5}/CHANGELOG.md +13 -0
  2. {vastdb-0.1.4/vastdb.egg-info → vastdb-0.1.5}/PKG-INFO +1 -1
  3. {vastdb-0.1.4 → vastdb-0.1.5}/README.md +8 -4
  4. {vastdb-0.1.4 → vastdb-0.1.5}/setup.py +3 -2
  5. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/internal_commands.py +25 -70
  6. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/session.py +2 -2
  7. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/table.py +31 -3
  8. vastdb-0.1.5/vastdb/tests/test_nested.py +102 -0
  9. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_tables.py +81 -78
  10. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/transaction.py +1 -1
  11. {vastdb-0.1.4 → vastdb-0.1.5/vastdb.egg-info}/PKG-INFO +1 -1
  12. vastdb-0.1.4/vastdb/tests/test_nested.py +0 -28
  13. {vastdb-0.1.4 → vastdb-0.1.5}/LICENSE +0 -0
  14. {vastdb-0.1.4 → vastdb-0.1.5}/MANIFEST.in +0 -0
  15. {vastdb-0.1.4 → vastdb-0.1.5}/requirements.txt +0 -0
  16. {vastdb-0.1.4 → vastdb-0.1.5}/setup.cfg +0 -0
  17. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/__init__.py +0 -0
  18. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/__init__.py +0 -0
  19. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/__init__.py +0 -0
  20. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/__init__.py +0 -0
  21. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/__init__.py +0 -0
  22. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Aggregate.py +0 -0
  23. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ArraySlice.py +0 -0
  24. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ArraySubscript.py +0 -0
  25. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/BinaryLiteral.py +0 -0
  26. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/BooleanLiteral.py +0 -0
  27. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Bound.py +0 -0
  28. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Call.py +0 -0
  29. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/CaseFragment.py +0 -0
  30. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Cast.py +0 -0
  31. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ConcreteBoundImpl.py +0 -0
  32. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ConditionalCase.py +0 -0
  33. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/CurrentRow.py +0 -0
  34. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/DateLiteral.py +0 -0
  35. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/DecimalLiteral.py +0 -0
  36. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Deref.py +0 -0
  37. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/DurationLiteral.py +0 -0
  38. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Expression.py +0 -0
  39. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ExpressionImpl.py +0 -0
  40. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/FieldIndex.py +0 -0
  41. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/FieldRef.py +0 -0
  42. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Filter.py +0 -0
  43. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/FixedSizeBinaryLiteral.py +0 -0
  44. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Float16Literal.py +0 -0
  45. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Float32Literal.py +0 -0
  46. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Float64Literal.py +0 -0
  47. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Following.py +0 -0
  48. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Frame.py +0 -0
  49. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Grouping.py +0 -0
  50. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Int16Literal.py +0 -0
  51. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Int32Literal.py +0 -0
  52. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Int64Literal.py +0 -0
  53. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Int8Literal.py +0 -0
  54. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/IntervalLiteral.py +0 -0
  55. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/IntervalLiteralDaysMilliseconds.py +0 -0
  56. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/IntervalLiteralImpl.py +0 -0
  57. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/IntervalLiteralMonths.py +0 -0
  58. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Join.py +0 -0
  59. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/JoinKind.py +0 -0
  60. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/KeyValue.py +0 -0
  61. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Limit.py +0 -0
  62. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/ListLiteral.py +0 -0
  63. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Literal.py +0 -0
  64. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/LiteralColumn.py +0 -0
  65. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/LiteralImpl.py +0 -0
  66. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/LiteralRelation.py +0 -0
  67. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/MapKey.py +0 -0
  68. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/MapLiteral.py +0 -0
  69. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/OrderBy.py +0 -0
  70. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Ordering.py +0 -0
  71. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Plan.py +0 -0
  72. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Preceding.py +0 -0
  73. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Project.py +0 -0
  74. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/RelId.py +0 -0
  75. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Relation.py +0 -0
  76. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/RelationImpl.py +0 -0
  77. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/SetOpKind.py +0 -0
  78. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/SetOperation.py +0 -0
  79. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/SimpleCase.py +0 -0
  80. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/SortKey.py +0 -0
  81. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Source.py +0 -0
  82. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/StringLiteral.py +0 -0
  83. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/StructField.py +0 -0
  84. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/StructLiteral.py +0 -0
  85. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/TimeLiteral.py +0 -0
  86. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/TimestampLiteral.py +0 -0
  87. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/UInt16Literal.py +0 -0
  88. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/UInt32Literal.py +0 -0
  89. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/UInt64Literal.py +0 -0
  90. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/UInt8Literal.py +0 -0
  91. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/Unbounded.py +0 -0
  92. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/WindowCall.py +0 -0
  93. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/computeir/flatbuf/__init__.py +0 -0
  94. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Binary.py +0 -0
  95. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Block.py +0 -0
  96. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/BodyCompression.py +0 -0
  97. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/BodyCompressionMethod.py +0 -0
  98. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Bool.py +0 -0
  99. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Buffer.py +0 -0
  100. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/CompressionType.py +0 -0
  101. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Date.py +0 -0
  102. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/DateUnit.py +0 -0
  103. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Decimal.py +0 -0
  104. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/DictionaryBatch.py +0 -0
  105. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/DictionaryEncoding.py +0 -0
  106. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/DictionaryKind.py +0 -0
  107. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Duration.py +0 -0
  108. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Endianness.py +0 -0
  109. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Feature.py +0 -0
  110. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Field.py +0 -0
  111. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/FieldNode.py +0 -0
  112. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/FixedSizeBinary.py +0 -0
  113. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/FixedSizeList.py +0 -0
  114. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/FloatingPoint.py +0 -0
  115. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Footer.py +0 -0
  116. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Int.py +0 -0
  117. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Interval.py +0 -0
  118. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/IntervalUnit.py +0 -0
  119. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/KeyValue.py +0 -0
  120. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/LargeBinary.py +0 -0
  121. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/LargeList.py +0 -0
  122. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/LargeUtf8.py +0 -0
  123. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/List.py +0 -0
  124. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Map.py +0 -0
  125. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Message.py +0 -0
  126. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/MessageHeader.py +0 -0
  127. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/MetadataVersion.py +0 -0
  128. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Null.py +0 -0
  129. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Precision.py +0 -0
  130. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/RecordBatch.py +0 -0
  131. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Schema.py +0 -0
  132. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseMatrixCompressedAxis.py +0 -0
  133. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseMatrixIndexCSX.py +0 -0
  134. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseTensor.py +0 -0
  135. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseTensorIndex.py +0 -0
  136. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseTensorIndexCOO.py +0 -0
  137. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/SparseTensorIndexCSF.py +0 -0
  138. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Struct_.py +0 -0
  139. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Tensor.py +0 -0
  140. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/TensorDim.py +0 -0
  141. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Time.py +0 -0
  142. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/TimeUnit.py +0 -0
  143. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Timestamp.py +0 -0
  144. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Type.py +0 -0
  145. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Union.py +0 -0
  146. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/UnionMode.py +0 -0
  147. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/Utf8.py +0 -0
  148. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/org/apache/arrow/flatbuf/__init__.py +0 -0
  149. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/AlterColumnRequest.py +0 -0
  150. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/AlterProjectionTableRequest.py +0 -0
  151. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/AlterSchemaRequest.py +0 -0
  152. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/AlterTableRequest.py +0 -0
  153. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/Column.py +0 -0
  154. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ColumnType.py +0 -0
  155. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/CreateProjectionRequest.py +0 -0
  156. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/CreateSchemaRequest.py +0 -0
  157. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/GetProjectionTableStatsResponse.py +0 -0
  158. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/GetTableStatsResponse.py +0 -0
  159. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ImportDataRequest.py +0 -0
  160. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ListProjectionsResponse.py +0 -0
  161. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ListSchemasResponse.py +0 -0
  162. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ListTablesResponse.py +0 -0
  163. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/ObjectDetails.py +0 -0
  164. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/S3File.py +0 -0
  165. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/VipRange.py +0 -0
  166. {vastdb-0.1.4 → vastdb-0.1.5}/vast_flatbuf/tabular/__init__.py +0 -0
  167. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/__init__.py +0 -0
  168. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/bench/__init__.py +0 -0
  169. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/bench/test_perf.py +0 -0
  170. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/bucket.py +0 -0
  171. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/conftest.py +0 -0
  172. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/errors.py +0 -0
  173. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/schema.py +0 -0
  174. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/__init__.py +0 -0
  175. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_duckdb.py +0 -0
  176. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_imports.py +0 -0
  177. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_projections.py +0 -0
  178. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_sanity.py +0 -0
  179. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_schemas.py +0 -0
  180. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/test_util.py +0 -0
  181. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/tests/util.py +0 -0
  182. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb/util.py +0 -0
  183. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb.egg-info/SOURCES.txt +0 -0
  184. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb.egg-info/dependency_links.txt +0 -0
  185. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb.egg-info/requires.txt +0 -0
  186. {vastdb-0.1.4 → vastdb-0.1.5}/vastdb.egg-info/top_level.txt +0 -0
@@ -4,6 +4,19 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/).
6
6
 
7
+ ## [0.1.5] (2024-05-16)
8
+ [0.1.5]: https://github.com/vast-data/vastdb_sdk/compare/v0.1.4...v0.1.5
9
+
10
+ ### Added
11
+ - Allow passing `ssl_verify` via `Session` c-tor
12
+ - Retry `requests.exceptions.ConnectionError`
13
+ - Document `QueryConfig` properties
14
+ - Support "deferred" `ibis` predicates using [Underscore (`_`) API](https://github.com/ibis-project/ibis/pull/3804)
15
+
16
+ ### Fixed
17
+ - Fix predicate pushdown when nested columns are present
18
+ - Attach original traceback to `MissingBucket` exception
19
+
7
20
  ## [0.1.4] (2024-05-13)
8
21
  [0.1.4]: https://github.com/vast-data/vastdb_sdk/compare/v0.1.3...v0.1.4
9
22
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: vastdb
3
- Version: 0.1.4
3
+ Version: 0.1.5
4
4
  Summary: VAST Data SDK
5
5
  Home-page: https://github.com/vast-data/vastdb_sdk
6
6
  Author: VAST DATA
@@ -74,16 +74,18 @@ with session.transaction() as tx:
74
74
  Our SDK supports predicate and projection pushdown:
75
75
 
76
76
  ```python
77
+ from ibis import _
78
+
77
79
  # SELECT c1 FROM t WHERE (c2 > 2) AND (c3 IS NULL)
78
80
  table.select(columns=['c1'],
79
- predicate=(table['c2'] > 2) & table['c3'].isnull())
81
+ predicate=(_.c2 > 2) & _.c3.isnull())
80
82
 
81
83
  # SELECT c2, c3 FROM t WHERE (c2 BETWEEN 0 AND 1) OR (c2 > 10)
82
84
  table.select(columns=['c2', 'c3'],
83
- predicate=table['c2'].between(0, 1) | (table['c2'] > 10))
85
+ predicate=(_.c2.between(0, 1) | (table['c2'] > 10))
84
86
 
85
87
  # SELECT * FROM t WHERE c3 LIKE '%substring%'
86
- table.select(predicate=table['c3'].contains('substring'))
88
+ table.select(predicate=_.c3.contains('substring'))
87
89
  ```
88
90
 
89
91
  See [here for more details](docs/predicate.md).
@@ -132,10 +134,12 @@ with contextlib.closing(pa.parquet.ParquetWriter('/path/to/file.parquet', batche
132
134
  We can use [DuckDB](https://duckdb.org/docs/guides/python/sql_on_arrow.html) to post-process the resulting stream of [PyArrow record batches](https://arrow.apache.org/docs/python/data.html#record-batches):
133
135
 
134
136
  ```python
137
+ from ibis import _
138
+
135
139
  import duckdb
136
140
  conn = duckdb.connect()
137
141
 
138
- batches = table.select(columns=['c1'], predicate=(table['c2'] > 2))
142
+ batches = table.select(columns=['c1'], predicate=(_.c2 > 2))
139
143
  print(conn.execute("SELECT sum(c1) FROM batches").arrow())
140
144
  ```
141
145
 
@@ -1,4 +1,5 @@
1
1
  import os
2
+ from pathlib import Path
2
3
 
3
4
  from setuptools import find_packages, setup
4
5
 
@@ -28,13 +29,13 @@ setup(
28
29
  name='vastdb',
29
30
  python_requires='>=3.9.0',
30
31
  description='VAST Data SDK',
31
- version='0.1.4' + suffix,
32
+ version='0.1.5' + suffix,
32
33
  url='https://github.com/vast-data/vastdb_sdk',
33
34
  author='VAST DATA',
34
35
  author_email='hello@vastdata.com',
35
36
  license='Copyright (C) VAST Data Ltd.',
36
37
  packages=find_packages(),
37
- install_requires=open('requirements.txt').read().strip().split('\n'),
38
+ install_requires=Path('requirements.txt').read_text().strip().split(),
38
39
  long_description=long_description,
39
40
  long_description_content_type='text/markdown',
40
41
  classifiers=[
@@ -130,46 +130,13 @@ def get_unit_to_flatbuff_time_unit(type):
130
130
  class Predicate:
131
131
  def __init__(self, schema: 'pa.Schema', expr: ibis.expr.types.BooleanColumn):
132
132
  self.schema = schema
133
+ index = itertools.count() # used to generate leaf column positions for VAST QueryData RPC
134
+ # Arrow schema contains the top-level columns, where each column may include multiple subfields
135
+ # We use DFS is used to enumerate all the sub-columns, using `index` as an ID allocator
136
+ nodes = [FieldNode(field, index) for field in schema]
137
+ self.nodes_map = {node.field.name: node for node in nodes}
133
138
  self.expr = expr
134
139
 
135
- def get_field_indexes(self, field: 'pa.Field', field_name_per_index: list) -> None:
136
- field_name_per_index.append(field.name)
137
-
138
- if isinstance(field.type, pa.StructType):
139
- flat_fields = field.flatten()
140
- elif isinstance(field.type, pa.MapType):
141
- flat_fields = [pa.field(f'{field.name}.entries', pa.struct([field.type.key_field, field.type.item_field]))]
142
- elif isinstance(field.type, pa.ListType):
143
- flat_fields = [pa.field(f'{field.name}.{field.type.value_field.name}', field.type.value_field.type)]
144
- else:
145
- return
146
-
147
- for flat_field in flat_fields:
148
- self.get_field_indexes(flat_field, field_name_per_index)
149
-
150
- @property
151
- def field_name_per_index(self):
152
- if self._field_name_per_index is None:
153
- _field_name_per_index = []
154
- for field in self.schema:
155
- self.get_field_indexes(field, _field_name_per_index)
156
- self._field_name_per_index = {field: index for index, field in enumerate(_field_name_per_index)}
157
- return self._field_name_per_index
158
-
159
- def get_projections(self, builder: 'flatbuffers.builder.Builder', field_names: Optional[List[str]] = None):
160
- if field_names is None:
161
- field_names = self.field_name_per_index.keys()
162
- projection_fields = []
163
- for field_name in field_names:
164
- fb_field_index.Start(builder)
165
- fb_field_index.AddPosition(builder, self.field_name_per_index[field_name])
166
- offset = fb_field_index.End(builder)
167
- projection_fields.append(offset)
168
- fb_source.StartProjectionVector(builder, len(projection_fields))
169
- for offset in reversed(projection_fields):
170
- builder.PrependUOffsetTRelative(offset)
171
- return builder.EndVector()
172
-
173
140
  def serialize(self, builder: 'flatbuffers.builder.Builder'):
174
141
  from ibis.expr.operations.generic import (
175
142
  IsNull,
@@ -204,8 +171,6 @@ class Predicate:
204
171
  Between: self.build_between,
205
172
  }
206
173
 
207
- positions_map = dict((f.name, index) for index, f in enumerate(self.schema)) # TODO: BFS
208
-
209
174
  self.builder = builder
210
175
 
211
176
  offsets = []
@@ -261,7 +226,11 @@ class Predicate:
261
226
  elif prev_field_name != field_name:
262
227
  raise NotImplementedError(self.expr)
263
228
 
264
- column_offset = self.build_column(position=positions_map[field_name])
229
+ node = self.nodes_map[field_name]
230
+ # TODO: support predicate pushdown for leaf nodes (ORION-160338)
231
+ if node.children:
232
+ raise NotImplementedError(node.field) # no predicate pushdown for nested columns
233
+ column_offset = self.build_column(position=node.index)
265
234
  field = self.schema.field(field_name)
266
235
  for literal in literals:
267
236
  args_offsets = [column_offset]
@@ -839,12 +808,13 @@ class VastdbApi:
839
808
  return prefix
840
809
 
841
810
  def _fill_common_headers(self, txid=0, client_tags=[], version_id=1):
842
- common_headers = {'tabular-txid': str(txid), 'tabular-api-version-id': str(version_id),
843
- 'tabular-client-name': 'tabular-api'}
844
- for tag in client_tags:
845
- common_headers['tabular-client-tags-%d' % client_tags.index(tag)] = tag
811
+ common_headers = {
812
+ 'tabular-txid': str(txid),
813
+ 'tabular-api-version-id': str(version_id),
814
+ 'tabular-client-name': 'tabular-api'
815
+ }
846
816
 
847
- return common_headers
817
+ return common_headers | {f'tabular-client-tags-{index}': tag for index, tag in enumerate(client_tags)}
848
818
 
849
819
  def _check_res(self, res, cmd="", expected_retvals=[]):
850
820
  if exc := errors.from_response(res):
@@ -952,8 +922,7 @@ class VastdbApi:
952
922
  res_headers = res.headers
953
923
  next_key = int(res_headers['tabular-next-key'])
954
924
  is_truncated = res_headers['tabular-is-truncated'] == 'true'
955
- flatbuf = b''.join(res.iter_content(chunk_size=128))
956
- lists = list_schemas.GetRootAs(flatbuf)
925
+ lists = list_schemas.GetRootAs(res.content)
957
926
  bucket_name = lists.BucketName().decode()
958
927
  if not bucket.startswith(bucket_name):
959
928
  raise ValueError(f'bucket: {bucket} did not start from {bucket_name}')
@@ -976,8 +945,7 @@ class VastdbApi:
976
945
  res = self.session.get(self._api_prefix(bucket=bucket, command="list", url_params=url_params), headers={}, stream=True)
977
946
  self._check_res(res, "list_snapshots")
978
947
 
979
- out = b''.join(res.iter_content(chunk_size=128))
980
- xml_str = out.decode()
948
+ xml_str = res.content.decode()
981
949
  xml_dict = xmltodict.parse(xml_str)
982
950
  list_res = xml_dict['ListBucketResult']
983
951
  is_truncated = list_res['IsTruncated'] == 'true'
@@ -1059,8 +1027,7 @@ class VastdbApi:
1059
1027
  res = self.session.get(self._api_prefix(bucket=bucket, schema=schema, table=name, command="stats", url_params=url_params), headers=headers)
1060
1028
  self._check_res(res, "get_table_stats", expected_retvals)
1061
1029
 
1062
- flatbuf = b''.join(res.iter_content(chunk_size=128))
1063
- stats = get_table_stats.GetRootAs(flatbuf)
1030
+ stats = get_table_stats.GetRootAs(res.content)
1064
1031
  num_rows = stats.NumRows()
1065
1032
  size_in_bytes = stats.SizeInBytes()
1066
1033
  is_external_rowid_alloc = stats.IsExternalRowidAlloc()
@@ -1159,8 +1126,7 @@ class VastdbApi:
1159
1126
  res_headers = res.headers
1160
1127
  next_key = int(res_headers['tabular-next-key'])
1161
1128
  is_truncated = res_headers['tabular-is-truncated'] == 'true'
1162
- flatbuf = b''.join(res.iter_content(chunk_size=128))
1163
- lists = list_tables.GetRootAs(flatbuf)
1129
+ lists = list_tables.GetRootAs(res.content)
1164
1130
  bucket_name = lists.BucketName().decode()
1165
1131
  schema_name = lists.SchemaName().decode()
1166
1132
  if not bucket.startswith(bucket_name): # ignore snapshot name
@@ -1288,11 +1254,7 @@ class VastdbApi:
1288
1254
  next_key = int(res_headers['tabular-next-key'])
1289
1255
  is_truncated = res_headers['tabular-is-truncated'] == 'true'
1290
1256
  count = int(res_headers['tabular-list-count'])
1291
- columns = []
1292
- if not count_only:
1293
- schema_buf = b''.join(res.iter_content(chunk_size=128))
1294
- schema_out = pa.ipc.open_stream(schema_buf).schema
1295
- columns = schema_out
1257
+ columns = [] if count_only else pa.ipc.open_stream(res.content).schema
1296
1258
 
1297
1259
  return columns, next_key, is_truncated, count
1298
1260
 
@@ -1692,8 +1654,7 @@ class VastdbApi:
1692
1654
  res = self.session.get(self._api_prefix(bucket=bucket, schema=schema, table=table, command="projection-stats", url_params=url_params),
1693
1655
  headers=headers)
1694
1656
  if res.status_code == 200:
1695
- flatbuf = b''.join(res.iter_content(chunk_size=128))
1696
- stats = get_projection_table_stats.GetRootAs(flatbuf)
1657
+ stats = get_projection_table_stats.GetRootAs(res.content)
1697
1658
  num_rows = stats.NumRows()
1698
1659
  size_in_bytes = stats.SizeInBytes()
1699
1660
  dirty_blocks_percentage = stats.DirtyBlocksPercentage()
@@ -1779,8 +1740,7 @@ class VastdbApi:
1779
1740
  next_key = int(res_headers['tabular-next-key'])
1780
1741
  is_truncated = res_headers['tabular-is-truncated'] == 'true'
1781
1742
  count = int(res_headers['tabular-list-count'])
1782
- flatbuf = b''.join(res.iter_content(chunk_size=128))
1783
- lists = list_projections.GetRootAs(flatbuf)
1743
+ lists = list_projections.GetRootAs(res.content)
1784
1744
  bucket_name = lists.BucketName().decode()
1785
1745
  schema_name = lists.SchemaName().decode()
1786
1746
  table_name = lists.TableName().decode()
@@ -1827,13 +1787,8 @@ class VastdbApi:
1827
1787
  next_key = int(res_headers['tabular-next-key'])
1828
1788
  is_truncated = res_headers['tabular-is-truncated'] == 'true'
1829
1789
  count = int(res_headers['tabular-list-count'])
1830
- columns = []
1831
- if not count_only:
1832
- schema_buf = b''.join(res.iter_content(chunk_size=128))
1833
- schema_out = pa.ipc.open_stream(schema_buf).schema
1834
- for f in schema_out:
1835
- columns.append([f.name, f.type, f.metadata])
1836
- # sort_type = f.metadata[b'VAST:sort_type'].decode()
1790
+ columns = [] if count_only else [[f.name, f.type, f.metadata] for f in
1791
+ pa.ipc.open_stream(res.content).schema]
1837
1792
 
1838
1793
  return columns, next_key, is_truncated, count
1839
1794
 
@@ -35,7 +35,7 @@ class Features:
35
35
  class Session:
36
36
  """VAST database session."""
37
37
 
38
- def __init__(self, access=None, secret=None, endpoint=None):
38
+ def __init__(self, access=None, secret=None, endpoint=None, ssl_verify=True):
39
39
  """Connect to a VAST Database endpoint, using specified credentials."""
40
40
  if access is None:
41
41
  access = os.environ['AWS_ACCESS_KEY_ID']
@@ -44,7 +44,7 @@ class Session:
44
44
  if endpoint is None:
45
45
  endpoint = os.environ['AWS_S3_ENDPOINT_URL']
46
46
 
47
- self.api = internal_commands.VastdbApi(endpoint, access, secret)
47
+ self.api = internal_commands.VastdbApi(endpoint, access, secret, ssl_verify=ssl_verify)
48
48
  version_tuple = tuple(int(part) for part in self.api.vast_version.split('.'))
49
49
  self.features = Features(version_tuple)
50
50
  self.s3 = boto3.client('s3',
@@ -12,6 +12,7 @@ from typing import Any, Dict, List, Optional, Tuple, Union
12
12
  import backoff
13
13
  import ibis
14
14
  import pyarrow as pa
15
+ import requests
15
16
 
16
17
  from . import errors, internal_commands, schema, util
17
18
 
@@ -39,20 +40,44 @@ class TableStats:
39
40
  endpoints: Tuple[str, ...] = ()
40
41
 
41
42
 
43
+ RETRIABLE_ERRORS = (
44
+ errors.Slowdown,
45
+ requests.exceptions.ConnectionError,
46
+ )
47
+
48
+
42
49
  @dataclass
43
50
  class QueryConfig:
44
51
  """Query execution configiration."""
45
52
 
53
+ # allows server-side parallel processing by issuing multiple reads concurrently for a single RPC
46
54
  num_sub_splits: int = 4
55
+
56
+ # used to split the table into disjoint subsets of rows, to be processed concurrently using multiple RPCs
47
57
  num_splits: int = 1
58
+
59
+ # each endpoint will be handled by a separate worker thread
60
+ # a single endpoint can be specified more than once to benefit from multithreaded execution
48
61
  data_endpoints: Optional[List[str]] = None
62
+
63
+ # a subsplit fiber will finish after sending this number of rows back to the client
49
64
  limit_rows_per_sub_split: int = 128 * 1024
65
+
66
+ # each fiber will read the following number of rowgroups coninuously before skipping
67
+ # in order to use semi-sorted projections this value must be 8
50
68
  num_row_groups_per_sub_split: int = 8
69
+
70
+ # can be disabled for benchmarking purposes
51
71
  use_semi_sorted_projections: bool = True
72
+
73
+ # used to estimate the number of splits, given the table rows' count
52
74
  rows_per_split: int = 4000000
75
+
76
+ # used for worker threads' naming
53
77
  query_id: str = ""
54
- max_slowdown_retry: int = 10
55
- backoff_func: Any = field(default=backoff.on_exception(backoff.expo, errors.Slowdown, max_tries=max_slowdown_retry))
78
+
79
+ # allows retrying QueryData when the server is overloaded
80
+ backoff_func: Any = field(default=backoff.on_exception(backoff.expo, RETRIABLE_ERRORS, max_tries=10))
56
81
 
57
82
 
58
83
  @dataclass
@@ -271,7 +296,7 @@ class Table:
271
296
  return TableStats(**stats_tuple._asdict())
272
297
 
273
298
  def select(self, columns: Optional[List[str]] = None,
274
- predicate: ibis.expr.types.BooleanColumn = None,
299
+ predicate: Union[ibis.expr.types.BooleanColumn, ibis.common.deferred.Deferred] = None,
275
300
  config: Optional[QueryConfig] = None,
276
301
  *,
277
302
  internal_row_id: bool = False) -> pa.RecordBatchReader:
@@ -310,6 +335,9 @@ class Table:
310
335
  response_schema = internal_commands.get_response_schema(schema=query_schema, field_names=columns)
311
336
  return pa.RecordBatchReader.from_batches(response_schema, [])
312
337
 
338
+ if isinstance(predicate, ibis.common.deferred.Deferred):
339
+ predicate = predicate.resolve(self._ibis_table) # may raise if the predicate is invalid (e.g. wrong types / missing column)
340
+
313
341
  query_data_request = internal_commands.build_query_data_request(
314
342
  schema=query_schema,
315
343
  predicate=predicate,
@@ -0,0 +1,102 @@
1
+ import functools
2
+ import itertools
3
+ import operator
4
+
5
+ import pyarrow as pa
6
+ import pyarrow.compute as pc
7
+ import pytest
8
+
9
+ from .util import prepare_data
10
+
11
+
12
+ def test_nested_select(session, clean_bucket_name):
13
+ columns = pa.schema([
14
+ ('l', pa.list_(pa.int8())),
15
+ ('m', pa.map_(pa.utf8(), pa.float64())),
16
+ ('s', pa.struct([('x', pa.int16()), ('y', pa.int32())])),
17
+ ])
18
+ expected = pa.table(schema=columns, data=[
19
+ [[1], [], [2, 3], None],
20
+ [None, {'a': 2.5}, {'b': 0.25, 'c': 0.025}, {}],
21
+ [{'x': 1, 'y': None}, None, {'x': 2, 'y': 3}, {'x': None, 'y': 4}],
22
+ ])
23
+
24
+ with prepare_data(session, clean_bucket_name, 's', 't', expected) as t:
25
+ actual = pa.Table.from_batches(t.select())
26
+ assert actual == expected
27
+
28
+ names = [f.name for f in columns]
29
+ for n in range(len(names) + 1):
30
+ for cols in itertools.permutations(names, n):
31
+ actual = pa.Table.from_batches(t.select(columns=cols))
32
+ assert actual == expected.select(cols)
33
+
34
+
35
+ def test_nested_filter(session, clean_bucket_name):
36
+ columns = pa.schema([
37
+ ('x', pa.int64()),
38
+ ('l', pa.list_(pa.int8())),
39
+ ('y', pa.int64()),
40
+ ('m', pa.map_(pa.utf8(), pa.float64())),
41
+ ('z', pa.int64()),
42
+ ('s', pa.struct([('x', pa.int16()), ('y', pa.int32())])),
43
+ ('w', pa.int64()),
44
+ ])
45
+ expected = pa.table(schema=columns, data=[
46
+ [1, 2, 3, None],
47
+ [[1], [], [2, 3], None],
48
+ [1, 2, None, 3],
49
+ [None, {'a': 2.5}, {'b': 0.25, 'c': 0.025}, {}],
50
+ [1, None, 2, 3],
51
+ [{'x': 1, 'y': None}, None, {'x': 2, 'y': 3}, {'x': None, 'y': 4}],
52
+ [None, 1, 2, 3],
53
+ ])
54
+
55
+ with prepare_data(session, clean_bucket_name, 's', 't', expected) as t:
56
+ actual = pa.Table.from_batches(t.select())
57
+ assert actual == expected
58
+
59
+ names = list('xyzw')
60
+ for n in range(1, len(names) + 1):
61
+ for cols in itertools.permutations(names, n):
62
+ ibis_predicate = functools.reduce(
63
+ operator.and_,
64
+ (t[col] > 2 for col in cols))
65
+ actual = pa.Table.from_batches(t.select(predicate=ibis_predicate), t.arrow_schema)
66
+
67
+ arrow_predicate = functools.reduce(
68
+ operator.and_,
69
+ (pc.field(col) > 2 for col in cols))
70
+ assert actual == expected.filter(arrow_predicate)
71
+
72
+
73
+ def test_nested_unsupported_filter(session, clean_bucket_name):
74
+ columns = pa.schema([
75
+ ('x', pa.int64()),
76
+ ('l', pa.list_(pa.int8())),
77
+ ('y', pa.int64()),
78
+ ('m', pa.map_(pa.utf8(), pa.float64())),
79
+ ('z', pa.int64()),
80
+ ('s', pa.struct([('x', pa.int16()), ('y', pa.int32())])),
81
+ ('w', pa.int64()),
82
+ ])
83
+ expected = pa.table(schema=columns, data=[
84
+ [1, 2, 3, None],
85
+ [[1], [], [2, 3], None],
86
+ [1, 2, None, 3],
87
+ [None, {'a': 2.5}, {'b': 0.25, 'c': 0.025}, {}],
88
+ [1, None, 2, 3],
89
+ [{'x': 1, 'y': None}, None, {'x': 2, 'y': 3}, {'x': None, 'y': 4}],
90
+ [None, 1, 2, 3],
91
+ ])
92
+
93
+ with prepare_data(session, clean_bucket_name, 's', 't', expected) as t:
94
+
95
+ with pytest.raises(NotImplementedError):
96
+ list(t.select(predicate=(t['l'].isnull())))
97
+
98
+ with pytest.raises(NotImplementedError):
99
+ list(t.select(predicate=(t['m'].isnull())))
100
+
101
+ with pytest.raises(NotImplementedError):
102
+ list(t.select(predicate=(t['s'].isnull())))