一键导入
一键导入
Add a new Terraform Cloud variable for the Render-hosted backend across production, sandbox, and test. Declares the tfe_variable in terraform/global/{production,sandbox,test}.tf and the matching variable {} block in terraform/{production,sandbox,test}/variables.tf, then reminds the user to wire it into render.tf / the render_service module.
Local development environment management for Polar using Docker
Add a new translation locale to the Polar frontend. Walks through registering the locale, generating translations, wiring the generated file into the i18n package, and updating the public-facing docs. Expects the target locale's ISO 639-1 alpha-2 code (optionally with a BCP-47 region suffix, e.g. `pt-PT`).
React and Next.js performance optimization guidelines from Vercel Engineering. This skill should be used when writing, reviewing, or refactoring React/Next.js code to ensure optimal performance patterns. Triggers on tasks involving React components, Next.js pages, data fetching, bundle optimization, or performance improvements.
Prepare an interview task for a candidate, as part of our hiring process.
A skill to add a new entry in the section "Backend Development" of the Polar Handbook. Those entries are there to explain concepts, tooling and best practices related to backend development, and are meant to be read by Polar developers.
| name | fix-sentry |
| description | Analyze and fix issues reported by Sentry in the Polar codebase. |
| user-invocable | true |
| allowed-tools | Bash(gh:*) Bash(git:*) logfire_polar* sentry_polar* github* |
You're responsible for analyzing and fixing issues reported by Sentry in the Polar codebase. This involves investigating the Sentry reports, identifying the root causes of the issues, and implementing fixes to resolve them.
If not provided in the invocation prompt, you should ask the user for the a Sentry issue ID or a link to the Sentry issue. This will allow you to access the details of the issue and begin your analysis.
The Sentry organization ID of Polar is 4505046560538624 and its slug is polar-sh.
Using the sentry_polar tools, access the details of the Sentry issue provided by the user. This includes the error message, stack trace, and any additional context or metadata associated with the issue.
Extract the correlation_id tag from the Sentry issue. If available, use it to search for related logs in Logfire using the logfire_polar tools. This can provide additional context and insights into the events leading up to the issue, helping you to further understand the root cause.
The clause will look like this: attributes->>'correlation_id' = '<correlation_id>'
If any logs has source_correlation_id, query those logs as well.
Look up for relevant code in the codebase using the information from the Sentry issue and the Logfire logs. This may involve searching for specific error messages, function names, or other relevant keywords in the codebase.
Synthetize the information gathered from the Sentry issue, Logfire logs, and source code search to formulate a hypothesis about the root cause of the issue.
Important: If your analysis indicates that the issue involves heavy architectural changes, or if you are unsure about the best way to implement a fix, do not proceed with implementing a fix on your own. Instead, open an issue on polarsource/polar with your findings and analysis.
Always start by creating a git worktree for the work you are about to do. This will allow you to keep your changes organized and separate from the main codebase until they are ready to be merged. Run the following script:
./dev/create-worktree <branch-name>
This will create a worktree and prepare the environment for you to work on the issue. Make sure to replace <branch-name> with a descriptive name for your branch, using only lowercase letters, digits, and underscores. The worktree is created in the ./worktrees directory, and you can navigate to it using cd ./worktrees/<branch-name>.
IMPORTANT: From now on, all your changes and commands should be executed within the context of the worktree you just created. This ensures that your changes are isolated and can be easily managed.
cd ./worktrees/<branch-name>
Based on your analysis, implement a fix to resolve the issue. This may involve modifying existing code, adding new code, or making configuration changes.
Check linting, type checking, and tests before committing your changes, as detailed in AGENTS.md.
Commit your changes to the branch you created in the worktree. Make sure to write a clear and descriptive commit message that explains the changes you made and the reason for those changes.
Open a pull request on polarsource/polar using github tools, detailing your analysis, adding relevant links to the Sentry issue and Logfire logs, and describing the changes you made to fix the issue.