Hello everyone! I'm struggling to resolve this iss...
# troubleshooting
m
Hello everyone! I'm struggling to resolve this issue I have with the tap-postgres (pipelinewise) psycopg2.OperationalError: SSL connection has been closed unexpectedly What is interesting that I don't have it when use the meltanolabs vaiant of tap-postgres. (As I don't really understand what the difference between the variants I thought that's a good idea to stick with the default one) I would really appreciate any help here. Thanks!
Copy code
2023-06-02T14:46:47.808622Z [info     ] Environment 'dev' is active
2023-06-02T14:46:48.270774Z [debug    ] Creating engine '<meltano.core.project.Project object at 0xffff9eac7b20>@sqlite:////artera/.meltano/meltano.db'
2023-06-02T14:46:48.340645Z [debug    ] Found plugin parent            parent=tap-postgres plugin=tap-postgres source=<DefinitionSource.LOCKFILE: 8>
2023-06-02T14:46:48.341869Z [debug    ] found plugin in cli invocation plugin_name=tap-postgres
2023-06-02T14:46:48.344760Z [debug    ] Found plugin parent            parent=target-snowflake plugin=target-snowflake source=<DefinitionSource.LOCKFILE: 8>
2023-06-02T14:46:48.346034Z [debug    ] found plugin in cli invocation plugin_name=target-snowflake
2023-06-02T14:46:48.346136Z [debug    ] head of set is extractor as expected block=<meltano.core.plugin.project_plugin.ProjectPlugin object at 0xffff998cc7f0>
2023-06-02T14:46:48.548669Z [debug    ] found block                    block_type=loaders index=1
2023-06-02T14:46:48.548780Z [debug    ] blocks                         idx=1 offset=0
2023-06-02T14:46:48.773371Z [debug    ] found ExtractLoadBlocks set    offset=0
2023-06-02T14:46:48.773508Z [debug    ] All ExtractLoadBlocks validated, starting execution.
2023-06-02T14:46:49.453206Z [debug    ] Created configuration at /artera/.meltano/run/tap-postgres/tap.8e3da021-d2a2-4793-a408-554ad360e660.config.json
2023-06-02T14:46:49.455290Z [debug    ] Could not find tap.properties.json in /artera/.meltano/extractors/tap-postgres/tap.properties.json, skipping.
2023-06-02T14:46:49.456717Z [debug    ] Could not find tap.properties.cache_key in /artera/.meltano/extractors/tap-postgres/tap.properties.cache_key, skipping.
2023-06-02T14:46:49.458107Z [debug    ] Could not find state.json in /artera/.meltano/extractors/tap-postgres/state.json, skipping.
2023-06-02T14:46:49.470893Z [debug    ] Invoking: ['/artera/.meltano/extractors/tap-postgres/venv/bin/tap-postgres', '--config', '/artera/.meltano/run/tap-postgres/tap.8e3da021-d2a2-4793-a408-554ad360e660.config.json', '--state', '/artera/.meltano/run/tap-postgres/state.json', '--discover']
time=2023-06-02 14:46:49 name=tap_postgres level=CRITICAL message=SSL connection has been closed unexpectedly

Traceback (most recent call last):
  File "/artera/.meltano/extractors/tap-postgres/venv/bin/tap-postgres", line 8, in <module>
    sys.exit(main())
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/tap_postgres/__init__.py", line 451, in main
    raise exc
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/tap_postgres/__init__.py", line 448, in main
    main_impl()
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/tap_postgres/__init__.py", line 433, in main_impl
    do_discovery(conn_config)
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/tap_postgres/__init__.py", line 43, in do_discovery
    with post_db.open_connection(conn_config) as conn:
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/tap_postgres/db.py", line 64, in open_connection
    conn = psycopg2.connect(**cfg)
  File "/artera/.meltano/extractors/tap-postgres/venv/lib/python3.9/site-packages/psycopg2/__init__.py", line 122, in connect
    conn = _connect(dsn, connection_factory=connection_factory, **kwasync)
psycopg2.OperationalError: SSL connection has been closed unexpectedly
v
We are working hard to get the default to be the meltanolabs variant so you'd be safe using the meltanolabs variant if it works for you!
m
@visch Thank you for the reply. I switched back to the meltanolabs variant.