Showing with 8,519 additions and 4,184 deletions.
  1. +6 −0 .commitlintrc.json
  2. +20 −0 .conventionalcommits.js
  3. +0 −3 .czrc
  4. +1 −1 .github/workflows/assign.yml
  5. +1 −0 .github/workflows/auto-rebase.yml
  6. +13 −15 .github/workflows/check-generated-files.yml
  7. +5 −0 .github/workflows/ci-data.yml
  8. +2 −0 .github/workflows/ibis-backends-skip-helper.yml
  9. +6 −4 .github/workflows/ibis-backends.yml
  10. +47 −23 .github/workflows/ibis-docs-lint.yml
  11. +2 −0 .github/workflows/ibis-main-skip-helper.yml
  12. +15 −3 .github/workflows/ibis-main.yml
  13. +1 −1 .github/workflows/ibis-tpch-queries.yml
  14. +1 −0 .github/workflows/nix.yml
  15. +3 −3 .github/workflows/update-deps.yml
  16. +1 −0 .gitignore
  17. +0 −9 .pep8speaks.yml
  18. +6 −6 .pre-commit-config.yaml
  19. +1 −0 .prettierignore
  20. +91 −0 .releaserc.js
  21. +0 −64 .releaserc.json
  22. +0 −4 .rgignore
  23. +0 −19 LICENSES/hdfscli.txt
  24. +1 −0 README.md
  25. +11 −8 ci/release/dry_run.sh
  26. +11 −5 ci/release/verify.sh
  27. +152 −150 conda-lock/linux-64-3.10.lock
  28. +138 −136 conda-lock/linux-64-3.8.lock
  29. +138 −136 conda-lock/linux-64-3.9.lock
  30. +158 −156 conda-lock/osx-64-3.10.lock
  31. +144 −142 conda-lock/osx-64-3.8.lock
  32. +144 −142 conda-lock/osx-64-3.9.lock
  33. +137 −136 conda-lock/win-64-3.10.lock
  34. +162 −161 conda-lock/win-64-3.8.lock
  35. +163 −162 conda-lock/win-64-3.9.lock
  36. +21 −0 dev/lockfile_diff.sh
  37. +3 −2 dev/poetry2setup
  38. +14 −0 dev/update-lock-files.sh
  39. +3 −3 docker-compose.yml
  40. +1 −1 docker/postgres/Dockerfile
  41. +50 −0 docs/CODE_OF_CONDUCT.md
  42. +11 −0 docs/CONTRIBUTING.md
  43. +4 −1 docs/SUMMARY.md
  44. +3 −3 docs/api/datatypes.md
  45. +4 −11 docs/api/expressions/collections.md
  46. +3 −7 docs/api/expressions/generic.md
  47. +2 −1 docs/api/expressions/geospatial.md
  48. +12 −3 docs/api/expressions/numeric.md
  49. +1 −1 docs/api/expressions/strings.md
  50. +2 −2 docs/api/expressions/tables.md
  51. +6 −2 docs/api/expressions/timestamps.md
  52. +8 −0 docs/api/expressions/top_level.md
  53. +5 −0 docs/api/schemas.md
  54. +8 −0 docs/backends/DuckDB.md
  55. +1 −1 docs/blog/Ibis-version-3.0.0-release.md
  56. +1 −1 docs/blog/Ibis-version-3.1.0-release.md
  57. +376 −0 docs/blog/ffill-and-bfill-using-ibis.md
  58. +0 −21 docs/community/coc.md
  59. +1 −1 docs/contribute/05_maintainers_guide.md
  60. +112 −0 docs/how_to/duckdb_register.md
  61. +87 −0 docs/how_to/ffill_bfill_w_window.md
  62. +37 −0 docs/how_to/topk.md
  63. +135 −0 docs/release_notes.md
  64. +1 −1 docs/tutorial/01-Introduction-to-Ibis.ipynb
  65. +1 −1 docs/tutorial/04-More-Value-Expressions.ipynb
  66. +0 −88 docs/user_guide/topk.md
  67. +0 −20 docs/user_guide/udfs.md
  68. +11 −19 ibis/__init__.py
  69. +69 −22 ibis/backends/base/__init__.py
  70. +50 −2 ibis/backends/base/sql/__init__.py
  71. +27 −6 ibis/backends/base/sql/alchemy/__init__.py
  72. +68 −2 ibis/backends/base/sql/alchemy/datatypes.py
  73. +58 −17 ibis/backends/base/sql/alchemy/query_builder.py
  74. +26 −2 ibis/backends/base/sql/alchemy/registry.py
  75. +19 −14 ibis/backends/base/sql/alchemy/translator.py
  76. +9 −4 ibis/backends/base/sql/compiler/base.py
  77. +50 −41 ibis/backends/base/sql/compiler/query_builder.py
  78. +47 −3 ibis/backends/base/sql/compiler/select_builder.py
  79. +14 −1 ibis/backends/base/sql/registry/main.py
  80. +18 −1 ibis/backends/clickhouse/__init__.py
  81. +8 −2 ibis/backends/clickhouse/compiler.py
  82. +31 −0 ibis/backends/clickhouse/datatypes.py
  83. +45 −19 ibis/backends/clickhouse/registry.py
  84. +12 −0 ibis/backends/clickhouse/tests/test_client.py
  85. +1 −1 ibis/backends/clickhouse/tests/test_select.py
  86. +9 −0 ibis/backends/clickhouse/tests/test_types.py
  87. +69 −46 ibis/backends/conftest.py
  88. +1 −1 ibis/backends/dask/core.py
  89. +20 −13 ibis/backends/dask/execution/generic.py
  90. +37 −56 ibis/backends/dask/execution/indexing.py
  91. +20 −0 ibis/backends/dask/execution/reductions.py
  92. +9 −9 ibis/backends/dask/execution/selection.py
  93. +7 −0 ibis/backends/dask/execution/strings.py
  94. +19 −7 ibis/backends/dask/tests/execution/test_operations.py
  95. +69 −31 ibis/backends/duckdb/__init__.py
  96. +29 −0 ibis/backends/duckdb/compiler.py
  97. +10 −3 ibis/backends/duckdb/datatypes.py
  98. +12 −2 ibis/backends/duckdb/registry.py
  99. +10 −0 ibis/backends/duckdb/tests/test_datatypes.py
  100. +24 −0 ibis/backends/duckdb/tests/test_register.py
  101. +5 −5 ibis/backends/impala/__init__.py
  102. +2 −2 ibis/backends/impala/tests/test_case_exprs.py
  103. +7 −7 ibis/backends/impala/tests/test_client.py
  104. +2 −3 ibis/backends/impala/tests/test_exprs.py
  105. +4 −4 ibis/backends/impala/tests/test_patched.py
  106. +1 −5 ibis/backends/impala/tests/test_unary_builtins.py
  107. +2 −0 ibis/backends/impala/udf.py
  108. +13 −4 ibis/backends/mysql/tests/test_client.py
  109. +3 −2 ibis/backends/pandas/__init__.py
  110. +37 −2 ibis/backends/pandas/client.py
  111. +1 −1 ibis/backends/pandas/core.py
  112. +152 −66 ibis/backends/pandas/execution/generic.py
  113. +6 −10 ibis/backends/pandas/execution/join.py
  114. +9 −0 ibis/backends/pandas/execution/strings.py
  115. +15 −3 ibis/backends/pandas/tests/execution/test_operations.py
  116. +1 −4 ibis/backends/pandas/tests/execution/test_window.py
  117. +9 −0 ibis/backends/pandas/tests/test_datatypes.py
  118. +15 −0 ibis/backends/pandas/tests/test_udf.py
  119. +5 −1 ibis/backends/postgres/registry.py
  120. +24 −32 ibis/backends/postgres/tests/test_functions.py
  121. +60 −10 ibis/backends/pyspark/__init__.py
  122. +289 −175 ibis/backends/pyspark/compiler.py
  123. +8 −8 ibis/backends/pyspark/tests/conftest.py
  124. +47 −0 ibis/backends/pyspark/tests/test_aggregation.py
  125. +2 −2 ibis/backends/pyspark/tests/test_null.py
  126. +16 −5 ibis/backends/sqlite/__init__.py
  127. +3 −0 ibis/backends/sqlite/registry.py
  128. +10 −0 ibis/backends/sqlite/udf.py
  129. +71 −27 ibis/backends/tests/test_aggregation.py
  130. +16 −0 ibis/backends/tests/test_api.py
  131. +378 −10 ibis/backends/tests/test_client.py
  132. +290 −119 ibis/backends/tests/test_generic.py
  133. +2 −7 ibis/backends/tests/test_join.py
  134. +8 −16 ibis/backends/tests/test_numeric.py
  135. +93 −0 ibis/backends/tests/test_pretty.py
  136. +130 −0 ibis/backends/tests/test_set_ops.py
  137. +9 −3 ibis/backends/tests/test_string.py
  138. +2 −1 ibis/backends/tests/test_struct.py
  139. +47 −2 ibis/backends/tests/test_temporal.py
  140. +1 −1 ibis/backends/tests/test_timecontext.py
  141. +0 −37 ibis/backends/tests/test_union.py
  142. +1 −1 ibis/backends/tests/test_vectorized_udf.py
  143. +94 −18 ibis/backends/tests/test_window.py
  144. +11 −1 ibis/common/dispatch.py
  145. +16 −7 ibis/common/grounds.py
  146. +108 −0 ibis/common/pretty.py
  147. +39 −1 ibis/config.py
  148. +27 −8 ibis/expr/analysis.py
  149. +309 −110 ibis/expr/api.py
  150. +13 −3 ibis/expr/datatypes/core.py
  151. +16 −0 ibis/expr/format.py
  152. +1 −0 ibis/expr/operations/__init__.py
  153. +3 −37 ibis/expr/operations/generic.py
  154. +38 −0 ibis/expr/operations/numeric.py
  155. +14 −0 ibis/expr/operations/reductions.py
  156. +24 −5 ibis/expr/operations/relations.py
  157. +2 −3 ibis/expr/operations/sortkeys.py
  158. +50 −0 ibis/expr/operations/structs.py
  159. +1 −1 ibis/expr/operations/temporal.py
  160. +68 −27 ibis/expr/rules.py
  161. +231 −43 ibis/expr/schema.py
  162. +36 −10 ibis/expr/types/core.py
  163. +50 −11 ibis/expr/types/generic.py
  164. +9 −9 ibis/expr/types/geospatial.py
  165. +2 −1 ibis/expr/types/groupby.py
  166. +2 −2 ibis/expr/types/logical.py
  167. +72 −1 ibis/expr/types/numeric.py
  168. +220 −72 ibis/expr/types/relations.py
  169. +64 −26 ibis/expr/types/strings.py
  170. +37 −0 ibis/expr/types/structs.py
  171. +3 −1 ibis/tests/benchmarks/test_benchmarks.py
  172. +1 −1 ibis/tests/expr/test_analysis.py
  173. +31 −0 ibis/tests/expr/test_decimal.py
  174. +76 −55 ibis/tests/expr/test_operations.py
  175. +44 −0 ibis/tests/expr/test_struct.py
  176. +44 −0 ibis/tests/expr/test_table.py
  177. +85 −1 ibis/tests/expr/test_value_exprs.py
  178. +13 −21 ibis/tests/sql/test_compiler.py
  179. +1 −1 ibis/tests/sql/test_non_tabular_results.py
  180. +7 −6 ibis/tests/sql/test_select_sql.py
  181. +5 −0 ibis/tests/sql/test_sqlalchemy.py
  182. +1 −1 ibis/tests/test_api.py
  183. +19 −26 ibis/util.py
  184. +9 −6 justfile
  185. +4 −0 lychee.toml
  186. +2 −0 mkdocs.yml
  187. +2 −22 nix/default.nix
  188. +9 −9 nix/sources.json
  189. +60 −25 poetry-overrides.nix
  190. +1,190 −920 poetry.lock
  191. +45 −32 pyproject.toml
  192. +84 −80 requirements.txt
  193. +26 −17 setup.py
  194. +3 −5 shell.nix
6 changes: 6 additions & 0 deletions .commitlintrc.json
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
"build",
"chore",
"ci",
"depr",
"docs",
"feat",
"fix",
Expand Down Expand Up @@ -52,6 +53,11 @@
"title": "Documentation",
"emoji": "📚"
},
"depr": {
"description": "Deprecated APIs and behaviors",
"title": "Deprecations",
"emoji": ""
},
"style": {
"description": "Changes that do not affect the meaning of the code (whitespace, formatting, missing semi-colons, etc)",
"title": "Styles",
Expand Down
20 changes: 20 additions & 0 deletions .conventionalcommits.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
"use strict";

const releaseConfig = require("./.releaserc.js");

function extractConventionalCommitsConfig(config) {
return config.plugins
.filter(
([plugin, _]) => plugin == "@semantic-release/release-notes-generator"
)
.map(([_, config]) => config)[0].presetConfig.types;
}

module.exports = {
options: {
preset: {
name: "conventionalcommits",
types: extractConventionalCommitsConfig(releaseConfig),
},
},
};
3 changes: 0 additions & 3 deletions .czrc

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/assign.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ jobs:
runs-on: ubuntu-latest
if: ${{ github.event.comment.body == '/take' }}
steps:
- uses: pozil/auto-assign-issue@v1.8.0
- uses: pozil/auto-assign-issue@v1.10.0
with:
assignees: ${{ github.event.comment.user.login }}
1 change: 1 addition & 0 deletions .github/workflows/auto-rebase.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ on:
- labeled
jobs:
auto-rebase:
if: github.repository == 'ibis-project/ibis'
runs-on: ubuntu-latest
steps:
- uses: tibdex/github-app-token@v1
Expand Down
28 changes: 13 additions & 15 deletions .github/workflows/check-generated-files.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- README.md
- poetry.lock
- pyproject.toml
- requirements.txt
- setup.py
- .github/workflows/check-setup-py.yml
pull_request:
Expand All @@ -17,6 +18,7 @@ on:
- README.md
- poetry.lock
- pyproject.toml
- requirements.txt
- setup.py
- .github/workflows/check-setup-py.yml

Expand Down Expand Up @@ -50,8 +52,6 @@ jobs:

check_setuptools_install:
runs-on: ubuntu-latest
needs:
- check_setup_py
steps:
- name: checkout
uses: actions/checkout@v3
Expand All @@ -69,7 +69,7 @@ jobs:
run: sudo apt-get install -y -q build-essential graphviz krb5-config libkrb5-dev libgeos-dev

- name: install poetry
run: pip install poetry
run: pip install 'poetry<1.2'

- name: generate requirements.txt
run: poetry export --dev --extras all --without-hashes --no-ansi > requirements.txt
Expand Down Expand Up @@ -108,18 +108,16 @@ jobs:
- name: checkout
uses: actions/checkout@v3

- name: install python
uses: actions/setup-python@v4
- name: install nix
uses: cachix/install-nix-action@v17
with:
python-version: "3.10"

- name: install poetry
run: pip install poetry
nix_path: nixpkgs=channel:nixos-unstable-small

- name: run poetry lock
run: poetry lock --no-update
env:
PYTHONHASHSEED: "42"
- name: setup cachix
uses: cachix/cachix-action@v10
with:
name: ibis
extraPullNames: nix-community,poetry2nix

- name: check whether poetry lockfile needs to be updated
run: git diff --exit-code poetry.lock
- name: verify lockfile
run: ./dev/lockfile_diff.sh
5 changes: 5 additions & 0 deletions .github/workflows/ci-data.yml
Original file line number Diff line number Diff line change
Expand Up @@ -56,4 +56,9 @@ jobs:
for table in workflows jobs; do
gsuri="gs://ibis-workflow-data/${yesterday}/${table}.json"
gsutil cp -Z "${table}.json" "${gsuri}"
bq load \
--autodetect=true \
--source_format=NEWLINE_DELIMITED_JSON \
"workflows_native.${table}" \
"${gsuri}"
done
2 changes: 2 additions & 0 deletions .github/workflows/ibis-backends-skip-helper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,14 @@ on:
push:
paths:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
pull_request:
paths:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
Expand Down
10 changes: 6 additions & 4 deletions .github/workflows/ibis-backends.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,15 @@ on:
# Skip the backend suite if all changes are in the docs directory
paths-ignore:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
pull_request:
# Skip the backend suite if all changes are in the docs directory
paths-ignore:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
Expand Down Expand Up @@ -143,7 +145,7 @@ jobs:
requirement_files: poetry.lock
custom_cache_key_element: ${{ matrix.backend.name }}-${{ steps.install_python.outputs.python-version }}

- run: python -m pip install --upgrade pip poetry
- run: python -m pip install --upgrade pip 'poetry<1.2'

- name: install ibis
if: ${{ matrix.backend.name != 'postgres' }}
Expand All @@ -158,11 +160,11 @@ jobs:
- name: download backend data
run: just download-data

- name: run parallel ${{ matrix.backend.name }} tests
- name: "run parallel tests: ${{ matrix.backend.name }}"
if: ${{ matrix.backend.name != 'pyspark' && matrix.backend.name != 'impala' }}
run: just ci-check -m ${{ matrix.backend.name }} --numprocesses auto --dist=loadgroup

- name: run non-parallel ${{ matrix.backend.name }} tests
- name: "run serial tests: ${{ matrix.backend.name }}"
if: ${{ matrix.backend.name == 'pyspark' || matrix.backend.name == 'impala' }}
run: just ci-check -m ${{ matrix.backend.name }}
env:
Expand Down Expand Up @@ -236,7 +238,7 @@ jobs:
with:
python-version: ${{ matrix.python-version }}

- run: python -m pip install --upgrade pip poetry
- run: python -m pip install --upgrade pip 'poetry<1.2'

- name: install minimum versions
run: poetry add --lock --optional ${{ join(matrix.backend.deps, ' ') }}
Expand Down
70 changes: 47 additions & 23 deletions .github/workflows/ibis-docs-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,6 +63,7 @@ jobs:

benchmarks:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'push' }}
steps:
- name: checkout
uses: actions/checkout@v3
Expand All @@ -86,25 +87,24 @@ jobs:
requirement_files: poetry.lock
custom_cache_key_element: benchmarks-${{ steps.install_python.outputs.python-version }}

- run: python -m pip install --upgrade pip poetry
- run: python -m pip install --upgrade pip 'poetry<1.2'

- name: install ibis
run: poetry install --extras all

- run: mkdir .benchmarks
- name: make benchmark output dir
run: mkdir .benchmarks

- name: benchmark
run: poetry run pytest --benchmark-only --benchmark-json .benchmarks/output.json ibis/tests/benchmarks
run: poetry run pytest --benchmark-enable --benchmark-json .benchmarks/output.json ibis/tests/benchmarks

- uses: tibdex/github-app-token@v1
if: ${{ github.event_name == 'push' }}
id: generate-token
with:
app_id: ${{ secrets.SQUAWK_BOT_APP_ID }}
private_key: ${{ secrets.SQUAWK_BOT_APP_PRIVATE_KEY }}

- uses: benchmark-action/github-action-benchmark@v1
if: ${{ github.event_name == 'push' }}
with:
tool: pytest
github-token: ${{ steps.generate-token.outputs.token }}
Expand All @@ -114,13 +114,10 @@ jobs:
comment-on-alert: true
alert-threshold: "300%"

docs:
docs_pr:
runs-on: ubuntu-latest
if: ${{ github.event_name != 'push' }}
concurrency: docs-${{ github.repository }}-${{ github.head_ref || github.sha }}
needs:
# wait on benchmarks to prevent a race condition when pushing to the
# gh-pages branch
- benchmarks
steps:
- name: install nix
uses: cachix/install-nix-action@v17
Expand All @@ -136,43 +133,57 @@ jobs:

- name: checkout
uses: actions/checkout@v3
if: ${{ github.event_name != 'push' }}
with:
fetch-depth: 0

- name: build docs
run: nix run -f nix ibisDevEnv310 -- -m mkdocs build

- name: verify internal links
run: nix shell -f nix --ignore-environment bash findutils just lychee -c just checklinks --offline --no-progress

docs_push:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'push' }}
concurrency: docs-${{ github.repository }}-${{ github.head_ref || github.sha }}
needs:
# wait on benchmarks to prevent a race condition when pushing to the
# gh-pages branch
- benchmarks
steps:
- name: install nix
uses: cachix/install-nix-action@v17
with:
nix_path: nixpkgs=channel:nixos-unstable-small

- name: setup cachix
uses: cachix/cachix-action@v10
with:
name: ibis
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
extraPullNames: nix-community,poetry2nix

- name: Generate a GitHub token
uses: tibdex/github-app-token@v1
if: ${{ github.event_name == 'push' }}
id: generate_token
with:
app_id: ${{ secrets.DOCS_BOT_APP_ID }}
private_key: ${{ secrets.DOCS_BOT_APP_PRIVATE_KEY }}

- name: checkout
uses: actions/checkout@v3
if: ${{ github.event_name == 'push' }}
with:
fetch-depth: 0
token: ${{ steps.generate_token.outputs.token }}

- name: build docs
if: ${{ github.event_name != 'push' }}
run: nix run -f nix ibisDevEnv310 -- -m mkdocs build

- name: verify internal links
if: ${{ github.event_name != 'push' }}
run: nix shell -f nix --ignore-environment bash findutils just lychee -c just checklinks --offline --no-progress

- name: Configure git info
if: ${{ github.event_name == 'push' }}
run: |
set -euo pipefail
git config user.name 'ibis-docs-bot[bot]'
git config user.email 'ibis-docs-bot[bot]@users.noreply.github.com'
- name: build and push dev docs
if: ${{ github.event_name == 'push' }}
run: |
set -euo pipefail
Expand Down Expand Up @@ -203,5 +214,18 @@ jobs:
authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
extraPullNames: nix-community,poetry2nix

- name: Configure git info
run: |
set -euo pipefail
# not incredibly important what user we use here
#
# we're making a commit in a temporary worktree that is thrown away
# if the process exits successfully
#
# git requires user information to make commits
git config user.name 'ibis-squawk-bot[bot]'
git config user.email 'ibis-squawk-bot[bot]@users.noreply.github.com'
- name: run semantic-release
run: ./ci/release/dry_run.sh
2 changes: 2 additions & 0 deletions .github/workflows/ibis-main-skip-helper.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,14 @@ on:
push:
paths:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
pull_request:
paths:
- "docs/**"
- "mkdocs.yml"
branches:
- master
- "*.x.x"
Expand Down
Loading