amazon-subscriptions 1.1.0__tar.gz → 1.1.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (84) hide show
  1. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.github/workflows/automerge-schedule.yml +5 -5
  2. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.github/workflows/lint.yml +6 -6
  3. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.github/workflows/pr-conventional-title.yml +1 -1
  4. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.github/workflows/publish.yml +5 -2
  5. amazon_subscriptions-1.1.0/.github/workflows/mr-test.yml → amazon_subscriptions-1.1.2/.github/workflows/test.yml +67 -9
  6. amazon_subscriptions-1.1.2/.github/zizmor.yml +9 -0
  7. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.markdownlint-cli2.yaml +3 -0
  8. amazon_subscriptions-1.1.2/.qlty/.gitignore +7 -0
  9. amazon_subscriptions-1.1.2/.qlty/qlty.toml +97 -0
  10. amazon_subscriptions-1.1.2/.release-please-manifest.json +3 -0
  11. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/CHANGELOG.md +16 -5
  12. amazon_subscriptions-1.1.0/README.md → amazon_subscriptions-1.1.2/PKG-INFO +56 -13
  13. amazon_subscriptions-1.1.0/PKG-INFO → amazon_subscriptions-1.1.2/README.md +36 -26
  14. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/cli.py +15 -65
  15. amazon_subscriptions-1.1.2/amazon_subscriptions/client.py +233 -0
  16. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/locales/__init__.py +4 -5
  17. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/locales/en.py +4 -4
  18. amazon_subscriptions-1.1.2/amazon_subscriptions/pages.py +264 -0
  19. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/__init__.py +10 -1
  20. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/deliveries.py +32 -4
  21. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/matching.py +23 -0
  22. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/product.py +3 -38
  23. amazon_subscriptions-1.1.2/amazon_subscriptions/parse/widget.py +68 -0
  24. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/serialize.py +4 -0
  25. amazon_subscriptions-1.1.2/amazon_subscriptions/text.py +60 -0
  26. amazon_subscriptions-1.1.2/assets/banner-dark.webp +0 -0
  27. amazon_subscriptions-1.1.2/assets/banner-light.webp +0 -0
  28. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/codecov.yml +1 -1
  29. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/lychee.toml +5 -0
  30. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/mise.toml +2 -2
  31. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/pyproject.toml +17 -8
  32. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/release-please-config.json +3 -2
  33. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/renovate.json +2 -2
  34. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/scripts/anonymize_fixtures.py +2 -189
  35. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/scripts/extract_product_fixture.py +45 -96
  36. amazon_subscriptions-1.1.2/scripts/fixture_html.py +86 -0
  37. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/scripts/privacy_scan.py +26 -19
  38. amazon_subscriptions-1.1.2/scripts/subscriptions_anonymizer.py +197 -0
  39. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/conftest.py +27 -22
  40. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_cli.py +35 -11
  41. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_client.py +91 -5
  42. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_locale.py +1 -1
  43. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_parse_deliveries.py +31 -1
  44. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_parse_product.py +20 -1
  45. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_serialize.py +4 -0
  46. amazon_subscriptions-1.1.2/tests/test_text.py +38 -0
  47. amazon_subscriptions-1.1.2/uv.lock +972 -0
  48. amazon_subscriptions-1.1.0/.release-please-manifest.json +0 -3
  49. amazon_subscriptions-1.1.0/amazon_subscriptions/client.py +0 -485
  50. amazon_subscriptions-1.1.0/uv.lock +0 -976
  51. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.github/workflows/release-please.yml +0 -0
  52. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.gitignore +0 -0
  53. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/.yamllint.yml +0 -0
  54. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/CONTRIBUTING.md +0 -0
  55. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/LICENSE +0 -0
  56. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/__init__.py +0 -0
  57. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/dates.py +0 -0
  58. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/exceptions.py +0 -0
  59. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/locales/base.py +0 -0
  60. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/models.py +0 -0
  61. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/acp.py +0 -0
  62. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/detail.py +0 -0
  63. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/selectors.py +0 -0
  64. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/subscriptions.py +0 -0
  65. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/amazon_subscriptions/parse/util.py +0 -0
  66. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/scripts/vendor/README.md +0 -0
  67. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/scripts/vendor/anonymize_test_resources.py +0 -0
  68. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/__init__.py +0 -0
  69. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/deliveries-page-2.html +0 -0
  70. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/delivery-1.html +0 -0
  71. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/delivery-2.html +0 -0
  72. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/landing.html +0 -0
  73. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-alternative-offer.html +0 -0
  74. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-no-buybox.html +0 -0
  75. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-rrp.html +0 -0
  76. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-single-offer.html +0 -0
  77. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-unavailable.html +0 -0
  78. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product-was.html +0 -0
  79. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/product.html +0 -0
  80. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/fixtures/de/subscription-detail.html +0 -0
  81. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_dates.py +0 -0
  82. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_matching.py +0 -0
  83. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_parse_detail.py +0 -0
  84. {amazon_subscriptions-1.1.0 → amazon_subscriptions-1.1.2}/tests/test_parse_subscriptions.py +0 -0
@@ -15,11 +15,12 @@ jobs:
15
15
  - name: Enable auto-merge on release-please PR
16
16
  env:
17
17
  GH_TOKEN: ${{ secrets.OVERRIDE_TOKEN }}
18
+ GH_REPO: ${{ github.repository }}
19
+ BASE_BRANCH: ${{ github.event.repository.default_branch }}
18
20
  run: |
19
21
  PRS=$(gh pr list \
20
- --repo "${{ github.repository }}" \
21
22
  --label "autorelease: pending" \
22
- --base "${{ github.event.repository.default_branch }}" \
23
+ --base "$BASE_BRANCH" \
23
24
  --state open \
24
25
  --json number)
25
26
 
@@ -35,9 +36,8 @@ jobs:
35
36
  if [ -n "$PR" ]; then
36
37
  # Auto-merge waits for the branch to be up to date with main, and release-please leaves it
37
38
  # behind when the new commits don't change the release notes.
38
- gh pr update-branch "$PR" --repo "${{ github.repository }}"
39
- gh pr merge "$PR" --auto --squash --delete-branch \
40
- --repo "${{ github.repository }}"
39
+ gh pr update-branch "$PR"
40
+ gh pr merge "$PR" --auto --squash --delete-branch
41
41
  echo "Auto-merge enabled on PR #$PR"
42
42
  else
43
43
  echo "No open release-please PR found"
@@ -2,13 +2,13 @@
2
2
  name: Lint
3
3
 
4
4
  on:
5
- # Called by mr-test.yml, so its required job covers the linters too.
5
+ # Called by test.yml, so its required job covers the linters too.
6
6
  workflow_call:
7
7
 
8
8
  permissions:
9
9
  contents: read
10
10
 
11
- # Python is linted in mr-test.yml. Each linter here is its own job so a failure names the file type. The linters'
11
+ # Python is linted in test.yml. Each linter here is its own job so a failure names the file type. The linters'
12
12
  # versions are in mise.toml, where Renovate updates them.
13
13
  jobs:
14
14
  markdown:
@@ -19,7 +19,7 @@ jobs:
19
19
  persist-credentials: false
20
20
 
21
21
  # Files and rules come from .markdownlint-cli2.yaml, whose globs add to the action's default of the root files.
22
- - uses: DavidAnson/markdownlint-cli2-action@21c1be1b93ad9ed58fa840aacc3f279cde2a72ff # v24.2.0
22
+ - uses: DavidAnson/markdownlint-cli2-action@696eb3f2509270d7b882d2aa68347bc676e7af34 # v25.0.0
23
23
 
24
24
  markdown-links:
25
25
  runs-on: ubuntu-latest
@@ -35,7 +35,7 @@ jobs:
35
35
  key: lychee-${{ github.sha }}
36
36
  restore-keys: lychee-
37
37
 
38
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
38
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
39
39
  with:
40
40
  install_args: lychee
41
41
 
@@ -52,7 +52,7 @@ jobs:
52
52
  with:
53
53
  persist-credentials: false
54
54
 
55
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
55
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
56
56
  with:
57
57
  install_args: python uv pypi:yamllint
58
58
 
@@ -67,7 +67,7 @@ jobs:
67
67
  with:
68
68
  persist-credentials: false
69
69
 
70
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
70
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
71
71
  with:
72
72
  install_args: actionlint shellcheck
73
73
 
@@ -18,6 +18,6 @@ jobs:
18
18
  conventional-pr-title:
19
19
  runs-on: ubuntu-latest
20
20
  steps:
21
- - uses: amannn/action-semantic-pull-request@48f256284bd46cdaab1048c3721360e808335d50 # v6.1.1
21
+ - uses: amannn/action-semantic-pull-request@2252a14e810aa9b85c2d560bd7070c802206ecf6 # v6.1.2
22
22
  env:
23
23
  GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
@@ -30,10 +30,13 @@ jobs:
30
30
  exit 1
31
31
  fi
32
32
 
33
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
33
+ # No cache in the release, a poisoned cache would end up in the published package.
34
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
35
+ with:
36
+ cache: false
34
37
 
35
38
  - name: Build
36
39
  run: uv build
37
40
 
38
41
  # Trusted publishing: PyPI trusts this workflow and the pypi environment, no token needed.
39
- - uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # v1.14.2
42
+ - uses: pypa/gh-action-pypi-publish@7245906fb61fa33a13554f9d5fb856fe61758086 # v1.14.3
@@ -1,5 +1,5 @@
1
1
  ---
2
- name: MR Test
2
+ name: Test
3
3
 
4
4
  on:
5
5
  workflow_dispatch:
@@ -13,12 +13,30 @@ on:
13
13
  permissions:
14
14
  contents: read
15
15
 
16
- concurrency:
17
- group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
18
- cancel-in-progress: true
19
-
20
16
  jobs:
17
+ # Queues the runs of pull requests and main, one at a time. Pull requests that
18
+ # are behind main are rebased, so automerge isn't blocked by the ruleset's
19
+ # up-to-date requirement. Pull requests from forks get no secrets and skip the
20
+ # wait.
21
+ boarding-gate:
22
+ if: github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository
23
+ permissions:
24
+ actions: read
25
+ contents: write # lock refs under refs/boarding-gate/
26
+ pull-requests: read # labels for label-weights
27
+ statuses: write # queue position as commit status
28
+ # Queue order, the concurrency group that cancels outdated waiting runs and
29
+ # the rebase of branches that are behind main: see
30
+ # https://github.com/udondan/boarding-gate#reusable-workflow
31
+ # The rebase needs OVERRIDE_TOKEN: pushes with github.token don't start new runs.
32
+ uses: udondan/boarding-gate/.github/workflows/boarding-gate.yml@v1
33
+ secrets:
34
+ update-token: ${{ secrets.OVERRIDE_TOKEN }}
35
+
21
36
  test:
37
+ needs: boarding-gate
38
+ # The wait is skipped for forks.
39
+ if: ${{ !cancelled() && (needs.boarding-gate.result == 'success' || needs.boarding-gate.result == 'skipped') }}
22
40
  runs-on: ubuntu-latest
23
41
  timeout-minutes: 15
24
42
  permissions:
@@ -37,7 +55,7 @@ jobs:
37
55
  with:
38
56
  persist-credentials: false
39
57
 
40
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
58
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
41
59
 
42
60
  - name: Install dependencies
43
61
  run: mise run install
@@ -63,7 +81,7 @@ jobs:
63
81
  name: Coverage
64
82
  runs-on: ubuntu-latest
65
83
  needs: [test]
66
- if: github.event_name == 'pull_request' && needs.test.result == 'success'
84
+ if: ${{ !cancelled() && github.event_name == 'pull_request' && needs.test.result == 'success' }}
67
85
  timeout-minutes: 10
68
86
  permissions:
69
87
  checks: read
@@ -92,6 +110,8 @@ jobs:
92
110
  echo "::warning::Codecov didn't report within 5 minutes, coverage is not checked."
93
111
 
94
112
  build:
113
+ needs: boarding-gate
114
+ if: ${{ !cancelled() && (needs.boarding-gate.result == 'success' || needs.boarding-gate.result == 'skipped') }}
95
115
  runs-on: ubuntu-latest
96
116
  timeout-minutes: 10
97
117
  steps:
@@ -99,18 +119,56 @@ jobs:
99
119
  with:
100
120
  persist-credentials: false
101
121
 
102
- - uses: jdx/mise-action@c2a87611a18de5b3828c5652fe268e992400cb5c # v4.3.0
122
+ - uses: jdx/mise-action@b44d12e7d0d8ee7461bb893e1b1993500433185b # v5.2.7
103
123
 
104
124
  - name: Build
105
125
  run: uv build
106
126
 
107
127
  lint:
128
+ needs: boarding-gate
129
+ if: ${{ !cancelled() && (needs.boarding-gate.result == 'success' || needs.boarding-gate.result == 'skipped') }}
108
130
  uses: ./.github/workflows/lint.yml
109
131
 
132
+ # The linters and code smells of Qlty Cloud, configured in .qlty/qlty.toml. On pull requests, only smells introduced
133
+ # compared to main fail the job.
134
+ qlty:
135
+ needs: boarding-gate
136
+ if: ${{ !cancelled() && (needs.boarding-gate.result == 'success' || needs.boarding-gate.result == 'skipped') }}
137
+ runs-on: ubuntu-latest
138
+ timeout-minutes: 10
139
+ steps:
140
+ - uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
141
+ with:
142
+ persist-credentials: false
143
+ fetch-depth: 0
144
+
145
+ - name: Install qlty
146
+ uses: qltysh/qlty-action/install@ebcd284bf32e36a030afe15f1e136c7be08b9506 # v2.5.0
147
+
148
+ - name: Lint via qlty plugins
149
+ run: qlty check --all
150
+
151
+ - name: Report code smells
152
+ if: github.event_name != 'pull_request'
153
+ run: qlty smells --all --no-snippets
154
+
155
+ - name: Report new code smells
156
+ if: github.event_name == 'pull_request'
157
+ run: qlty smells --upstream origin/main --no-snippets
158
+
159
+ - name: Fail on new code smells
160
+ if: github.event_name == 'pull_request'
161
+ run: |
162
+ count=$(qlty smells --upstream origin/main --json --quiet 2>/dev/null | jq length)
163
+ if [ "$count" -gt 0 ]; then
164
+ echo "::error::qlty found $count new code smell(s) compared to main"
165
+ exit 1
166
+ fi
167
+
110
168
  # One status check for the ruleset, whatever jobs are added later.
111
169
  required:
112
170
  runs-on: ubuntu-latest
113
- needs: [test, coverage, build, lint]
171
+ needs: [boarding-gate, test, coverage, build, lint, qlty]
114
172
  if: always()
115
173
  steps:
116
174
  - name: Check result
@@ -0,0 +1,9 @@
1
+ ---
2
+ # Actions are pinned to a commit SHA. The reusable workflow of boarding-gate is
3
+ # used by its major tag, so every release reaches this repo without update PRs.
4
+ rules:
5
+ unpinned-uses:
6
+ config:
7
+ policies:
8
+ "udondan/boarding-gate/*": ref-pin
9
+ "*": hash-pin
@@ -2,6 +2,9 @@
2
2
  config:
3
3
  # Prose is written one paragraph per line, and tables and command lines can't be wrapped.
4
4
  MD013: false
5
+ # The README banner switches between light and dark mode with a <picture> element.
6
+ MD033:
7
+ allowed_elements: [picture, source, img]
5
8
 
6
9
  globs:
7
10
  - "**/*.md"
@@ -0,0 +1,7 @@
1
+ *
2
+ !configs
3
+ !configs/**
4
+ !hooks
5
+ !hooks/**
6
+ !qlty.toml
7
+ !.gitignore
@@ -0,0 +1,97 @@
1
+ # Used by Qlty Cloud and by the qlty job of test.yml. The plugins are the ones `qlty init` enables for this
2
+ # repository. All of them and the code smells block, so a finding fails the job.
3
+ #
4
+ # Guide: https://qlty.sh/d/config, reference: https://qlty.sh/d/qlty-toml
5
+ config_version = "0"
6
+
7
+ exclude_patterns = [
8
+ "*_min.*",
9
+ "*-min.*",
10
+ "*.min.*",
11
+ "**/.yarn/**",
12
+ "**/*.d.ts",
13
+ "**/assets/**",
14
+ "**/bower_components/**",
15
+ "**/build/**",
16
+ "**/cache/**",
17
+ "**/config/**",
18
+ "**/db/**",
19
+ "**/deps/**",
20
+ "**/dist/**",
21
+ "**/extern/**",
22
+ "**/external/**",
23
+ "**/generated/**",
24
+ "**/Godeps/**",
25
+ "**/gradlew/**",
26
+ "**/mvnw/**",
27
+ "**/node_modules/**",
28
+ "**/protos/**",
29
+ "**/seed/**",
30
+ "**/target/**",
31
+ "**/templates/**",
32
+ "**/testdata/**",
33
+ "**/vendor/**",
34
+ "**/.claude/**",
35
+ ]
36
+
37
+ test_patterns = [
38
+ "**/test/**",
39
+ "**/spec/**",
40
+ "**/*.test.*",
41
+ "**/*.spec.*",
42
+ "**/*_test.*",
43
+ "**/*_spec.*",
44
+ "**/test_*.*",
45
+ "**/spec_*.*",
46
+ ]
47
+
48
+ [smells]
49
+ mode = "block"
50
+
51
+ # Counts self, and functions with this many parameters are reported. SubscriptionsClient.__init__ takes the session
52
+ # and five options as keyword parameters, which are its public API. Smells cannot be ignored per file.
53
+ [smells.function_parameters]
54
+ threshold = 7
55
+
56
+ [[source]]
57
+ name = "default"
58
+ default = true
59
+
60
+ [[plugin]]
61
+ name = "actionlint"
62
+
63
+ [[plugin]]
64
+ name = "bandit"
65
+
66
+ [[plugin]]
67
+ name = "radarlint-python"
68
+
69
+ [[plugin]]
70
+ name = "ripgrep"
71
+
72
+ [[plugin]]
73
+ name = "ruff"
74
+ drivers = [
75
+ "lint",
76
+ ]
77
+
78
+ [[plugin]]
79
+ name = "trufflehog"
80
+
81
+ [[plugin]]
82
+ name = "yamllint"
83
+
84
+ [[plugin]]
85
+ name = "zizmor"
86
+
87
+ # pytest checks with assert.
88
+ [[triage]]
89
+ match.rules = ["bandit:B101"]
90
+ match.file_patterns = ["tests/**"]
91
+ set.ignored = true
92
+
93
+ # The TODOs of #41 and #42. Remove this once both are resolved.
94
+ [[triage]]
95
+ match.rules = ["ripgrep:TODO", "radarlint-python:python:S1135"]
96
+ match.file_patterns = ["amazon_subscriptions/locales/en.py"]
97
+ set.ignored = true
@@ -0,0 +1,3 @@
1
+ {
2
+ ".": "1.1.2"
3
+ }
@@ -1,5 +1,21 @@
1
1
  # Changelog
2
2
 
3
+ ## [1.1.2](https://github.com/udondan/amazon-subscriptions/compare/v1.1.1...v1.1.2) (2026-11-12)
4
+
5
+
6
+ ### Dependencies
7
+
8
+ * **deps:** update amazon-auth to 1.0 ([#59](https://github.com/udondan/amazon-subscriptions/issues/59)) ([a961290](https://github.com/udondan/amazon-subscriptions/commit/a9612908820d6512ee5e3527aa29a1519a7d7dda))
9
+
10
+ ## [1.1.1](https://github.com/udondan/amazon-subscriptions/compare/v1.1.0...v1.1.1) (2026-11-09)
11
+
12
+
13
+ ### Dependencies
14
+
15
+ * **deps:** replace amazon-orders with amazon-auth ([#52](https://github.com/udondan/amazon-subscriptions/issues/52)) ([6771e25](https://github.com/udondan/amazon-subscriptions/commit/6771e25d5584f4891139ae147f6f2352523dca62))
16
+ * **deps:** update dependency amazon-auth to v0.2.3 ([#57](https://github.com/udondan/amazon-subscriptions/issues/57)) ([8cac493](https://github.com/udondan/amazon-subscriptions/commit/8cac493c598e6b4cb96b9465a5b669b41f34ceb2))
17
+ * **deps:** update dependency click to v8.5.1 ([#53](https://github.com/udondan/amazon-subscriptions/issues/53)) ([3c01915](https://github.com/udondan/amazon-subscriptions/commit/3c01915265aee358258560be61471b4d8cd678e8))
18
+
3
19
  ## [1.1.0](https://github.com/udondan/amazon-subscriptions/compare/v1.0.1...v1.1.0) (2026-11-01)
4
20
 
5
21
 
@@ -44,8 +60,3 @@
44
60
 
45
61
  * read the seller name of alternative offers from the offer row and add seller_id ([#6](https://github.com/udondan/amazon-subscriptions/issues/6)) ([0accfb9](https://github.com/udondan/amazon-subscriptions/commit/0accfb9d4ce017e0a3fe50e47d2d29d709fd1b38))
46
62
  * return a partial result instead of failing when a delivery or product page cannot be read ([#7](https://github.com/udondan/amazon-subscriptions/issues/7)) ([3a3f08f](https://github.com/udondan/amazon-subscriptions/commit/3a3f08f8d797a0472b6add240c3ae454bb5755d2))
47
-
48
-
49
- ### Dependencies
50
-
51
- * **deps:** update dependency ruff to v0.16.9 ([#9](https://github.com/udondan/amazon-subscriptions/issues/9)) ([ff25334](https://github.com/udondan/amazon-subscriptions/commit/ff25334c39d4e21857432ae0b9e83ddbfbcadf92))
@@ -1,8 +1,44 @@
1
+ Metadata-Version: 2.5
2
+ Name: amazon-subscriptions
3
+ Version: 1.1.2
4
+ Summary: Unofficial tool to read Amazon Subscribe & Save subscriptions and upcoming deliveries as JSON (read-only)
5
+ Author: Daniel Schroeder
6
+ License-Expression: MIT
7
+ License-File: LICENSE
8
+ Classifier: Operating System :: OS Independent
9
+ Classifier: Programming Language :: Python :: 3
10
+ Classifier: Programming Language :: Python :: 3.11
11
+ Classifier: Programming Language :: Python :: 3.12
12
+ Classifier: Programming Language :: Python :: 3.13
13
+ Classifier: Programming Language :: Python :: 3.14
14
+ Classifier: Programming Language :: Python :: 3.15
15
+ Requires-Python: >=3.11
16
+ Requires-Dist: amazon-auth<2,>=1.0.0
17
+ Requires-Dist: beautifulsoup4==4.15.0
18
+ Requires-Dist: click==8.5.1
19
+ Description-Content-Type: text/markdown
20
+
1
21
  # amazon-subscriptions
2
22
 
23
+ <picture>
24
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-dark.webp">
25
+ <source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-light.webp">
26
+ <img alt="amazon-subscriptions – Amazon Subscribe &amp; Save CLI" src="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-light.webp">
27
+ </picture>
28
+
29
+ [![PyPI](https://img.shields.io/pypi/v/amazon-subscriptions)](https://pypi.org/project/amazon-subscriptions/)
30
+ [![Python](https://img.shields.io/pypi/pyversions/amazon-subscriptions)](https://pypi.org/project/amazon-subscriptions/)
31
+ [![CI](https://github.com/udondan/amazon-subscriptions/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/udondan/amazon-subscriptions/actions/workflows/test.yml)
32
+ [![codecov](https://codecov.io/gh/udondan/amazon-subscriptions/graph/badge.svg)](https://codecov.io/gh/udondan/amazon-subscriptions)
33
+ [![Maintainability](https://qlty.sh/gh/udondan/projects/amazon-subscriptions/maintainability.svg)](https://qlty.sh/gh/udondan/projects/amazon-subscriptions)
34
+ [![License](https://img.shields.io/github/license/udondan/amazon-subscriptions)](LICENSE)
35
+
36
+ > [!NOTE]
37
+ > Unofficial community project. Not affiliated with, endorsed or authorized by Amazon.
38
+
3
39
  Read Amazon Subscribe & Save subscriptions and upcoming deliveries as JSON. Strictly read-only.
4
40
 
5
- Built on [amazon-orders](https://github.com/alexdlaird/amazon-orders), which handles login and the session, and
41
+ Built on [amazon-auth](https://github.com/alexdlaird/amazon-auth), which handles login and the session, and
6
42
  requests every page in English, whatever language the account is set to. Every Amazon site that offers its pages in
7
43
  English is supported; so far it is tested with amazon.de. See [Other sites](#other-sites).
8
44
 
@@ -33,7 +69,7 @@ Or from a checkout, prefixing the commands below with `uv run`:
33
69
  uv sync
34
70
  ```
35
71
 
36
- The installation includes amazon-orders; its CLI is not needed.
72
+ The installation includes amazon-auth, which handles login and the session.
37
73
 
38
74
  ## Usage
39
75
 
@@ -48,13 +84,13 @@ amazon-subscriptions check-session
48
84
  amazon-subscriptions logout
49
85
  ```
50
86
 
51
- `login`, `logout` and `check-session` are the commands of amazon-orders. Each Amazon site has its own session, stored
52
- in `~/.config/amazonorders/cookies.<site>.json` (e.g. `cookies.amazon.de.json`, for amazon.com `cookies.json`) and
53
- shared with amazon-orders. A session that older versions of amazon-orders stored in `cookies.json` for another site is
54
- still used. Credentials are only asked for by `login` and never stored; the other commands never log in by themselves.
55
- `login` signs out of the site's stored session first, so it always starts a new one. `login --browser` signs in
56
- through a browser window instead, which needs the `browser` extra of amazon-orders. `check-session --verify` asks
57
- Amazon whether it still accepts the session.
87
+ `login`, `logout` and `check-session` are the commands of amazon-auth. Each Amazon site has its own session, stored in
88
+ `~/.config/amazonorders/cookies.<site>.json` (e.g. `cookies.amazon.de.json`, for amazon.com `cookies.json`) and shared
89
+ with amazon-orders. A session that older versions of amazon-orders stored in `cookies.json` for another site is still
90
+ used. Credentials are only asked for by `login` and never stored; the other commands never log in by themselves.
91
+ `login` signs out of the site's stored session first, so it always starts a new one. `login --browser` signs in through
92
+ a browser window instead, which needs the `browser` extra of amazon-auth. `check-session --verify` asks Amazon whether
93
+ it still accepts the session.
58
94
 
59
95
  A `language_package` configured for amazon-orders is ignored, as the pages are only read in English. The configuration
60
96
  file is not changed.
@@ -224,13 +260,13 @@ A list of deliveries:
224
260
  ## Library
225
261
 
226
262
  ```python
227
- from amazonorders.conf import AmazonOrdersConfig
228
- from amazonorders.session import AmazonSession
263
+ from amazonauth.conf import AmazonAuthConfig
264
+ from amazonauth.session import AmazonSession
229
265
 
230
266
  from amazon_subscriptions.client import SubscriptionsClient
231
267
  from amazon_subscriptions.serialize import to_json
232
268
 
233
- session = AmazonSession(config=AmazonOrdersConfig()) # logged in with `amazon-subscriptions login`
269
+ session = AmazonSession(config=AmazonAuthConfig()) # logged in with `amazon-subscriptions login`
234
270
  client = SubscriptionsClient(session) # with_prices=True also loads the product pages
235
271
  print(to_json(client.get_subscriptions()))
236
272
  print(to_json(client.get_upcoming_deliveries()))
@@ -276,7 +312,7 @@ amazon.com.br, amazon.com.mx, amazon.com.tr and amazon.pl, are refused.
276
312
 
277
313
  Only amazon.de has been tested so far. On other sites, the texts, the markup of the pages or the URLs may differ, so
278
314
  some values may be missing (with a warning or an `[incomplete]` result) or a page may not be read at all. Login,
279
- session and cookies are handled by amazon-orders for all sites.
315
+ session and cookies are handled by amazon-auth for all sites.
280
316
 
281
317
  If you use another site, please contribute anonymized pages of it, so it can be tested.
282
318
  [CONTRIBUTING.md](CONTRIBUTING.md) explains step by step how to capture and anonymize them.
@@ -299,3 +335,10 @@ The test fixtures in `tests/fixtures/<tld>/` are anonymized English pages, see [
299
335
  how to capture and anonymize them. The product page fixtures (`product*.html`) are reduced to their title and price
300
336
  blocks with `scripts/extract_product_fixture.py`. It also keeps the variants, the comparison widget and a sponsored
301
337
  product, as prices the parser must not read.
338
+
339
+ ## Disclaimer
340
+
341
+ This is an unofficial, independent open-source project and is not affiliated with Amazon.com, Inc. or its affiliates.
342
+ Amazon and Subscribe & Save are trademarks of Amazon.com, Inc. or its affiliates. The names are used only to describe
343
+ compatibility. This tool reads pages of your own Amazon account automatically, which Amazon's Conditions of Use may
344
+ not permit. Use at your own risk and in accordance with the Conditions of Use of your Amazon site.
@@ -1,21 +1,24 @@
1
- Metadata-Version: 2.5
2
- Name: amazon-subscriptions
3
- Version: 1.1.0
4
- Summary: Read Amazon Subscribe & Save subscriptions and upcoming deliveries as JSON (read-only)
5
- Author: Daniel Schroeder
6
- License-Expression: MIT
7
- License-File: LICENSE
8
- Requires-Python: >=3.11
9
- Requires-Dist: amazon-orders<6,>=5.2.0
10
- Requires-Dist: beautifulsoup4==4.15.0
11
- Requires-Dist: click==8.5.0
12
- Description-Content-Type: text/markdown
13
-
14
1
  # amazon-subscriptions
15
2
 
3
+ <picture>
4
+ <source media="(prefers-color-scheme: dark)" srcset="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-dark.webp">
5
+ <source media="(prefers-color-scheme: light)" srcset="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-light.webp">
6
+ <img alt="amazon-subscriptions – Amazon Subscribe &amp; Save CLI" src="https://raw.githubusercontent.com/udondan/amazon-subscriptions/main/assets/banner-light.webp">
7
+ </picture>
8
+
9
+ [![PyPI](https://img.shields.io/pypi/v/amazon-subscriptions)](https://pypi.org/project/amazon-subscriptions/)
10
+ [![Python](https://img.shields.io/pypi/pyversions/amazon-subscriptions)](https://pypi.org/project/amazon-subscriptions/)
11
+ [![CI](https://github.com/udondan/amazon-subscriptions/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/udondan/amazon-subscriptions/actions/workflows/test.yml)
12
+ [![codecov](https://codecov.io/gh/udondan/amazon-subscriptions/graph/badge.svg)](https://codecov.io/gh/udondan/amazon-subscriptions)
13
+ [![Maintainability](https://qlty.sh/gh/udondan/projects/amazon-subscriptions/maintainability.svg)](https://qlty.sh/gh/udondan/projects/amazon-subscriptions)
14
+ [![License](https://img.shields.io/github/license/udondan/amazon-subscriptions)](LICENSE)
15
+
16
+ > [!NOTE]
17
+ > Unofficial community project. Not affiliated with, endorsed or authorized by Amazon.
18
+
16
19
  Read Amazon Subscribe & Save subscriptions and upcoming deliveries as JSON. Strictly read-only.
17
20
 
18
- Built on [amazon-orders](https://github.com/alexdlaird/amazon-orders), which handles login and the session, and
21
+ Built on [amazon-auth](https://github.com/alexdlaird/amazon-auth), which handles login and the session, and
19
22
  requests every page in English, whatever language the account is set to. Every Amazon site that offers its pages in
20
23
  English is supported; so far it is tested with amazon.de. See [Other sites](#other-sites).
21
24
 
@@ -46,7 +49,7 @@ Or from a checkout, prefixing the commands below with `uv run`:
46
49
  uv sync
47
50
  ```
48
51
 
49
- The installation includes amazon-orders; its CLI is not needed.
52
+ The installation includes amazon-auth, which handles login and the session.
50
53
 
51
54
  ## Usage
52
55
 
@@ -61,13 +64,13 @@ amazon-subscriptions check-session
61
64
  amazon-subscriptions logout
62
65
  ```
63
66
 
64
- `login`, `logout` and `check-session` are the commands of amazon-orders. Each Amazon site has its own session, stored
65
- in `~/.config/amazonorders/cookies.<site>.json` (e.g. `cookies.amazon.de.json`, for amazon.com `cookies.json`) and
66
- shared with amazon-orders. A session that older versions of amazon-orders stored in `cookies.json` for another site is
67
- still used. Credentials are only asked for by `login` and never stored; the other commands never log in by themselves.
68
- `login` signs out of the site's stored session first, so it always starts a new one. `login --browser` signs in
69
- through a browser window instead, which needs the `browser` extra of amazon-orders. `check-session --verify` asks
70
- Amazon whether it still accepts the session.
67
+ `login`, `logout` and `check-session` are the commands of amazon-auth. Each Amazon site has its own session, stored in
68
+ `~/.config/amazonorders/cookies.<site>.json` (e.g. `cookies.amazon.de.json`, for amazon.com `cookies.json`) and shared
69
+ with amazon-orders. A session that older versions of amazon-orders stored in `cookies.json` for another site is still
70
+ used. Credentials are only asked for by `login` and never stored; the other commands never log in by themselves.
71
+ `login` signs out of the site's stored session first, so it always starts a new one. `login --browser` signs in through
72
+ a browser window instead, which needs the `browser` extra of amazon-auth. `check-session --verify` asks Amazon whether
73
+ it still accepts the session.
71
74
 
72
75
  A `language_package` configured for amazon-orders is ignored, as the pages are only read in English. The configuration
73
76
  file is not changed.
@@ -237,13 +240,13 @@ A list of deliveries:
237
240
  ## Library
238
241
 
239
242
  ```python
240
- from amazonorders.conf import AmazonOrdersConfig
241
- from amazonorders.session import AmazonSession
243
+ from amazonauth.conf import AmazonAuthConfig
244
+ from amazonauth.session import AmazonSession
242
245
 
243
246
  from amazon_subscriptions.client import SubscriptionsClient
244
247
  from amazon_subscriptions.serialize import to_json
245
248
 
246
- session = AmazonSession(config=AmazonOrdersConfig()) # logged in with `amazon-subscriptions login`
249
+ session = AmazonSession(config=AmazonAuthConfig()) # logged in with `amazon-subscriptions login`
247
250
  client = SubscriptionsClient(session) # with_prices=True also loads the product pages
248
251
  print(to_json(client.get_subscriptions()))
249
252
  print(to_json(client.get_upcoming_deliveries()))
@@ -289,7 +292,7 @@ amazon.com.br, amazon.com.mx, amazon.com.tr and amazon.pl, are refused.
289
292
 
290
293
  Only amazon.de has been tested so far. On other sites, the texts, the markup of the pages or the URLs may differ, so
291
294
  some values may be missing (with a warning or an `[incomplete]` result) or a page may not be read at all. Login,
292
- session and cookies are handled by amazon-orders for all sites.
295
+ session and cookies are handled by amazon-auth for all sites.
293
296
 
294
297
  If you use another site, please contribute anonymized pages of it, so it can be tested.
295
298
  [CONTRIBUTING.md](CONTRIBUTING.md) explains step by step how to capture and anonymize them.
@@ -312,3 +315,10 @@ The test fixtures in `tests/fixtures/<tld>/` are anonymized English pages, see [
312
315
  how to capture and anonymize them. The product page fixtures (`product*.html`) are reduced to their title and price
313
316
  blocks with `scripts/extract_product_fixture.py`. It also keeps the variants, the comparison widget and a sponsored
314
317
  product, as prices the parser must not read.
318
+
319
+ ## Disclaimer
320
+
321
+ This is an unofficial, independent open-source project and is not affiliated with Amazon.com, Inc. or its affiliates.
322
+ Amazon and Subscribe & Save are trademarks of Amazon.com, Inc. or its affiliates. The names are used only to describe
323
+ compatibility. This tool reads pages of your own Amazon account automatically, which Amazon's Conditions of Use may
324
+ not permit. Use at your own risk and in accordance with the Conditions of Use of your Amazon site.