Skip to content

Commit 61f65d5

Browse files
Merge branch 'main' into custom-benefit
2 parents 8fc4aa9 + a99adcb commit 61f65d5

File tree

720 files changed

+67360
-56195
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

720 files changed

+67360
-56195
lines changed

.devcontainer/devcontainer.json

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,10 +59,6 @@
5959
"5432": {
6060
"label": "db"
6161
},
62-
"6006": {
63-
"label": "storybook",
64-
"onAutoForward": "ignore"
65-
},
6662
"6379": {
6763
"label": "redis"
6864
},

.github/ISSUE_TEMPLATE/config.yml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1 @@
11
blank_issues_enabled: true
2-
contact_links:
3-
- name: 💡 Feature Request
4-
url: https://github.com/orgs/polarsource/discussions/new?category=feature-requests
5-
about: Please submit feature requests here.
6-
- name: 🛟 Support
7-
url: https://discord.com/invite/Pnhfz3UThd
8-
about: Join us on Discord to ask support questions.

.github/pull_request_template.md

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
<!--
2+
Thank you for contributing to Polar! 🎉
3+
4+
Before submitting your PR, please ensure:
5+
- An issue exists and you're assigned to it (unless it's a minor fix)
6+
- You've tested your changes locally
7+
- All tests pass
8+
- Code follows our style guidelines
9+
10+
For minor fixes (typos, broken links, formatting), you may skip the issue requirement.
11+
-->
12+
13+
## 📋 Summary
14+
15+
**Related Issue**: Fixes #<!-- issue number -->
16+
17+
<!-- Brief description of what this PR does -->
18+
19+
## 🎯 What
20+
21+
<!-- Describe what changes you've made -->
22+
23+
## 🤔 Why
24+
25+
<!-- Explain why this change is needed -->
26+
27+
## 🔧 How
28+
29+
<!-- Describe the approach you took to implement the changes -->
30+
31+
## 🧪 Testing
32+
33+
<!-- Check all that apply -->
34+
35+
- [ ] I have tested these changes locally
36+
- [ ] All existing tests pass (`uv run task test` for backend, `pnpm test` for frontend)
37+
- [ ] I have added new tests for new functionality
38+
- [ ] I have run linting and type checking (`uv run task lint && uv run task lint_types` for backend)
39+
40+
### Test Instructions
41+
42+
<!-- Provide step-by-step instructions for reviewers to test your changes -->
43+
44+
1.
45+
2.
46+
3.
47+
48+
## 🖼️ Screenshots/Recordings
49+
50+
<!-- Include screenshots or recordings if your changes affect the UI -->
51+
<!-- You can drag and drop images directly into this text area -->
52+
53+
## 📝 Additional Notes
54+
55+
<!-- Any additional context, considerations, or notes for reviewers -->
56+
57+
## ✅ Pre-submission Checklist
58+
59+
- [ ] My code follows the project's style guidelines
60+
- [ ] I have performed a self-review of my code
61+
- [ ] I have commented my code where necessary
62+
- [ ] I have made corresponding changes to the documentation
63+
- [ ] My changes generate no new warnings
64+
- [ ] I have updated the relevant tests
65+
- [ ] All tests pass locally
66+
- [ ] **AI/LLM Policy**: If I used AI assistance, I have tested and executed the code locally (not just "vibe-coded")
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
#!/usr/bin/env -S uv run
2+
3+
# /// script
4+
# requires-python = ">=3.9"
5+
# dependencies = [
6+
# "httpx",
7+
# "certifi>2025.1.31"
8+
# ]
9+
# ///
10+
import argparse
11+
import sys
12+
13+
import certifi
14+
import httpx
15+
16+
17+
def _check_website(url: str) -> bool:
18+
try:
19+
httpx.get(url, verify=certifi.where())
20+
return True
21+
except httpx.ConnectError:
22+
return False
23+
24+
25+
if __name__ == "__main__":
26+
parser = argparse.ArgumentParser()
27+
parser.add_argument("url", help="URL to check")
28+
args = parser.parse_args()
29+
30+
result = _check_website(args.url)
31+
# Fail if the check PASSES (meaning pinning certifi is NOT needed anymore)
32+
sys.exit(0 if not result else 1)
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
name: Check if certifi<=2025.1.31 is still needed
2+
3+
on:
4+
workflow_dispatch:
5+
schedule:
6+
- cron: "0 9 * * *"
7+
8+
permissions:
9+
contents: read
10+
11+
jobs:
12+
check:
13+
runs-on: ubuntu-latest
14+
steps:
15+
- uses: actions/checkout@v5
16+
17+
- name: Install uv
18+
uses: astral-sh/setup-uv@v6
19+
with:
20+
enable-cache: true
21+
22+
- name: Run certifi pin check. Fail if certifi>2025.1.31 is not needed anymore.
23+
run: |
24+
.github/workflows/certifi-pin-check.py ${{ secrets.CERTIFI_PIN_URL_CHECK }}

.github/workflows/chromatic.yaml

Lines changed: 0 additions & 49 deletions
This file was deleted.

.github/workflows/copilot-setup-steps.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ jobs:
3939
- 5432:5432
4040

4141
minio:
42-
image: bitnami/minio:2024.5.28
42+
image: bitnamilegacy/minio:2024.5.28
4343
ports:
4444
- 9000:9000
4545
- 9001:9001

.github/workflows/deploy-environment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ jobs:
8888
RENDER_API_TOKEN: ${{ secrets.RENDER_API_TOKEN }}
8989

9090
- name: Sentry Release
91-
uses: getsentry/action-release@v3.2.0
91+
uses: getsentry/action-release@v3.3.0
9292
env:
9393
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
9494
SENTRY_ORG: ${{ secrets.SENTRY_ORG }}

.github/workflows/deploy.yml

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ on:
99
- ".github/workflows/deploy.yml"
1010
- ".github/workflows/deploy-environment.yml"
1111
- ".github/workflows/deploy_server.sh"
12+
workflow_dispatch:
1213

1314
jobs:
1415
changes:
@@ -36,7 +37,7 @@ jobs:
3637
build:
3738
name: "Build Docker Image 🐳"
3839
needs: changes
39-
if: needs.changes.outputs.backend == 'true'
40+
if: needs.changes.outputs.backend == 'true' || github.event_name == 'workflow_dispatch'
4041
timeout-minutes: 15
4142
runs-on: ubuntu-latest
4243
permissions:
@@ -92,14 +93,14 @@ jobs:
9293
deploy-sandbox:
9394
name: "Deploy to Sandbox 🧪"
9495
needs: [changes, build]
95-
if: always() && (needs.changes.outputs.backend == 'true' || needs.changes.outputs.frontend == 'true')
96+
if: always() && (needs.changes.outputs.backend == 'true' || needs.changes.outputs.frontend == 'true' || github.event_name == 'workflow_dispatch')
9697
uses: ./.github/workflows/deploy-environment.yml
9798
with:
9899
environment: sandbox
99100
docker-digest: ${{ needs.build.outputs.digest }}
100101
render-service-ids: "srv-crkocgbtq21c73ddsdbg,srv-d089jj7diees73934kgg"
101-
skip-backend: ${{ needs.changes.outputs.backend != 'true' }}
102-
skip-frontend: ${{ needs.changes.outputs.frontend != 'true' }}
102+
skip-backend: ${{ needs.changes.outputs.backend != 'true' && github.event_name != 'workflow_dispatch' }}
103+
skip-frontend: ${{ needs.changes.outputs.frontend != 'true' && github.event_name != 'workflow_dispatch' }}
103104
secrets:
104105
RENDER_API_TOKEN: ${{ secrets.RENDER_API_TOKEN }}
105106
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}
@@ -111,14 +112,14 @@ jobs:
111112
deploy-production:
112113
name: "Deploy to Production 🚀"
113114
needs: [changes, build, deploy-sandbox]
114-
if: always() && !failure() && !cancelled() && (needs.changes.outputs.backend == 'true' || needs.changes.outputs.frontend == 'true')
115+
if: always() && !failure() && !cancelled() && (needs.changes.outputs.backend == 'true' || needs.changes.outputs.frontend == 'true' || github.event_name == 'workflow_dispatch')
115116
uses: ./.github/workflows/deploy-environment.yml
116117
with:
117118
environment: production
118119
docker-digest: ${{ needs.build.outputs.digest }}
119120
render-service-ids: "srv-ci4r87h8g3ne0dmvvl60,srv-d089jj7diees73934ka0"
120-
skip-backend: ${{ needs.changes.outputs.backend != 'true' }}
121-
skip-frontend: ${{ needs.changes.outputs.frontend != 'true' }}
121+
skip-backend: ${{ needs.changes.outputs.backend != 'true' && github.event_name != 'workflow_dispatch' }}
122+
skip-frontend: ${{ needs.changes.outputs.frontend != 'true' && github.event_name != 'workflow_dispatch' }}
122123
secrets:
123124
RENDER_API_TOKEN: ${{ secrets.RENDER_API_TOKEN }}
124125
VERCEL_TOKEN: ${{ secrets.VERCEL_TOKEN }}

.github/workflows/test_client.yaml

Lines changed: 6 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -48,47 +48,14 @@ jobs:
4848
next-${{ hashFiles('./clients/pnpm-lock.yaml') }}-
4949
next-
5050
51-
- name: Build
52-
working-directory: ./clients
53-
run: pnpm build
54-
55-
- name: Test
56-
working-directory: ./clients
57-
run: pnpm test
58-
59-
build_storybook:
60-
name: "Client: Storybook 🎨"
61-
timeout-minutes: 15
62-
runs-on: ubuntu-latest
63-
64-
env:
65-
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
66-
TURBO_TEAM: ${{ vars.TURBO_TEAM }}
67-
VERCEL_ENV: "testing"
68-
69-
steps:
70-
- name: Check out code
71-
uses: actions/checkout@v5
72-
73-
- uses: pnpm/action-setup@v4
74-
with:
75-
version: 10.13.1
76-
77-
- name: Setup Node.js environment
78-
uses: actions/setup-node@v5
79-
with:
80-
node-version: v22
81-
cache: "pnpm"
82-
cache-dependency-path: "clients/pnpm-lock.yaml"
83-
84-
- name: Install dependencies
51+
- name: Lint
8552
working-directory: ./clients
86-
run: pnpm install
53+
run: pnpm run lint
8754

88-
- name: Build SDK
55+
- name: Typecheck
8956
working-directory: ./clients
90-
run: pnpm turbo run build --filter=@polar-sh/*
57+
run: pnpm run typecheck
9158

9259
- name: Build
93-
working-directory: ./clients/apps/web
94-
run: pnpm build-storybook
60+
working-directory: ./clients
61+
run: pnpm build

0 commit comments

Comments
 (0)