Hey Team, getting this error in our OSS implementa...
# ask-community
a
Hey Team, getting this error in our OSS implementation all of a sudden. We have been using Python GraphQL Client for a while but never got this before..
Copy code
sqlalchemy.exc.OperationalError: (psycopg2.OperationalError) SSL connection has been closed unexpectedly

[SQL: INSERT INTO event_logs (run_id, event, dagster_event_type, timestamp, step_key, asset_key, partition) VALUES (%(run_id)s, %(event)s, %(dagster_event_type)s, %(timestamp)s, %(step_key)s, %(asset_key)s, %(partition)s) RETURNING event_logs.run_id, event_logs.id]
[parameters: {'run_id': '28f30b2d-f74a-443e-842d-98d901921509', 'event': '{"__class__": "EventLogEntry", "dagster_event": {"__class__": "DagsterEvent", "event_specific_data": null, "event_type_value": "PIPELINE_ENQUEUED", " ... (256 characters truncated) ... ate_customer_infrastructure", "run_id": "28f30b2d-f74a-443e-842d-98d901921509", "step_key": null, "timestamp": 1688011188.979952, "user_message": ""}', 'dagster_event_type': 'PIPELINE_ENQUEUED', 'timestamp': datetime.datetime(2023, 6, 29, 3, 59, 48, 979952), 'step_key': None, 'asset_key': None, 'partition': None}]
(Background on this error at: <https://sqlalche.me/e/20/e3q8>)

  File "/usr/local/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 2108, in submit_run
    SubmitRunContext(run, workspace=workspace)
  File "/usr/local/lib/python3.7/site-packages/dagster/_core/run_coordinator/queued_run_coordinator.py", line 234, in submit_run
    self._instance.report_dagster_event(enqueued_event, run_id=dagster_run.run_id)
  File "/usr/local/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 1998, in report_dagster_event
    self.handle_new_event(event_record)
  File "/usr/local/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 1916, in handle_new_event
    self._event_storage.store_event(event)
  File "/usr/local/lib/python3.7/site-packages/dagster_postgres/event_log/event_log.py", line 179, in store_event
    SqlEventLogStorageTable.c.run_id, SqlEventLogStorageTable.c.id
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1416, in execute
    execution_options or NO_OPTIONS,
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/sql/elements.py", line 484, in _execute_on_connection
    self, distilled_params, execution_options
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1647, in _execute_clauseelement
    cache_hit=cache_hit,
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1847, in _execute_context
    dialect, context, statement, parameters
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1988, in _exec_single_context
    e, str_statement, effective_parameters, cursor, context
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 2344, in _handle_dbapi_exception
    raise sqlalchemy_exception.with_traceback(exc_info[2]) from e
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1969, in _exec_single_context
    cursor, str_statement, effective_parameters, context
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 920, in do_execute
    cursor.execute(statement, parameters)

The above exception was caused by the following exception:
psycopg2.OperationalError: SSL connection has been closed unexpectedly


  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1969, in _exec_single_context
    cursor, str_statement, effective_parameters, context
  File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 920, in do_execute
    cursor.execute(statement, parameters)
🤖 1
s
Hi Abhishek, This looks like a networking error-- can you say a little more about the conditions under which this is arising?
a
Hmm actually everything was working and then one of the jobs we triggered via the GraphQL client failed.. but then after some time it was working fine.. so I am not sure why this happened
maybe we can ignore for now
👍 1