error while executing expectations #5669
Unanswered
sridhardataengineer
asked this question in
Support
Replies: 1 comment 2 replies
-
Hey @sridhardataengineer ! Thanks for reaching out. Are you able to confirm that your datasource is configured correctly? This appears to be a connection issue, which generally results from a mis-configured datasource / bad connection string / bad credentials. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
hi All,
i am new to this community, i am getting to understand great expectations and while running through lab , i got a error while running profiler. i pasted error below can someone help..?
Name the new Expectation Suite [mls_easports_v_1.mls_supporters.warning]: test_new_sf
Great Expectations will create a notebook, containing code cells that select from available columns in your dataset and
generate expectations about them to demonstrate some examples of assertions you can make about your data.
When you run this notebook, Great Expectations will store these expectations in a new Expectation Suite "test_new_sf" here:
file://C:\Users\dengineer1\great_expectations\great_expectations\expectations/test_new_sf.json
Would you like to proceed? [Y/n]: y
Please install the optional dependency 'black' to enable linting. Returning input with no changes.
Calculating Metrics: 0%| | 0/2 [00:03<?, ?it/s]
Exceptions
{('table.column_types', 'batch_id=e4c33775d14b35c84601318352c7d7a0', 'include_nested=True'): {'metric_configuration': {
"metric_name": "table.column_types",
"metric_domain_kwargs": {
"batch_id": "e4c33775d14b35c84601318352c7d7a0"
},
"metric_domain_kwargs_id": "batch_id=e4c33775d14b35c84601318352c7d7a0",
"metric_value_kwargs": {
"include_nested": true
},
"metric_value_kwargs_id": "include_nested=True",
"id": [
"table.column_types",
"batch_id=e4c33775d14b35c84601318352c7d7a0",
"include_nested=True"
]
}, 'num_failures': 3, 'exception_info': {{'exception_traceback': 'Traceback (most recent call last):\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\execution_engine\execution_engine.py", line 379, in resolve_metrics\n resolved_metrics[metric_to_resolve.id] = metric_fn(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\expectations\metrics\metric_provider.py", line 34, in inner_func\n return metric_fn(*args, **kwargs)\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\expectations\metrics\table_metrics\table_column_types.py", line 71, in _sqlalchemy\n return _get_sqlalchemy_column_metadata(execution_engine.engine, batch_data)\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\expectations\metrics\table_metrics\table_column_types.py", line 100, in _get_sqlalchemy_column_metadata\n return get_sqlalchemy_column_metadata(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\expectations\metrics\util.py", line 337, in get_sqlalchemy_column_metadata\n columns = inspector.get_columns(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\sqlalchemy\engine\reflection.py", line 497, in get_columns\n col_defs = self.dialect.get_columns(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\sqlalchemy\snowdialect.py", line 680, in get_columns\n schema_columns = self._get_schema_columns(connection, schema, **kw)\n File "", line 2, in _get_schema_columns\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\sqlalchemy\engine\reflection.py", line 55, in cache\n ret = fn(self, con, *args, **kw)\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\sqlalchemy\snowdialect.py", line 555, in _get_schema_columns\n type_instance = col_type(**col_type_kw)\nTypeError: 'NullType' object is not callable\n\nDuring handling of the above exception, another exception occurred:\n\nTraceback (most recent call last):\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 1294, in resolve_validation_graph\n self._resolve_metrics(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 2219, in _resolve_metrics\n return execution_engine.resolve_metrics(\n File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\execution_engine\execution_engine.py", line 383, in resolve_metrics\n raise ge_exceptions.MetricResolutionError(\ngreat_expectations.exceptions.exceptions.MetricResolutionError: 'NullType' object is not callable\n', 'exception_message': "'NullType' object is not callable", 'raised_exception': True}}}}
occurred while resolving metrics.
Traceback (most recent call last):
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\Scripts\great_expectations-script.py", line 9, in
sys.exit(main())
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\cli.py", line 190, in main
cli()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 1130, in call
return self.main(*args, **kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 1055, in main
rv = self.invoke(ctx)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 1657, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\click\decorators.py", line 26, in new_func
return f(get_current_context(), *args, **kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\suite.py", line 151, in suite_new
_suite_new_workflow(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\suite.py", line 335, in _suite_new_workflow
raise e
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\suite.py", line 298, in _suite_new_workflow
_suite_edit_workflow(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\suite.py", line 862, in _suite_edit_workflow
raise e
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\cli\suite.py", line 800, in _suite_edit_workflow
renderer.render_to_disk(notebook_file_path=notebook_path)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\render\renderer\v3\suite_profile_notebook_renderer.py", line 68, in render_to_disk
self.render()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\render\renderer\v3\suite_profile_notebook_renderer.py", line 58, in render
self._add_user_configurable_profiler_cells()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\render\renderer\v3\suite_profile_notebook_renderer.py", line 172, in _add_user_configurable_profiler_cells
self._add_available_columns_list()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\render\renderer\v3\suite_profile_notebook_renderer.py", line 369, in _add_available_columns_list
f' "{column_name}",\n' for column_name in self._validator.columns()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 2139, in columns
columns: List[str] = self.get_metric(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 898, in get_metric
return self.get_metrics(metrics={metric.metric_name: metric})[
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 863, in get_metrics
return {
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\great_expectations\validator\validator.py", line 864, in
metric_configuration.metric_name: resolved_metrics[metric_configuration.id]
KeyError: ('table.columns', 'batch_id=e4c33775d14b35c84601318352c7d7a0', ())
Exception during reset or similar
Traceback (most recent call last):
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\sqlalchemy\pool\base.py", line 739, in _finalize_fairy
fairy._reset(pool)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\sqlalchemy\pool\base.py", line 988, in _reset
pool._dialect.do_rollback(self)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\sqlalchemy\engine\default.py", line 682, in do_rollback
dbapi_connection.rollback()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\connection.py", line 618, in rollback
self.cursor().execute("ROLLBACK")
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\cursor.py", line 716, in execute
ret = self._execute_helper(query, **kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\cursor.py", line 516, in _execute_helper
ret = self._connection.cmd_query(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\connection.py", line 1004, in cmd_query
ret = self.rest.request(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 465, in request
return self._post_request(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 704, in _post_request
ret = self.fetch(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 794, in fetch
ret = self._request_exec_wrapper(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 917, in _request_exec_wrapper
raise e
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 837, in _request_exec_wrapper
return_object = self._request_exec(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 1116, in _request_exec
raise err
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\network.py", line 1018, in _request_exec
raw_ret = session.request(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\requests\sessions.py", line 587, in request
resp = self.send(prep, **send_kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\requests\sessions.py", line 701, in send
r = adapter.send(request, **kwargs)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\requests\adapters.py", line 489, in send
resp = conn.urlopen(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\urllib3\connectionpool.py", line 703, in urlopen
httplib_response = self._make_request(
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\urllib3\connectionpool.py", line 386, in _make_request
self._validate_conn(conn)
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\urllib3\connectionpool.py", line 1042, in _validate_conn
conn.connect()
File "C:\Users\dengineer1\Anaconda3\envs\greatexpectations\lib\site-packages\snowflake\connector\vendored\urllib3\connection.py", line 380, in connect
is_time_off = datetime.date.today() < RECENT_DATE
ImportError: sys.meta_path is None, Python is likely shutting down
Beta Was this translation helpful? Give feedback.
All reactions