Error running dlt pipeline to send loaded table query result to s3!
Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1971, in _exec_single_context
    self.dialect.do_execute(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/default.py", line 919, in do_execute
    cursor.execute(statement, parameters)
psycopg2.errors.SyntaxError: syntax error at end of input
LINE 1: select * from 
                      ^


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

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/dlt/extract/pipe_iterator.py", line 275, in _get_source_item
    pipe_item = next(gen)
  File "/app/app/dlt_sources.py", line 15, in query_resource
    query_result = conn.execute(text(query))
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1422, in execute
    return meth(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/sql/elements.py", line 514, in _execute_on_connection
    return connection._execute_clauseelement(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1644, in _execute_clauseelement
    ret = self._execute_context(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1850, in _execute_context
    return self._exec_single_context(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1990, in _exec_single_context
    self._handle_dbapi_exception(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 2357, in _handle_dbapi_exception
    raise sqlalchemy_exception.with_traceback(exc_info[2]) from e
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/base.py", line 1971, in _exec_single_context
    self.dialect.do_execute(
  File "/usr/local/lib/python3.10/site-packages/sqlalchemy/engine/default.py", line 919, in do_execute
    cursor.execute(statement, parameters)
sqlalchemy.exc.ProgrammingError: (psycopg2.errors.SyntaxError) syntax error at end of input
LINE 1: select * from 
                      ^

[SQL: select * from ]
(Background on this error at: https://sqlalche.me/e/20/f405)

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

Traceback (most recent call last):
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 432, in extract
    self._extract_source(extract_step, source, max_parallel_items, workers)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 1106, in _extract_source
    load_id = extract.extract(source, max_parallel_items, workers)
  File "/usr/local/lib/python3.10/site-packages/dlt/extract/extract.py", line 397, in extract
    self._extract_single_source(
  File "/usr/local/lib/python3.10/site-packages/dlt/extract/extract.py", line 326, in _extract_single_source
    for pipe_item in pipes:
  File "/usr/local/lib/python3.10/site-packages/dlt/extract/pipe_iterator.py", line 159, in __next__
    pipe_item = self._get_source_item()
  File "/usr/local/lib/python3.10/site-packages/dlt/extract/pipe_iterator.py", line 306, in _get_source_item
    raise ResourceExtractionError(pipe.name, gen, str(ex), "generator") from ex
dlt.extract.exceptions.ResourceExtractionError: In processing pipe query_resource: extraction of resource query_resource in generator query_resource caused an exception: (psycopg2.errors.SyntaxError) syntax error at end of input
LINE 1: select * from 
                      ^

[SQL: select * from ]
(Background on this error at: https://sqlalche.me/e/20/f405)

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

Traceback (most recent call last):
  File "/app/app/data_pipeline.py", line 704, in run_pipeline
    pipe_info = s3_pipeline.run(
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 223, in _wrap
    step_info = f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 268, in _wrap
    return f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 674, in run
    self.extract(
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 223, in _wrap
    step_info = f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 177, in _wrap
    rv = f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 163, in _wrap
    return f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 268, in _wrap
    return f(self, *args, **kwargs)
  File "/usr/local/lib/python3.10/site-packages/dlt/pipeline/pipeline.py", line 447, in extract
    raise PipelineStepFailed(
dlt.pipeline.exceptions.PipelineStepFailed: Pipeline execution failed at stage extract when processing package 1721319665.2118878 with exception:

<class 'dlt.extract.exceptions.ResourceExtractionError'>
In processing pipe query_resource: extraction of resource query_resource in generator query_resource caused an exception: (psycopg2.errors.SyntaxError) syntax error at end of input
LINE 1: select * from 
                      ^

[SQL: select * from ]
(Background on this error at: https://sqlalche.me/e/20/f405)