https://dagster.io/ logo
#ask-community
Title
# ask-community
t

Terry Lines

03/24/2023, 7:55 PM
Hi, I'm running dagster locally with sqlite storage. It crashed out and everytime I try to start dagit or dagster-daemon I get the following sqlite3 error. Has anyone else experienced this? Is there an easy way to recover or am I better off deleting the database (it's a testing one so no big deal)? Thanks...
Copy code
File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1901, in _execute_context
    cursor, statement, parameters, context
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 736, in do_execute
    cursor.execute(statement, parameters)
sqlite3.OperationalError: disk I/O error

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/terry/.pyenv/versions/etl_new_env/bin/dagster-daemon", line 8, in <module>
    sys.exit(main())
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_daemon/cli/__init__.py", line 143, in main
    cli(obj={})  # pylint:disable=E1123
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/click/core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/click/core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/click/core.py", line 1657, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/click/core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_daemon/cli/__init__.py", line 55, in run_command
    ) if instance_ref else DagsterInstance.get() as instance:
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 479, in get
    return DagsterInstance.from_config(dagster_home_path)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 495, in from_config
    return DagsterInstance.from_ref(instance_ref)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/instance/__init__.py", line 507, in from_ref
    unified_storage = instance_ref.storage
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/instance/ref.py", line 463, in storage
    return self.storage_data.rehydrate() if self.storage_data else None
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_serdes/config_class.py", line 99, in rehydrate
    return klass.from_config_value(self, check.not_none(result.value))
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/storage/sqlite_storage.py", line 81, in from_config_value
    return DagsterSqliteStorage.from_local(inst_data=inst_data, **config_value)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/storage/sqlite_storage.py", line 87, in from_local
    return cls(base_dir, inst_data=inst_data)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/storage/sqlite_storage.py", line 63, in __init__
    self._run_storage = SqliteRunStorage.from_local(_runs_directory(base_dir))
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/storage/runs/sqlite/sqlite_run_storage.py", line 91, in from_local
    db_revision, head_revision = check_alembic_revision(alembic_config, connection)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/dagster/_core/storage/sql.py", line 77, in check_alembic_revision
    db_revision = migration_context.get_current_revision()
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/alembic/runtime/migration.py", line 487, in get_current_revision
    heads = self.get_current_heads()
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/alembic/runtime/migration.py", line 534, in get_current_heads
    if not self._has_version_table():
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/alembic/runtime/migration.py", line 552, in _has_version_table
    self.connection, self.version_table, self.version_table_schema
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/alembic/util/sqla_compat.py", line 244, in _connectable_has_table
    return inspect(connectable).has_table(tablename, schemaname)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/reflection.py", line 283, in has_table
    return self.dialect.has_table(conn, table_name, schema)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/dialects/sqlite/base.py", line 2020, in has_table
    connection, "table_info", table_name, schema=schema
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/dialects/sqlite/base.py", line 2604, in _get_table_pragma
    cursor = connection.exec_driver_sql(statement)
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1765, in exec_driver_sql
    future=True,
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1676, in _exec_driver_sql
    distilled_parameters,
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1944, in _execute_context
    e, statement, parameters, cursor, context
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 2125, in _handle_dbapi_exception
    sqlalchemy_exception, with_traceback=exc_info[2], from_=e
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/util/compat.py", line 211, in raise_
    raise exception
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1901, in _execute_context
    cursor, statement, parameters, context
  File "/home/terry/.pyenv/versions/3.7.11/envs/etl_new_env/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 736, in do_execute
    cursor.execute(statement, parameters)
sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) disk I/O error
[SQL: PRAGMA main.table_info("alembic_version")]
🤖 2
update. deleting didn't help. it started and then crapped out with the graphql error
Copy code
Operation name: InstanceWarningQuery

Message: (sqlite3.OperationalError) disk I/O error
[SQL: SELECT daemon_heartbeats.body 
FROM daemon_heartbeats]
(Background on this error at: <https://sqlalche.me/e/14/e3q8>)

Path: ["instance","daemonHealth","allDaemonStatuses"]

Locations: [{"line":30,"column":3}]
ok. this was me running out of disk space...