Codesandbox dev#586
Conversation
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com> Signed-off-by: Dargon789 <64915515+Dargon789@users.noreply.github.com>
Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com> Signed-off-by: Dargon789 <64915515+Dargon789@users.noreply.github.com>
Co-authored-by: gemini-code-assist[bot] <176961590+gemini-code-assist[bot]@users.noreply.github.com> Signed-off-by: Dargon789 <64915515+Dargon789@users.noreply.github.com>
* Bump next from 15.5.14 to 15.5.15 (0xsequence#989) Bumps [next](https://github.com/vercel/next.js) from 15.5.14 to 15.5.15. - [Release notes](https://github.com/vercel/next.js/releases) - [Changelog](https://github.com/vercel/next.js/blob/canary/release.js) - [Commits](vercel/next.js@v15.5.14...v15.5.15) --- updated-dependencies: - dependency-name: next dependency-version: 15.5.15 dependency-type: direct:production ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> * Update to latest pnpm * 3.0.8 * Fix fee options stub signature (0xsequence#999) * 3.0.9 * Enforce minimum age limitation for packages --------- Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Taylan Pince <taylanpince@gmail.com> Co-authored-by: tolgahan-arikan <tolgahan.arikan@gmail.com>
|
|
Review or Edit in CodeSandboxOpen the branch in Web Editor • VS Code • Insiders |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
Reviewer's GuideAdds a new wagmi-based Vite demo project for wallet connection (likely for CodeSandbox dev), introduces Fortify AST and Azure Pipelines CI workflows plus GitHub issue/security templates, and updates the indexer changelog for a 2.0.0 release placeholder along with various sandbox/config/cache files. Sequence diagram for wallet connection flow in wagmi AppsequenceDiagram
actor User
participant App
participant useConnect
User ->> App: click connector button
App ->> useConnect: connect(connector)
alt [connection succeeds]
useConnect -->> App: status=connected
else [connection fails]
useConnect -->> App: error.message
end
App -->> User: render account.status and addresses
Flow diagram for React app bootstrapping with Wagmi and React Queryflowchart LR
Browser --> ReactDOM_root
ReactDOM_root --> WagmiProvider
WagmiProvider --> QueryClientProvider
QueryClientProvider --> App
WagmiProvider --> Wagmi_config
App --> useAccount
App --> useConnect
App --> useDisconnect
File-Level Changes
Possibly linked issues
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
There was a problem hiding this comment.
Hey - I've found 2 issues, and left some high level feedback:
- Consider excluding generated and environment-specific artifacts like
v8-compile-cache-0/**,.codesandbox/tasks.json, andCNAMEfrom source control (e.g., via.gitignore) to avoid bloating the repo with cache and hosting-specific files. - The Azure pipeline is pinned to Node 10 (
versionSpec: '10.x'), which is EOL; aligning this with the Node version your project actually uses (e.g., a current LTS) will prevent future incompatibilities and security issues. - In
wagmi-project/src/wagmi.ts,walletConnectdepends onimport.meta.env.VITE_WC_PROJECT_ID; you may want to add a guard or fallback to avoid runtime failures when this env var is missing or misconfigured.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Consider excluding generated and environment-specific artifacts like `v8-compile-cache-0/**`, `.codesandbox/tasks.json`, and `CNAME` from source control (e.g., via `.gitignore`) to avoid bloating the repo with cache and hosting-specific files.
- The Azure pipeline is pinned to Node 10 (`versionSpec: '10.x'`), which is EOL; aligning this with the Node version your project actually uses (e.g., a current LTS) will prevent future incompatibilities and security issues.
- In `wagmi-project/src/wagmi.ts`, `walletConnect` depends on `import.meta.env.VITE_WC_PROJECT_ID`; you may want to add a guard or fallback to avoid runtime failures when this env var is missing or misconfigured.
## Individual Comments
### Comment 1
<location path="azure-pipelines.yml" line_range="15" />
<code_context>
+steps:
+- task: NodeTool@0
+ inputs:
+ versionSpec: '10.x'
+ displayName: 'Install Node.js'
+
</code_context>
<issue_to_address>
**🚨 issue (security):** Node.js 10.x in the pipeline is EOL and likely incompatible with this toolchain
This stack (Vite 5, TypeScript 5, React 18) expects at least Node 16, ideally 18+. Node 10 is EOL, insecure, and likely to break the build. Please update `versionSpec` to a supported LTS (e.g. `18.x` or `20.x`).
</issue_to_address>
### Comment 2
<location path="wagmi-project/src/wagmi.ts" line_range="10" />
<code_context>
+ connectors: [
+ injected(),
+ coinbaseWallet(),
+ walletConnect({ projectId: import.meta.env.VITE_WC_PROJECT_ID }),
+ ],
+ transports: {
</code_context>
<issue_to_address>
**suggestion:** No guard around `VITE_WC_PROJECT_ID` could cause runtime failures when missing or misconfigured
Consider validating `import.meta.env.VITE_WC_PROJECT_ID` at startup and either disabling the WalletConnect connector or throwing a clear configuration error when it’s missing/invalid, so failures are deterministic and not triggered deep in the connector logic.
Suggested implementation:
```typescript
const walletConnectProjectId = import.meta.env.VITE_WC_PROJECT_ID
if (!walletConnectProjectId) {
// WalletConnect is disabled when the project ID is not configured
console.warn(
'[wagmi] WalletConnect disabled: VITE_WC_PROJECT_ID is not set or invalid.',
)
}
export const config = createConfig({
```
```typescript
connectors: [
injected(),
coinbaseWallet(),
...(walletConnectProjectId
? [walletConnect({ projectId: walletConnectProjectId })]
: []),
],
```
</issue_to_address>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
There was a problem hiding this comment.
Code Review
This pull request introduces a new project structure, including a Vite-based web application, Azure Pipelines configuration, and repository metadata like issue templates. The review identifies several critical issues: the CI pipeline uses an obsolete Node.js version (10.x) incompatible with the modern stack, environment-specific build artifacts were mistakenly committed, the WalletConnect project ID requires validation to prevent runtime errors, and dependencies should be pinned rather than using the 'latest' tag to ensure build stability.
|
Deployment failed with the following error: Learn More: https://vercel.com/dargon789-forge?upgradeToPro=build-rate-limit |
Summary by Sourcery
Add a new example wagmi-based Vite React app and introduce security scanning and issue management infrastructure.
New Features:
Enhancements:
Build:
CI:
Documentation:
Chores: