Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Python versions and bump ci deps #1177

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/continuous_integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: ["pypy-3.9", "3.8", "3.9", "3.10", "3.11", "3.12-dev"]
python-version: ["pypy-3.9", "3.8", "3.9", "3.10", "3.11", "3.12", "3.13"]
os: [ubuntu-latest, macos-latest, windows-latest]
exclude:
# pypy3 randomly fails on Windows builds
Expand Down
8 changes: 4 additions & 4 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ default_language_version:
python: python3
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.4.0
rev: v4.5.0
hooks:
- id: check-ast
- id: check-yaml
Expand All @@ -18,11 +18,11 @@ repos:
args: [requirements/requirements.txt, requirements/requirements-docs.txt, requirements/requirements-tests.txt]
- id: trailing-whitespace
- repo: https://github.com/timothycrosley/isort
rev: 5.12.0
rev: 5.13.2
hooks:
- id: isort
- repo: https://github.com/asottile/pyupgrade
rev: v3.13.0
rev: v3.16.0
hooks:
- id: pyupgrade
args: [--py36-plus]
Expand All @@ -48,7 +48,7 @@ repos:
- id: flake8
additional_dependencies: [flake8-bugbear,flake8-annotations]
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.5.1
rev: v1.10.0
hooks:
- id: mypy
additional_dependencies: [types-python-dateutil]
3 changes: 2 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ build39: PYTHON_VER = python3.9
build310: PYTHON_VER = python3.10
build311: PYTHON_VER = python3.11
build312: PYTHON_VER = python3.12
build313: PYTHON_VER = python3.13

build36 build37 build38 build39 build310 build311 build312: clean
build36 build37 build38 build39 build310 build311 build312 build313: clean
$(PYTHON_VER) -m venv venv
. venv/bin/activate; \
pip install -U pip setuptools wheel; \
Expand Down
2 changes: 1 addition & 1 deletion README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ Features
--------

- Fully-implemented, drop-in replacement for datetime
- Support for Python 3.6+
- Support for Python 3.8+
- Timezone-aware and UTC by default
- Super-simple creation options for many common input scenarios
- ``shift`` method with support for relative offsets, including weeks
Expand Down
1 change: 0 additions & 1 deletion arrow/arrow.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@

"""


import calendar
import re
import sys
Expand Down
1 change: 0 additions & 1 deletion arrow/factory.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@

"""


import calendar
from datetime import date, datetime
from datetime import tzinfo as dt_tzinfo
Expand Down
58 changes: 53 additions & 5 deletions arrow/locales.py
Original file line number Diff line number Diff line change
Expand Up @@ -776,7 +776,16 @@ class JapaneseLocale(Locale):
"12",
]

day_names = ["", "月曜日", "火曜日", "水曜日", "木曜日", "金曜日", "土曜日", "日曜日"]
day_names = [
"",
"月曜日",
"火曜日",
"水曜日",
"木曜日",
"金曜日",
"土曜日",
"日曜日",
]
day_abbreviations = ["", "月", "火", "水", "木", "金", "土", "日"]


Expand Down Expand Up @@ -992,7 +1001,16 @@ class ChineseCNLocale(Locale):
"12",
]

day_names = ["", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"]
day_names = [
"",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
"星期日",
]
day_abbreviations = ["", "一", "二", "三", "四", "五", "六", "日"]


Expand Down Expand Up @@ -1111,7 +1129,16 @@ class HongKongLocale(Locale):
"12",
]

day_names = ["", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六", "星期日"]
day_names = [
"",
"星期一",
"星期二",
"星期三",
"星期四",
"星期五",
"星期六",
"星期日",
]
day_abbreviations = ["", "一", "二", "三", "四", "五", "六", "日"]


Expand Down Expand Up @@ -1181,11 +1208,32 @@ class KoreanLocale(Locale):
"12",
]

day_names = ["", "월요일", "화요일", "수요일", "목요일", "금요일", "토요일", "일요일"]
day_names = [
"",
"월요일",
"화요일",
"수요일",
"목요일",
"금요일",
"토요일",
"일요일",
]
day_abbreviations = ["", "월", "화", "수", "목", "금", "토", "일"]

def _ordinal_number(self, n: int) -> str:
ordinals = ["0", "첫", "두", "세", "네", "다섯", "여섯", "일곱", "여덟", "아홉", "열"]
ordinals = [
"0",
"첫",
"두",
"세",
"네",
"다섯",
"여섯",
"일곱",
"여덟",
"아홉",
"열",
]
if n < len(ordinals):
return f"{ordinals[n]}번째"
return f"{n}번째"
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@ classifiers = [
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
"Operating System :: OS Independent",
]
dependencies = [
Expand Down
5 changes: 2 additions & 3 deletions tox.ini
Original file line number Diff line number Diff line change
@@ -1,18 +1,17 @@
[tox]
minversion = 3.18.0
envlist = py{py3,38,39,310,311,312}
envlist = py{py3,38,39,310,311,312,313}
skip_missing_interpreters = true

[gh-actions]
python =
pypy-3.7: pypy3
3.6: py36
3.7: py37
3.8: py38
3.9: py39
3.10: py310
3.11: py311
3.12: py312
3.13: py313

[testenv]
deps = -r requirements/requirements-tests.txt
Expand Down
Loading