snowflakedb / snowflake-sqlalchemy

Snowflake SQLAlchemy
https://pypi.python.org/pypi/snowflake-sqlalchemy/
Apache License 2.0
232 stars 151 forks source link

SNOW-593204: Reflect fails to load all available table definitions from the database. #296

Closed sbalasa closed 1 year ago

sbalasa commented 2 years ago

Please answer these questions before submitting your issue. Thanks!

  1. What version of Python are you using?

    Python 3.10.0 (default, Oct 7 2021, 04:19:18) [Clang 10.0.0 ]

  2. What operating system and processor architecture are you using?

    macOS-10.16-x86_64-i386-64bit

  3. What are the component versions in the environment (pip freeze)?

abstract==2021.11.29.1
aioredis==1.3.1
amqp==5.0.9
appdirs==1.4.3
appnope==0.1.2
asgiref==3.5.1
asn1crypto==1.5.1
asttokens==2.0.5
async-timeout==4.0.2
attrs==19.3.0
autobahn==22.3.2
Automat==20.2.0
backcall==0.2.0
base32hex==1.0.2
billiard==3.6.4.0
black==19.10b0
celery==5.2.2
certifi==2019.11.28
cffi==1.15.0
channels==3.0.4
channels-redis==3.3.1
chardet==3.0.4
charset-normalizer==2.0.12
click==8.0.3
click-didyoumean==0.3.0
click-plugins==1.1.1
click-repl==0.2.0
colouration==2020.7.26
constantly==15.1.0
contextlib2==21.6.0
coverage==5.2.1
croniter==1.0.14
cryptography==36.0.2
daphne==3.0.2
decorator==5.1.1
Deprecated==1.2.13
Django==3.1.14
django-celery-beat==2.2.1
django-cors-headers==3.2.0
django-profiler==2.0.0
django-redis==4.11.0
django-snowflake==3.2a2
django-snowflake-backend==1.0.2
django-timezone-field==4.2.3
djangorestframework==3.11.2
et-xmlfile==1.1.0
executing==0.8.3
futures==2.2.0
fwrite==0.3
graphviz==0.19.2
greenlet==1.1.2
gunicorn==20.0.4
hiredis==2.0.0
hyperlink==21.0.0
idna==2.8
importlib-metadata==1.5.0
incremental==21.3.0
ipython==8.2.0
jedi==0.18.1
jsonrpclib==0.1.7
kombu==5.2.2
lml==0.1.0
markdown2==2.4.2
matplotlib-inline==0.1.3
meta==1.0.2
mock-server==0.3.9
model-bakery==1.0.2
more-itertools==8.2.0
msgpack==1.0.3
natsort==7.1.1
newrelic==5.10.0.138
openpyxl==3.0.9
oscrypto==1.3.0
packaging==20.1
parso==0.8.3
pathspec==0.7.0
pexpect==4.8.0
pickleshare==0.7.5
Pillow==9.0.0
pluggy==0.13.1
prompt-toolkit==3.0.28
psycopg2-binary==2.9.2
ptyprocess==0.7.0
pure-eval==0.2.2
py==1.10.0
py-bcrypt==0.4
py-json-logger==0.0.4
pyasn1==0.4.8
pyasn1-modules==0.2.8
pycparser==2.21
pycryptodomex==3.14.1
pyexcel==0.6.6
pyexcel-io==0.6.6
pyexcel-xls==0.6.2
pyexcel-xlsx==0.6.0
Pygments==2.11.2
PyJWT==2.1.0
pymodm==0.4.3
pymongo==3.10.1
pyOpenSSL==21.0.0
pyparsing==2.4.6
pytest==5.3.5
pytest-django==3.8.0
python-crontab==2.6.0
python-dateutil==2.8.2
python-dotenv==0.10.3
python-json-logger==2.0.2
pytz==2019.3
redis==4.0.2
regex==2020.1.8
requests==2.27.1
schema==0.7.5
selenium==3.141.0
service-identity==21.1.0
six==1.10.0
snowflake==0.0.3
snowflake-connector-python==2.7.6
snowflake-sqlalchemy==1.3.3
sql==2022.4.0
sql-metadata==2.3.0
SQLAlchemy==1.4.32
sqlalchemy-views==0.3.1
sqlparse==0.4.2
stack-data==0.2.0
texttable==1.6.4
toml==0.10.2
tornado==4.3
traitlets==5.1.1
Twisted==22.2.0
txaio==22.2.1
typed-ast==1.5.2
typing_extensions==4.1.1
urllib3==1.26.8
vine==5.0.0
wcwidth==0.1.8
wrapt==1.14.0
xlrd==1.2.0
xlwt==1.3.0
zipp==2.2.0
zope.event==4.5.0
zope.interface==5.4.0
  1. What did you do?
import sqlalchemy
from sqlalchemy.orm import sessionmaker

engine = sqlalchemy.create_engine(SQL_ALCHEMY_DB_URL, echo=True)
session = sessionmaker(bind=engine)()
meta = sqlalchemy.MetaData()
meta.reflect(bind=session.bind)
books = meta.tables["BOOKS"]
  1. What did you expect to see?

    BOOKS table metadata

  2. Can you set logging to DEBUG and collect the logs?

    import logging
    import os
    
    for logger_name in ['snowflake.sqlalchemy', 'snowflake.connector']:
      logger = logging.getLogger(logger_name)
      logger.setLevel(logging.DEBUG)
      ch = logging.StreamHandler()
      ch.setLevel(logging.DEBUG)
      ch.setFormatter(logging.Formatter('%(asctime)s - %(threadName)s %(filename)s:%(lineno)d - %(funcName)s() - %(levelname)s - %(message)s'))
      logger.addHandler(ch)

Traceback:

Connected to pydev debugger (build 211.7628.24)
2022-05-21 00:03:09,698 - MainThread ssl_wrap_socket.py:43 - inject_into_urllib3() - DEBUG - Injecting ssl_wrap_socket_with_ocsp
2022-05-21 00:03:09,703 - MainThread auth.py:90 - <module>() - DEBUG - cache directory: /Users/star/Library/Caches/Snowflake
2022-05-21 00:03:10,131 - MainThread cursor.py:77 - <module>() - DEBUG - Failed to import pyarrow. Cannot use pandas fetch API
2022-05-21 00:03:12,090 - MainThread connection.py:257 - __init__() - INFO - Snowflake Connector for Python Version: 2.7.6, Python Version: 3.10.0, Platform: macOS-10.16-x86_64-i386-64bit
2022-05-21 00:03:12,091 - MainThread connection.py:489 - connect() - DEBUG - connect
2022-05-21 00:03:12,091 - MainThread connection.py:754 - __config() - DEBUG - __config
2022-05-21 00:03:12,092 - MainThread connection.py:878 - __config() - INFO - This connection is in OCSP Fail Open Mode. TLS Certificates would be checked for validity and revocation status. Any other Certificate Revocation related exceptions or OCSP Responder failures would be disregarded in favor of connectivity.
2022-05-21 00:03:12,092 - MainThread connection.py:896 - __config() - INFO - Setting use_openssl_only mode to False
2022-05-21 00:03:12,094 - MainThread converter.py:143 - __init__() - DEBUG - use_numpy: False
2022-05-21 00:03:12,095 - MainThread connection.py:657 - __open_connection() - DEBUG - REST API object was created: cool.east-us-2.azure.snowflakecomputing.com:443
2022-05-21 00:03:12,096 - MainThread auth.py:170 - authenticate() - DEBUG - authenticate
2022-05-21 00:03:12,098 - MainThread auth.py:200 - authenticate() - DEBUG - assertion content: *********
2022-05-21 00:03:12,098 - MainThread auth.py:203 - authenticate() - DEBUG - account=cool, user=random, database=RANDOM, schema=None, warehouse=RANDOM, role=None, request_id=67c00897-5b1d-419b-9a00-e6f39d47ab8d
2022-05-21 00:03:12,098 - MainThread auth.py:236 - authenticate() - DEBUG - body['data']: {'CLIENT_APP_ID': 'PythonConnector', 'CLIENT_APP_VERSION': '2.7.6', 'SVN_REVISION': None, 'ACCOUNT_NAME': 'cool', 'LOGIN_NAME': 'random', 'CLIENT_ENVIRONMENT': {'APPLICATION': 'PythonConnector', 'OS': 'Darwin', 'OS_VERSION': 'macOS-10.16-x86_64-i386-64bit', 'PYTHON_VERSION': '3.10.0', 'PYTHON_RUNTIME': 'CPython', 'PYTHON_COMPILER': 'Clang 10.0.0 ', 'OCSP_MODE': 'FAIL_OPEN', 'TRACING': 10, 'LOGIN_TIMEOUT': 120, 'NETWORK_TIMEOUT': None}, 'SESSION_PARAMETERS': {'AUTOCOMMIT': False, 'CLIENT_PREFETCH_THREADS': 4}}
2022-05-21 00:03:12,098 - MainThread auth.py:254 - authenticate() - DEBUG - Timeout set to 120
2022-05-21 00:03:12,100 - MainThread retry.py:333 - from_int() - DEBUG - Converted retries value: 1 -> Retry(total=1, connect=None, read=None, redirect=None, status=None)
2022-05-21 00:03:12,100 - MainThread retry.py:333 - from_int() - DEBUG - Converted retries value: 1 -> Retry(total=1, connect=None, read=None, redirect=None, status=None)
2022-05-21 00:03:12,100 - MainThread network.py:1120 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 1/1 active sessions
2022-05-21 00:03:12,100 - MainThread network.py:826 - _request_exec_wrapper() - DEBUG - remaining request timeout: 120, retry cnt: 1
2022-05-21 00:03:12,101 - MainThread network.py:807 - add_request_guid() - DEBUG - Request guid: 0fb5db33-f833-4bd7-afec-5361bed38c8e
2022-05-21 00:03:12,101 - MainThread network.py:976 - _request_exec() - DEBUG - socket timeout: 60
2022-05-21 00:03:12,235 - MainThread connectionpool.py:971 - _new_conn() - DEBUG - Starting new HTTPS connection (1): cool.east-us-2.azure.snowflakecomputing.com:443
2022-05-21 00:03:13,257 - MainThread ocsp_snowflake.py:465 - reset_cache_dir() - DEBUG - cache directory: /Users/star/Library/Caches/Snowflake
2022-05-21 00:03:13,650 - MainThread ssl_wrap_socket.py:80 - ssl_wrap_socket_with_ocsp() - DEBUG - OCSP Mode: FAIL_OPEN, OCSP response cache file name: None
2022-05-21 00:03:13,651 - MainThread ocsp_snowflake.py:507 - reset_ocsp_response_cache_uri() - DEBUG - ocsp_response_cache_uri: file:///Users/star/Library/Caches/Snowflake/ocsp_response_cache.json
2022-05-21 00:03:13,651 - MainThread ocsp_snowflake.py:508 - reset_ocsp_response_cache_uri() - DEBUG - OCSP_VALIDATION_CACHE size: 0
2022-05-21 00:03:13,651 - MainThread ocsp_snowflake.py:290 - reset_ocsp_dynamic_cache_server_url() - DEBUG - OCSP response cache server is enabled: http://ocsp.snowflakecomputing.com/ocsp_response_cache.json
2022-05-21 00:03:13,651 - MainThread ocsp_snowflake.py:326 - reset_ocsp_dynamic_cache_server_url() - DEBUG - OCSP dynamic cache server RETRY URL: None
2022-05-21 00:03:13,662 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2025-05-12 23:58:59+00:00
2022-05-21 00:03:13,669 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2024-05-12 02:43:45+00:00
2022-05-21 00:03:13,675 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2024-05-12 02:47:38+00:00
2022-05-21 00:03:13,683 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2022-09-01 07:00:00+00:00
2022-05-21 00:03:13,691 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2025-05-12 23:58:59+00:00
2022-05-21 00:03:13,697 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2025-05-12 23:58:59+00:00
2022-05-21 00:03:13,771 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2022-07-15 00:00:00+00:00
2022-05-21 00:03:13,800 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,807 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,813 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,823 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:13,831 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,838 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:13,846 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,855 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:13,867 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,880 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,894 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,902 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:13,912 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,920 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,927 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:13,934 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:13,950 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,003 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,018 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,028 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,034 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,041 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,049 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,058 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,065 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,073 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 19:35:21+00:00
2022-05-21 00:03:14,083 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,089 - MainThread ocsp_asn1crypto.py:234 - is_valid_time() - DEBUG - Verifying the attached certificate is signed by the issuer. Valid Not After: 2023-01-25 20:00:20+00:00
2022-05-21 00:03:14,091 - MainThread ocsp_snowflake.py:543 - read_ocsp_response_cache_file() - DEBUG - Read OCSP response cache file: /Users/star/Library/Caches/Snowflake/ocsp_response_cache.json, count=188
2022-05-21 00:03:14,092 - MainThread ocsp_snowflake.py:1063 - validate() - DEBUG - validating certificate: cool.east-us-2.azure.snowflakecomputing.com
2022-05-21 00:03:14,092 - MainThread ocsp_asn1crypto.py:435 - extract_certificate_chain() - DEBUG - # of certificates: 2
2022-05-21 00:03:14,095 - MainThread ocsp_asn1crypto.py:440 - extract_certificate_chain() - DEBUG - subject: OrderedDict([('country_name', 'US'), ('state_or_province_name', 'California'), ('locality_name', 'San Mateo'), ('organization_name', 'Snowflake Computing LLC'), ('common_name', '*.east-us-2.azure.snowflakecomputing.com')]), issuer: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('common_name', 'DigiCert TLS RSA SHA256 2020 CA1')])
2022-05-21 00:03:14,098 - MainThread ocsp_asn1crypto.py:440 - extract_certificate_chain() - DEBUG - subject: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('common_name', 'DigiCert TLS RSA SHA256 2020 CA1')]), issuer: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('organizational_unit_name', 'www.digicert.com'), ('common_name', 'DigiCert Global Root CA')])
2022-05-21 00:03:14,103 - MainThread ocsp_asn1crypto.py:123 - read_cert_bundle() - DEBUG - reading certificate bundle: /Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/certifi/cacert.pem
2022-05-21 00:03:14,160 - MainThread ocsp_asn1crypto.py:461 - create_pair_issuer_subject() - DEBUG - not found issuer_der: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('organizational_unit_name', 'www.digicert.com'), ('common_name', 'DigiCert Global Root CA')])
2022-05-21 00:03:14,166 - MainThread ocsp_snowflake.py:683 - find_cache() - DEBUG - hit cache for subject: OrderedDict([('country_name', 'US'), ('state_or_province_name', 'California'), ('locality_name', 'San Mateo'), ('organization_name', 'Snowflake Computing LLC'), ('common_name', '*.east-us-2.azure.snowflakecomputing.com')])
2022-05-21 00:03:14,170 - MainThread ocsp_snowflake.py:683 - find_cache() - DEBUG - hit cache for subject: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('common_name', 'DigiCert TLS RSA SHA256 2020 CA1')])
2022-05-21 00:03:14,174 - MainThread ocsp_snowflake.py:683 - find_cache() - DEBUG - hit cache for subject: OrderedDict([('country_name', 'US'), ('state_or_province_name', 'California'), ('locality_name', 'San Mateo'), ('organization_name', 'Snowflake Computing LLC'), ('common_name', '*.east-us-2.azure.snowflakecomputing.com')])
2022-05-21 00:03:14,180 - MainThread ocsp_snowflake.py:1237 - validate_by_direct_connection() - DEBUG - using OCSP response cache
2022-05-21 00:03:14,181 - MainThread ocsp_asn1crypto.py:329 - process_ocsp_response() - DEBUG - Certificate is NOT attached in Basic OCSP Response. Using issuer's certificate
2022-05-21 00:03:14,181 - MainThread ocsp_asn1crypto.py:337 - process_ocsp_response() - DEBUG - Verifying the OCSP response is signed by the issuer.
2022-05-21 00:03:14,300 - MainThread ocsp_snowflake.py:683 - find_cache() - DEBUG - hit cache for subject: OrderedDict([('country_name', 'US'), ('organization_name', 'DigiCert Inc'), ('common_name', 'DigiCert TLS RSA SHA256 2020 CA1')])
2022-05-21 00:03:14,306 - MainThread ocsp_snowflake.py:1237 - validate_by_direct_connection() - DEBUG - using OCSP response cache
2022-05-21 00:03:14,307 - MainThread ocsp_asn1crypto.py:329 - process_ocsp_response() - DEBUG - Certificate is NOT attached in Basic OCSP Response. Using issuer's certificate
2022-05-21 00:03:14,308 - MainThread ocsp_asn1crypto.py:337 - process_ocsp_response() - DEBUG - Verifying the OCSP response is signed by the issuer.
2022-05-21 00:03:14,318 - MainThread ocsp_snowflake.py:605 - write_ocsp_response_cache_file() - DEBUG - writing OCSP response cache file to /Users/star/Library/Caches/Snowflake/ocsp_response_cache.json
2022-05-21 00:03:14,318 - MainThread ocsp_snowflake.py:1715 - encode_ocsp_response_cache() - DEBUG - encoding OCSP response cache to JSON
2022-05-21 00:03:14,490 - MainThread ocsp_snowflake.py:1115 - _validate() - DEBUG - ok
2022-05-21 00:03:15,061 - MainThread connectionpool.py:452 - _make_request() - DEBUG - https://cool.east-us-2.azure.snowflakecomputing.com:443 "POST /session/v1/login-request?request_id=67c00897-5b1d-419b-9a00-e6f39d47ab8d&databaseName=RANDOM&warehouse=RANDOM&request_guid=0fb5db33-f833-4bd7-afec-5361bed38c8e HTTP/1.1" 200 None
2022-05-21 00:03:15,066 - MainThread network.py:1005 - _request_exec() - DEBUG - SUCCESS
2022-05-21 00:03:15,066 - MainThread network.py:1125 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 0/1 active sessions
2022-05-21 00:03:15,067 - MainThread network.py:714 - _post_request() - DEBUG - ret[code] = None, after post request
2022-05-21 00:03:15,067 - MainThread auth.py:373 - authenticate() - DEBUG - completed authentication
2022-05-21 00:03:15,068 - MainThread auth.py:416 - authenticate() - DEBUG - token = ******
2022-05-21 00:03:15,068 - MainThread auth.py:419 - authenticate() - DEBUG - master_token = ******
2022-05-21 00:03:15,068 - MainThread auth.py:423 - authenticate() - DEBUG - id_token = NULL
2022-05-21 00:03:15,068 - MainThread auth.py:427 - authenticate() - DEBUG - mfa_token = NULL
2022-05-21 00:03:15,070 - MainThread connection.py:576 - cursor() - DEBUG - cursor
2022-05-21 00:03:15,070 - MainThread cursor.py:616 - execute() - DEBUG - executing SQL/command
2022-05-21 00:03:15,070 - MainThread cursor.py:654 - execute() - DEBUG - binding: [ROLLBACK] with input=[None], processed=[{}]
2022-05-21 00:03:15,070 - MainThread cursor.py:700 - execute() - INFO - query: [ROLLBACK]
2022-05-21 00:03:15,071 - MainThread connection.py:1252 - _next_sequence_counter() - DEBUG - sequence counter: 1
2022-05-21 00:03:15,071 - MainThread cursor.py:447 - _execute_helper() - DEBUG - Request id: bc5d8f8b-3849-4d6b-a0ab-053b79754ed3
2022-05-21 00:03:15,071 - MainThread cursor.py:450 - _execute_helper() - DEBUG - running query [ROLLBACK]
2022-05-21 00:03:15,071 - MainThread cursor.py:459 - _execute_helper() - DEBUG - is_file_transfer: False
2022-05-21 00:03:15,072 - MainThread connection.py:923 - cmd_query() - DEBUG - _cmd_query
2022-05-21 00:03:15,072 - MainThread connection.py:946 - cmd_query() - DEBUG - sql=[ROLLBACK], sequence_id=[1], is_file_transfer=[False]
2022-05-21 00:03:15,073 - MainThread network.py:1120 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 1/1 active sessions
2022-05-21 00:03:15,073 - MainThread network.py:826 - _request_exec_wrapper() - DEBUG - remaining request timeout: None, retry cnt: 1
2022-05-21 00:03:15,073 - MainThread network.py:807 - add_request_guid() - DEBUG - Request guid: 09b7bf4b-451f-41e3-bee2-062aea64ac2c
2022-05-21 00:03:15,074 - MainThread network.py:976 - _request_exec() - DEBUG - socket timeout: 60
2022-05-21 00:03:15,408 - MainThread connectionpool.py:452 - _make_request() - DEBUG - https://cool.east-us-2.azure.snowflakecomputing.com:443 "POST /queries/v1/query-request?requestId=bc5d8f8b-3849-4d6b-a0ab-053b79754ed3&request_guid=09b7bf4b-451f-41e3-bee2-062aea64ac2c HTTP/1.1" 200 None
2022-05-21 00:03:15,411 - MainThread network.py:1005 - _request_exec() - DEBUG - SUCCESS
2022-05-21 00:03:15,412 - MainThread network.py:1125 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 0/1 active sessions
2022-05-21 00:03:15,412 - MainThread network.py:714 - _post_request() - DEBUG - ret[code] = None, after post request
2022-05-21 00:03:15,412 - MainThread network.py:738 - _post_request() - DEBUG - Query id: 01a465d9-0b03-1676-0001-25660acd83ba
2022-05-21 00:03:15,413 - MainThread cursor.py:722 - execute() - DEBUG - sfqid: 01a465d9-0b03-1676-0001-25660acd83ba
2022-05-21 00:03:15,414 - MainThread cursor.py:724 - execute() - INFO - query execution done
2022-05-21 00:03:15,414 - MainThread cursor.py:726 - execute() - DEBUG - SUCCESS
2022-05-21 00:03:15,414 - MainThread cursor.py:729 - execute() - DEBUG - PUT OR GET: None
2022-05-21 00:03:15,414 - MainThread cursor.py:826 - _init_result_and_meta() - DEBUG - Query result format: json
2022-05-21 00:03:15,415 - MainThread result_batch.py:446 - _parse() - DEBUG - parsing for result batch id: 1
2022-05-21 00:03:15,417 - MainThread connection.py:576 - cursor() - DEBUG - cursor
2022-05-21 00:03:15,417 - MainThread cursor.py:616 - execute() - DEBUG - executing SQL/command
2022-05-21 00:03:15,418 - MainThread cursor.py:654 - execute() - DEBUG - binding: [ROLLBACK] with input=[None], processed=[{}]
2022-05-21 00:03:15,418 - MainThread cursor.py:700 - execute() - INFO - query: [ROLLBACK]
2022-05-21 00:03:15,418 - MainThread connection.py:1252 - _next_sequence_counter() - DEBUG - sequence counter: 2
2022-05-21 00:03:15,419 - MainThread cursor.py:447 - _execute_helper() - DEBUG - Request id: e17b1f0d-de42-4c2b-9a7e-330b181feb09
2022-05-21 00:03:15,419 - MainThread cursor.py:450 - _execute_helper() - DEBUG - running query [ROLLBACK]
2022-05-21 00:03:15,419 - MainThread cursor.py:459 - _execute_helper() - DEBUG - is_file_transfer: False
2022-05-21 00:03:15,420 - MainThread connection.py:923 - cmd_query() - DEBUG - _cmd_query
2022-05-21 00:03:15,420 - MainThread connection.py:946 - cmd_query() - DEBUG - sql=[ROLLBACK], sequence_id=[2], is_file_transfer=[False]
2022-05-21 00:03:15,421 - MainThread network.py:1120 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 1/1 active sessions
2022-05-21 00:03:15,421 - MainThread network.py:826 - _request_exec_wrapper() - DEBUG - remaining request timeout: None, retry cnt: 1
2022-05-21 00:03:15,421 - MainThread network.py:807 - add_request_guid() - DEBUG - Request guid: b3bfa734-6d38-4d4d-baaf-dad25c078117
2022-05-21 00:03:15,422 - MainThread network.py:976 - _request_exec() - DEBUG - socket timeout: 60
2022-05-21 00:03:15,746 - MainThread connectionpool.py:452 - _make_request() - DEBUG - https://cool.east-us-2.azure.snowflakecomputing.com:443 "POST /queries/v1/query-request?requestId=e17b1f0d-de42-4c2b-9a7e-330b181feb09&request_guid=b3bfa734-6d38-4d4d-baaf-dad25c078117 HTTP/1.1" 200 None
2022-05-21 00:03:15,748 - MainThread network.py:1005 - _request_exec() - DEBUG - SUCCESS
2022-05-21 00:03:15,748 - MainThread network.py:1125 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 0/1 active sessions
2022-05-21 00:03:15,748 - MainThread network.py:714 - _post_request() - DEBUG - ret[code] = None, after post request
2022-05-21 00:03:15,748 - MainThread network.py:738 - _post_request() - DEBUG - Query id: 01a465d9-0b03-1472-0001-25660acd59b6
2022-05-21 00:03:15,749 - MainThread cursor.py:722 - execute() - DEBUG - sfqid: 01a465d9-0b03-1472-0001-25660acd59b6
2022-05-21 00:03:15,749 - MainThread cursor.py:724 - execute() - INFO - query execution done
2022-05-21 00:03:15,749 - MainThread cursor.py:726 - execute() - DEBUG - SUCCESS
2022-05-21 00:03:15,749 - MainThread cursor.py:729 - execute() - DEBUG - PUT OR GET: None
2022-05-21 00:03:15,750 - MainThread cursor.py:826 - _init_result_and_meta() - DEBUG - Query result format: json
2022-05-21 00:03:15,750 - MainThread result_batch.py:446 - _parse() - DEBUG - parsing for result batch id: 1
/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/snowflake/sqlalchemy/snowdialect.py:515: SAWarning: Dialect snowflake:snowflake will not make use of SQL compilation caching as it does not set the 'supports_statement_cache' attribute to ``True``.  This can have significant performance implications including some performance degradations in comparison to prior SQLAlchemy versions.  Dialect maintainers should seek to set this attribute to True after appropriate development and testing for SQLAlchemy 1.4 caching support.   Alternatively, this attribute may be set to False which will disable this warning. (Background on this error at: https://sqlalche.me/e/14/cprf)
  cursor = connection.execute(text(
2022-05-21 00:03:15,753 - MainThread connection.py:576 - cursor() - DEBUG - cursor
2022-05-21 00:03:15,754 - MainThread cursor.py:616 - execute() - DEBUG - executing SQL/command
2022-05-21 00:03:15,754 - MainThread connection.py:1206 - _process_params_dict() - DEBUG - parameters: {}
2022-05-21 00:03:15,755 - MainThread cursor.py:654 - execute() - DEBUG - binding: [SHOW /* sqlalchemy:get_table_names */ TABLES] with input=[{}], processed=[{}]
2022-05-21 00:03:15,755 - MainThread cursor.py:700 - execute() - INFO - query: [SHOW /* sqlalchemy:get_table_names */ TABLES]
2022-05-21 00:03:15,755 - MainThread connection.py:1252 - _next_sequence_counter() - DEBUG - sequence counter: 3
2022-05-21 00:03:15,755 - MainThread cursor.py:447 - _execute_helper() - DEBUG - Request id: fe5bbb1a-859f-4603-8af9-7d8e48423d66
2022-05-21 00:03:15,756 - MainThread cursor.py:450 - _execute_helper() - DEBUG - running query [SHOW /* sqlalchemy:get_table_names */ TABLES]
2022-05-21 00:03:15,756 - MainThread cursor.py:459 - _execute_helper() - DEBUG - is_file_transfer: False
2022-05-21 00:03:15,756 - MainThread connection.py:923 - cmd_query() - DEBUG - _cmd_query
2022-05-21 00:03:15,756 - MainThread connection.py:946 - cmd_query() - DEBUG - sql=[SHOW /* sqlalchemy:get_table_names */ TABLES], sequence_id=[3], is_file_transfer=[False]
2022-05-21 00:03:15,757 - MainThread network.py:1120 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 1/1 active sessions
2022-05-21 00:03:15,757 - MainThread network.py:826 - _request_exec_wrapper() - DEBUG - remaining request timeout: None, retry cnt: 1
2022-05-21 00:03:15,757 - MainThread network.py:807 - add_request_guid() - DEBUG - Request guid: 3cd40ac1-179d-4a21-a404-d237210f2a92
2022-05-21 00:03:15,757 - MainThread network.py:976 - _request_exec() - DEBUG - socket timeout: 60
2022-05-21 00:03:15,754 INFO sqlalchemy.engine.Engine SHOW /* sqlalchemy:get_table_names */ TABLES
2022-05-21 00:03:15,754 INFO sqlalchemy.engine.Engine [dialect snowflake+snowflake does not support caching 0.00098s] {}
2022-05-21 00:03:16,559 - MainThread connectionpool.py:452 - _make_request() - DEBUG - https://cool.east-us-2.azure.snowflakecomputing.com:443 "POST /queries/v1/query-request?requestId=fe5bbb1a-859f-4603-8af9-7d8e48423d66&request_guid=3cd40ac1-179d-4a21-a404-d237210f2a92 HTTP/1.1" 200 None
2022-05-21 00:03:16,564 - MainThread network.py:1005 - _request_exec() - DEBUG - SUCCESS
2022-05-21 00:03:16,565 - MainThread network.py:1125 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 0/1 active sessions
2022-05-21 00:03:16,565 - MainThread network.py:714 - _post_request() - DEBUG - ret[code] = None, after post request
2022-05-21 00:03:16,566 - MainThread network.py:738 - _post_request() - DEBUG - Query id: 01a465d9-0b03-13f6-0001-25660acd66d6
2022-05-21 00:03:16,566 - MainThread cursor.py:722 - execute() - DEBUG - sfqid: 01a465d9-0b03-13f6-0001-25660acd66d6
2022-05-21 00:03:16,566 - MainThread cursor.py:724 - execute() - INFO - query execution done
2022-05-21 00:03:16,566 - MainThread cursor.py:726 - execute() - DEBUG - SUCCESS
2022-05-21 00:03:16,566 - MainThread cursor.py:729 - execute() - DEBUG - PUT OR GET: None
2022-05-21 00:03:16,567 - MainThread cursor.py:826 - _init_result_and_meta() - DEBUG - Query result format: json
2022-05-21 00:03:16,624 - MainThread result_batch.py:446 - _parse() - DEBUG - parsing for result batch id: 418
2022-05-21 00:03:16,633 - MainThread result_set.py:58 - result_set_iterator() - DEBUG - beginning to schedule result batch downloads
2022-05-21 00:03:16,646 - MainThread connection.py:576 - cursor() - DEBUG - cursor
2022-05-21 00:03:16,647 - MainThread cursor.py:616 - execute() - DEBUG - executing SQL/command
2022-05-21 00:03:16,647 - MainThread cursor.py:654 - execute() - DEBUG - binding: [ROLLBACK] with input=[None], processed=[{}]
2022-05-21 00:03:16,647 - MainThread cursor.py:700 - execute() - INFO - query: [ROLLBACK]
2022-05-21 00:03:16,647 - MainThread connection.py:1252 - _next_sequence_counter() - DEBUG - sequence counter: 4
2022-05-21 00:03:16,647 - MainThread cursor.py:447 - _execute_helper() - DEBUG - Request id: b9c694ed-2787-40de-86d2-e7c3f4cc278d
2022-05-21 00:03:16,648 - MainThread cursor.py:450 - _execute_helper() - DEBUG - running query [ROLLBACK]
2022-05-21 00:03:16,648 - MainThread cursor.py:459 - _execute_helper() - DEBUG - is_file_transfer: False
2022-05-21 00:03:16,648 - MainThread connection.py:923 - cmd_query() - DEBUG - _cmd_query
2022-05-21 00:03:16,648 - MainThread connection.py:946 - cmd_query() - DEBUG - sql=[ROLLBACK], sequence_id=[4], is_file_transfer=[False]
2022-05-21 00:03:16,648 - MainThread network.py:1120 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 1/1 active sessions
2022-05-21 00:03:16,649 - MainThread network.py:826 - _request_exec_wrapper() - DEBUG - remaining request timeout: None, retry cnt: 1
2022-05-21 00:03:16,649 - MainThread network.py:807 - add_request_guid() - DEBUG - Request guid: a4098222-17ad-4ee4-b17e-9350ba197757
2022-05-21 00:03:16,649 - MainThread network.py:976 - _request_exec() - DEBUG - socket timeout: 60
2022-05-21 00:03:16,978 - MainThread connectionpool.py:452 - _make_request() - DEBUG - https://cool.east-us-2.azure.snowflakecomputing.com:443 "POST /queries/v1/query-request?requestId=b9c694ed-2787-40de-86d2-e7c3f4cc278d&request_guid=a4098222-17ad-4ee4-b17e-9350ba197757 HTTP/1.1" 200 None
2022-05-21 00:03:16,982 - MainThread network.py:1005 - _request_exec() - DEBUG - SUCCESS
2022-05-21 00:03:16,983 - MainThread network.py:1125 - _use_requests_session() - DEBUG - Session status for SessionPool 'cool.east-us-2.azure.snowflakecomputing.com', SessionPool 0/1 active sessions
2022-05-21 00:03:16,984 - MainThread network.py:714 - _post_request() - DEBUG - ret[code] = None, after post request
2022-05-21 00:03:16,984 - MainThread network.py:738 - _post_request() - DEBUG - Query id: 01a465d9-0b03-1676-0001-25660acd83c6
2022-05-21 00:03:16,985 - MainThread cursor.py:722 - execute() - DEBUG - sfqid: 01a465d9-0b03-1676-0001-25660acd83c6
2022-05-21 00:03:16,985 - MainThread cursor.py:724 - execute() - INFO - query execution done
2022-05-21 00:03:16,986 - MainThread cursor.py:726 - execute() - DEBUG - SUCCESS
2022-05-21 00:03:16,986 - MainThread cursor.py:729 - execute() - DEBUG - PUT OR GET: None
2022-05-21 00:03:16,986 - MainThread cursor.py:826 - _init_result_and_meta() - DEBUG - Query result format: json
2022-05-21 00:03:16,987 - MainThread result_batch.py:446 - _parse() - DEBUG - parsing for result batch id: 1
Traceback (most recent call last):
  File "/Users/star/opt/anaconda3/envs/py310/lib/python3.10/contextlib.py", line 153, in __exit__
    self.gen.throw(typ, value, traceback)
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/sqlalchemy/engine/reflection.py", line 219, in _inspection_context
    yield sub_insp
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/sqlalchemy/sql/schema.py", line 4793, in reflect
    available = util.OrderedSet(insp.get_table_names(schema))
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/sqlalchemy/engine/reflection.py", line 266, in get_table_names
    return self.dialect.get_table_names(
  File "<string>", line 2, in get_table_names
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/sqlalchemy/engine/reflection.py", line 55, in cache
    ret = fn(self, con, *args, **kw)
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/snowflake/sqlalchemy/snowdialect.py", line 519, in get_table_names
    ret = [self.normalize_name(row[1]) for row in cursor]
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/snowflake/sqlalchemy/snowdialect.py", line 519, in <listcomp>
    ret = [self.normalize_name(row[1]) for row in cursor]
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/snowflake/sqlalchemy/snowdialect.py", line 221, in normalize_name
    self.identifier_preparer._requires_quotes(name.lower()):
  File "/Users/star/PycharmProjects/my_project/my-service/venv/lib/python3.10/site-packages/sqlalchemy/sql/compiler.py", line 5167, in _requires_quotes
    or value[0] in self.illegal_initial_characters
IndexError: string index out of range
python-BaseException
github-actions[bot] commented 1 year ago

To clean up and re-prioritize bugs and feature requests we are closing all issues older than 6 months as of Apr 1, 2023. If there are any issues or feature requests that you would like us to address, please re-create them. For urgent issues, opening a support case with this link Snowflake Community is the fastest way to get a response