From 4bc1781bb86d81ccc55c816cb60c7b36191fce5b Mon Sep 17 00:00:00 2001 From: Michael-J-Ward Date: Fri, 10 May 2024 16:03:56 -0500 Subject: [PATCH] docs: remove regexp_replace example This is the same underlying issue as #670. The new datafusion UDF functions don't properly handle optional arguments. --- .../source/generated/datafusion.DataFrame.rst | 60 +++++++++++++++++++ docs/source/generated/datafusion.Expr.rst | 38 ++++++++++++ .../generated/datafusion.RuntimeConfig.rst | 29 +++++++++ .../generated/datafusion.SessionConfig.rst | 35 +++++++++++ .../generated/datafusion.SessionContext.rst | 55 +++++++++++++++++ .../datafusion.functions.functions.rst | 23 +++++++ .../datafusion.object_store.object_store.rst | 23 +++++++ .../common-operations/functions.rst | 3 +- 8 files changed, 264 insertions(+), 2 deletions(-) create mode 100644 docs/source/generated/datafusion.DataFrame.rst create mode 100644 docs/source/generated/datafusion.Expr.rst create mode 100644 docs/source/generated/datafusion.RuntimeConfig.rst create mode 100644 docs/source/generated/datafusion.SessionConfig.rst create mode 100644 docs/source/generated/datafusion.SessionContext.rst create mode 100644 docs/source/generated/datafusion.functions.functions.rst create mode 100644 docs/source/generated/datafusion.object_store.object_store.rst diff --git a/docs/source/generated/datafusion.DataFrame.rst b/docs/source/generated/datafusion.DataFrame.rst new file mode 100644 index 000000000..9e18d8de7 --- /dev/null +++ b/docs/source/generated/datafusion.DataFrame.rst @@ -0,0 +1,60 @@ +datafusion.DataFrame +==================== + +.. currentmodule:: datafusion + +.. autoclass:: DataFrame + + + .. automethod:: __init__ + + + .. rubric:: Methods + + .. autosummary:: + + ~DataFrame.__init__ + ~DataFrame.aggregate + ~DataFrame.cache + ~DataFrame.collect + ~DataFrame.collect_partitioned + ~DataFrame.count + ~DataFrame.describe + ~DataFrame.distinct + ~DataFrame.except_all + ~DataFrame.execute_stream + ~DataFrame.execute_stream_partitioned + ~DataFrame.execution_plan + ~DataFrame.explain + ~DataFrame.filter + ~DataFrame.intersect + ~DataFrame.join + ~DataFrame.limit + ~DataFrame.logical_plan + ~DataFrame.optimized_logical_plan + ~DataFrame.repartition + ~DataFrame.repartition_by_hash + ~DataFrame.schema + ~DataFrame.select + ~DataFrame.select_columns + ~DataFrame.show + ~DataFrame.sort + ~DataFrame.to_arrow_table + ~DataFrame.to_pandas + ~DataFrame.to_polars + ~DataFrame.to_pydict + ~DataFrame.to_pylist + ~DataFrame.union + ~DataFrame.union_distinct + ~DataFrame.unnest_column + ~DataFrame.with_column + ~DataFrame.with_column_renamed + ~DataFrame.write_csv + ~DataFrame.write_json + ~DataFrame.write_parquet + + + + + + \ No newline at end of file diff --git a/docs/source/generated/datafusion.Expr.rst b/docs/source/generated/datafusion.Expr.rst new file mode 100644 index 000000000..ec3699b0f --- /dev/null +++ b/docs/source/generated/datafusion.Expr.rst @@ -0,0 +1,38 @@ +datafusion.Expr +=============== + +.. currentmodule:: datafusion + +.. autoclass:: Expr + + + .. automethod:: __init__ + + + .. rubric:: Methods + + .. autosummary:: + + ~Expr.__init__ + ~Expr.alias + ~Expr.canonical_name + ~Expr.cast + ~Expr.column + ~Expr.column_name + ~Expr.display_name + ~Expr.is_null + ~Expr.literal + ~Expr.python_value + ~Expr.rex_call_operands + ~Expr.rex_call_operator + ~Expr.rex_type + ~Expr.sort + ~Expr.to_variant + ~Expr.types + ~Expr.variant_name + + + + + + \ No newline at end of file diff --git a/docs/source/generated/datafusion.RuntimeConfig.rst b/docs/source/generated/datafusion.RuntimeConfig.rst new file mode 100644 index 000000000..aee08415c --- /dev/null +++ b/docs/source/generated/datafusion.RuntimeConfig.rst @@ -0,0 +1,29 @@ +datafusion.RuntimeConfig +======================== + +.. currentmodule:: datafusion + +.. autoclass:: RuntimeConfig + + + .. automethod:: __init__ + + + .. rubric:: Methods + + .. autosummary:: + + ~RuntimeConfig.__init__ + ~RuntimeConfig.with_disk_manager_disabled + ~RuntimeConfig.with_disk_manager_os + ~RuntimeConfig.with_disk_manager_specified + ~RuntimeConfig.with_fair_spill_pool + ~RuntimeConfig.with_greedy_memory_pool + ~RuntimeConfig.with_temp_file_path + ~RuntimeConfig.with_unbounded_memory_pool + + + + + + \ No newline at end of file diff --git a/docs/source/generated/datafusion.SessionConfig.rst b/docs/source/generated/datafusion.SessionConfig.rst new file mode 100644 index 000000000..3c466629a --- /dev/null +++ b/docs/source/generated/datafusion.SessionConfig.rst @@ -0,0 +1,35 @@ +datafusion.SessionConfig +======================== + +.. currentmodule:: datafusion + +.. autoclass:: SessionConfig + + + .. automethod:: __init__ + + + .. rubric:: Methods + + .. autosummary:: + + ~SessionConfig.__init__ + ~SessionConfig.set + ~SessionConfig.with_batch_size + ~SessionConfig.with_create_default_catalog_and_schema + ~SessionConfig.with_default_catalog_and_schema + ~SessionConfig.with_information_schema + ~SessionConfig.with_parquet_pruning + ~SessionConfig.with_repartition_aggregations + ~SessionConfig.with_repartition_file_min_size + ~SessionConfig.with_repartition_file_scans + ~SessionConfig.with_repartition_joins + ~SessionConfig.with_repartition_sorts + ~SessionConfig.with_repartition_windows + ~SessionConfig.with_target_partitions + + + + + + \ No newline at end of file diff --git a/docs/source/generated/datafusion.SessionContext.rst b/docs/source/generated/datafusion.SessionContext.rst new file mode 100644 index 000000000..d5e2a3adf --- /dev/null +++ b/docs/source/generated/datafusion.SessionContext.rst @@ -0,0 +1,55 @@ +datafusion.SessionContext +========================= + +.. currentmodule:: datafusion + +.. autoclass:: SessionContext + + + .. automethod:: __init__ + + + .. rubric:: Methods + + .. autosummary:: + + ~SessionContext.__init__ + ~SessionContext.catalog + ~SessionContext.create_dataframe + ~SessionContext.create_dataframe_from_logical_plan + ~SessionContext.deregister_table + ~SessionContext.empty_table + ~SessionContext.execute + ~SessionContext.from_arrow_table + ~SessionContext.from_pandas + ~SessionContext.from_polars + ~SessionContext.from_pydict + ~SessionContext.from_pylist + ~SessionContext.read_avro + ~SessionContext.read_csv + ~SessionContext.read_json + ~SessionContext.read_parquet + ~SessionContext.read_table + ~SessionContext.register_avro + ~SessionContext.register_csv + ~SessionContext.register_dataset + ~SessionContext.register_json + ~SessionContext.register_listing_table + ~SessionContext.register_object_store + ~SessionContext.register_parquet + ~SessionContext.register_record_batches + ~SessionContext.register_table + ~SessionContext.register_udaf + ~SessionContext.register_udf + ~SessionContext.session_id + ~SessionContext.sql + ~SessionContext.sql_with_options + ~SessionContext.table + ~SessionContext.table_exist + ~SessionContext.tables + + + + + + \ No newline at end of file diff --git a/docs/source/generated/datafusion.functions.functions.rst b/docs/source/generated/datafusion.functions.functions.rst new file mode 100644 index 000000000..eb10a67f0 --- /dev/null +++ b/docs/source/generated/datafusion.functions.functions.rst @@ -0,0 +1,23 @@ +datafusion.functions.functions +============================== + +.. automodule:: datafusion.functions.functions + + + + + + + + + + + + + + + + + + + diff --git a/docs/source/generated/datafusion.object_store.object_store.rst b/docs/source/generated/datafusion.object_store.object_store.rst new file mode 100644 index 000000000..7934ec323 --- /dev/null +++ b/docs/source/generated/datafusion.object_store.object_store.rst @@ -0,0 +1,23 @@ +datafusion.object\_store.object\_store +====================================== + +.. automodule:: datafusion.object_store.object_store + + + + + + + + + + + + + + + + + + + diff --git a/docs/source/user-guide/common-operations/functions.rst b/docs/source/user-guide/common-operations/functions.rst index 7e5c592d8..50b493098 100644 --- a/docs/source/user-guide/common-operations/functions.rst +++ b/docs/source/user-guide/common-operations/functions.rst @@ -92,13 +92,12 @@ DataFusion offers a range of helpful options. f.left(col('"Name"'), literal(4)).alias("code") ) -This also includes the functions for regular expressions :func:`.regexp_replace` and :func:`.regexp_match` +This also includes the functions for regular expressions like :func:`.regexp_match` .. ipython:: python df.select( f.regexp_match(col('"Name"'), literal("Char")).alias("dragons"), - f.regexp_replace(col('"Name"'), literal("saur"), literal("fleur")).alias("flowers") )