snowflakedb / snowflakedb/snowflake-connector-python

SNOW-2043406: Type Annotations for `snowflake.connector.connect`

Open
#2,270 3 comments 0 reactions 1 assignee View on GitHub

@sfc-gh-dszmolka is already working on this.

Since Apr 16, 2025.

enhancement status-pr_pending_merge status-triage_done
Dominant language
Python
Stars
730
Forks
574
Avg merge
5h 45m
Merged PRs (30d)
16

Description

What is the current behavior?

snowflake.connect lacks any type annotations, despite usage of **kwargs it's possible to share annotations between SnowflakeConnection and snowflake.connect through usage of Unpack.

What is the desired behavior?

That snowflake.connect is properly annotated making type-checkers such as MyPy and Pyright raise type-checking warnings when incorrect arguments are parsed in.

How would this improve snowflake-connector-python?

Users relying on type-checkers or Pylance would get linting errors for invalid arguments without having to execute code. Additionally, by having py.typed the package indicates it's properly typed however in this case proper annotations are missing.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.