Compare commits

..
Author SHA1 Message Date
Raphael Michel 936b7af702 Stripe: Add an idempotency key for refund requests 2026-11-18 16:32:41 +01:00
4 changed files with 7 additions and 6 deletions

No files matched your search

+1 -1
View File
@@ -123,7 +123,7 @@ jobs:
working-directory: ./src
run: make all compress
- name: Install Playwright browsers
run: playwright install chromium --with-deps
run: playwright install --with-deps
- name: Run E2E tests
working-directory: ./src
run: PRETIX_CONFIG_FILE=tests/ci_postgres.cfg py.test tests/e2e/ -v --maxfail=10 --tracing=retain-on-failure
+3 -4
View File
@@ -34,7 +34,7 @@ dependencies = [
"celery==5.6.*",
"chardet==5.2.*",
"cryptography>=50.0.2",
"css-inline==0.24.*",
"css-inline==0.23.*",
"defusedcsv>=3.0.0",
"dnspython==2.9.*",
"Django[argon2]==5.2.*,>=5.2.17",
@@ -62,7 +62,7 @@ dependencies = [
"geoip2==5.*",
"isoweek",
"jsonschema",
"kombu==5.7.*",
"kombu==5.6.*",
"libsass==0.23.*",
"lxml",
"markdown==3.11.2",
@@ -123,8 +123,7 @@ dev = [
"pytest-sugar",
"pytest-xdist==3.8.*",
"pytest-playwright",
"pytest-base-url",
"pytest==9.2.*",
"pytest==9.1.*",
"playwright",
"responses",
"pypdfium2"
+2
View File
@@ -773,6 +773,8 @@ class StripeMethod(BasePaymentProvider):
r = stripe.Refund.create(
charge=chargeid,
amount=self._get_amount(refund),
# Refunds should only be started once, a retry is a new refund
idempotency_key=chargeid + refund.full_id,
**self.api_kwargs,
**kwargs,
)
+1 -1
View File
@@ -267,7 +267,7 @@ class CustomerStep(CartMixin, TemplateFlowStep):
else None
),
prefix='login',
request=self.request,
request=self.request.event,
)
for field in f.fields.values():
field._show_required = field.required