Skip to main content

A simple hello world package for demonstration

Project description

hello251114

A simple hello world package for PyPI demonstration.

Installation

pip install hello251114

Usage

hello251114

Or in Python:

from hello251114 import greet

print(greet())

License

MIT

class PostgresHelper:

def __init__(self):
    self.db_connection_string = f"postgresql://{config.POSTGRES_USER}:{config.POSTGRES_PWD}@{config.POSTGRES_HOST}:{config.POSTGRES_POST}/{config.POSTGRES_DB}"
    self.engine: Optional[Engine] = None
    self.session_factory: Optional[sessionmaker] = None

def initialize(self):
    """初始化数据库连接"""
    try:
        self.engine = create_engine(
            self.db_connection_string,
            echo=True  # 设置为True可以查看生成的SQL
        )
        self.session_factory = sessionmaker(bind=self.engine)
        logger.info("数据库连接初始化完成")
    except Exception as e:
        logger.error(f"数据库连接失败: {e}")
        raise

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hello251114-0.1.1.tar.gz (24.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hello251114-0.1.1-py3-none-any.whl (3.3 kB view details)

Uploaded Python 3

File details

Details for the file hello251114-0.1.1.tar.gz.

File metadata

  • Download URL: hello251114-0.1.1.tar.gz
  • Upload date:
  • Size: 24.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.6

File hashes

Hashes for hello251114-0.1.1.tar.gz
Algorithm Hash digest
SHA256 d4f1f876368d189572aba2940365bc91ae57ad02ca583db29e98c7f9014ccb59
MD5 6dbe9a62d3e1f806e5e3afb788fb0913
BLAKE2b-256 7dd1da4c4304952bbf3fedb4870d8d13f86b163eab73360633efc8c7ae896cf2

See more details on using hashes here.

File details

Details for the file hello251114-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for hello251114-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 3ce7f45e15bdf04e0f85a3cc6b2868af4427074c3cd836abc977fe92671e0901
MD5 9755779bad31c0a4b2fd44d8d49cf6eb
BLAKE2b-256 f1e1a8a80622bbb4cea0869308003bd2d95a04109603dab5f6e354b81d751740

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page