getKST
A Python package that returns datetime values for the Asia/Seoul region.
Installation
Prerequisites
- Python (>=3.9)
Install via pip
pip install getKST
Install via uv
uv add getKST
Usage
Note: Default format of getKST is %Y-%m-%d %H:%M:%S as a string.
getKST() always converts to Asia/Seoul time internally before formatting, so the result is identical no matter what timezone the host machine or server is set to (UTC, EST, JST, etc.).
-
Basic Usage
from getKST import getKST now = getKST() print(now)
-
Using other formats
from getKST import getKST now = getKST("%Y/%m/%d") # Year/Month/Date now = getKST("%H-%M-%S") # Hour-Minute-Second
-
Converting an existing datetime
from datetime import datetime, timezone from getKST import getKST utc_now = datetime.now(tz=timezone.utc) print(getKST(dt=utc_now))
All Python datetime formats are supported.
Change Log
v1.1.0
- Added
KSTStringclass that extendsstr, allowing the result ofgetKST()to be used as both a formatted string and adatetimeobject - Added
KSTString.toDatetime()method to retrieve the underlying KSTdatetimeobject - Changed return type of
getKST()fromstrtoKSTString
v1.0.2
- Added
tzdataas a requirement on Windows - Added
Change Logsection at README.md
v1.0.1
- Updated README.md
v1.0.0
- Published a package
License
Metadata
Release files for getKST 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| getkst-1.1.0.tar.gz | 2.7 kB | Without provenance | Details for getkst-1.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| getkst-1.1.0-py3-none-any.whl | Python 3 | none | any | Details for getkst-1.1.0-py3-none-any.whl |
Total release size: 6.7 kB
Release files / getkst-1.1.0.tar.gz
| Download URL | getkst-1.1.0.tar.gz |
|---|---|
| Size | 2.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f2269985effbf22f27334ed71c03042f7b0a975634911ad5a225245a9eea5e35
|
|
BLAKE2b-256 checksum How to use checksums |
23df03cf8bfa97b4c6e026daa7a770b4bc9788cf4a0ec7567c3bd781ea4f88a2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Release files / getkst-1.1.0-py3-none-any.whl
| Download URL | getkst-1.1.0-py3-none-any.whl |
|---|---|
| Size | 4.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
a06332b1ff9ce85b380861e8eeca20708d47a91aa6d59b92ce0d2e09f07c6e8e
|
|
BLAKE2b-256 checksum How to use checksums |
9216406c3862c78ef1a1bfe7aa639df57a9ddbed2c40b8fb4419a922dd930bda
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.12.2 {"installer":{"name":"uv","version":"0.12.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}
|
Security for getKST 1.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.