jcrist opened a new issue, #826:
URL: https://github.com/apache/datafusion-python/issues/826
In `datafusion 40.1.0` a bug was added where a `SessionContext` cannot be
created when specifying only a `SessionConfig`. This is due to a small
copy-paste error in the `SessionContext.__init__`.
```python
In [1]: import datafusion
In [2]: config = datafusion.SessionConfig()
In [3]: ctx = datafusion.SessionContext(config)
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
Cell In[3], line 1
----> 1 ctx = datafusion.SessionContext(config)
File
~/miniforge3/envs/ibis/lib/python3.11/site-packages/datafusion/context.py:448,
in SessionContext.__init__(self, config, runtime)
427 """Main interface for executing queries with DataFusion.
428
429 Maintains the state of the connection between a user and an instance
(...)
445 df = ctx.read_csv("data.csv")
446 """
447 config = config.config_internal if config is not None else None
--> 448 runtime = runtime.config_internal if config is not None else None
450 self.ctx = SessionContextInternal(config, runtime)
AttributeError: 'NoneType' object has no attribute 'config_internal'
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]