-
Notifications
You must be signed in to change notification settings - Fork 24
Fix cli link #718
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Fix cli link #718
Conversation
WalkthroughUpdated UI text and layout in EnvioInkApp.res: changed label from "GraphQL Endpoint" to "GraphQL Interface", switched displayed URL from the /v1/graphql endpoint to the root Hasura URL, added an underlined URL line, and introduced a separate info-colored line showing "(password: testing)". Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
Tip 🔌 Remote MCP (Model Context Protocol) integration is now available!Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats. ✨ Finishing Touches🧪 Generate unit tests
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. CodeRabbit Commands (Invoked using PR/Issue comments)Type Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res (1)
45-60
: De-duplicate link rows with a tiny helper for consistency and alignment.Both “Development Console” and “GraphQL …” rows share structure. A small component improves readability and avoids manual spacing.
Example helper (add near this module):
module LinkRow = { @react.component let make = (~label: string, ~url: string, ~underline=true, ~color=Info) => { <Box flexDirection={Row}> <Text> {label->React.string} </Text> <Text color={color} underline> {url->React.string} </Text> </Box> } }Then replace the two rows:
<LinkRow label="Development Console: " url={`${Env.envioAppUrl}/console`} /> <LinkRow label="GraphQL Interface: " url={`${Env.Hasura.url}/console`} />
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
💡 Knowledge Base configuration:
- MCP integration is disabled by default for public repositories
- Jira integration is disabled by default for public repositories
- Linear integration is disabled by default for public repositories
You can enable these sources in your CodeRabbit configuration.
📒 Files selected for processing (1)
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
(1 hunks)
🧰 Additional context used
📓 Path-based instructions (3)
**/*.{res,resi}
📄 CodeRabbit inference engine (.cursor/rules/rescript.mdc)
**/*.{res,resi}
: Never use[| item |]
to create an array. Use[ item ]
instead.
Must always use=
for setting value to a field. Use:=
only for ref values created usingref
function.
ReScript has record types which require a type definition before hand. You can access record fields by dot likefoo.myField
.
It's also possible to define an inline object, it'll have quoted fields in this case.
Use records when working with structured data, and objects to conveniently pass payload data between functions.
Never use %raw to access object fields if you know the type.
Files:
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
codegenerator/cli/templates/{dynamic/**/*.hbs,static/**}
📄 CodeRabbit inference engine (.cursor/rules/navigation.mdc)
Templates live under codegenerator/cli/templates: dynamic/ for Handlebars (.hbs), static/ for raw Rescript files copied verbatim.
Files:
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
{**/generated/src/**/*.res,codegenerator/cli/templates/static/codegen/src/**/*.res,codegenerator/cli/templates/dynamic/codegen/src/**/*.res}
📄 CodeRabbit inference engine (.cursor/rules/navigation.mdc)
Runtime code lives in each project’s generated/src, but template versions (good for editing) are under codegenerator/cli/templates/static/codegen/src or codegenerator/cli/templates/dynamic/codegen/src.
Files:
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: build_and_test
🔇 Additional comments (1)
codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res (1)
53-57
: Confirm Hasura dashboard URL in EnvioInkApp
Please verify thatEnv.Hasura.url
actually points to your Hasura Console (often served under/console
) rather than just the API root. Incodegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
at line 56 you have:<Text color={Info} underline=true> {`${Env.Hasura.url}`->React.string} </Text>If your console is indeed hosted at
https://…/console
, consider appending that path:-<Text color={Info} underline=true> - {`${Env.Hasura.url}`->React.string} -</Text> +<Text color={Info} underline=true> + {`${Env.Hasura.url}/console`->React.string} +</Text>– Double-check your Hasura setup and update the link only if needed.
<Text color={Info}> | ||
{" (password: testing)"->React.string} | ||
</Text> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💡 Verification agent
🧩 Analysis chain
Remove hard-coded credential from TUI.
Displaying credentials is a security risk and may leak into screenshots or logs. Avoid showing secrets even in dev.
- <Text color={Info}>
- {" (password: testing)"->React.string}
- </Text>
Scan for similar leaks:
🏁 Script executed:
#!/bin/bash
rg -nP -C1 '(password|secret|token)\s*:\s*(testing|test|[A-Za-z0-9._-]{6,})'
Length of output: 3762
Remove the hard-coded credential from the TUI (critical)
Our grep scan confirms that the only literal credential (" (password: testing)"
) is in codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
. All other matches are type annotations or env-var references rather than hard-coded secrets. Please remove or externalize this snippet:
--- a/codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
+++ b/codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res
@@ lines 58-60
- <Text color={Info}>
- {" (password: testing)"->React.string}
- </Text>
No other hard-coded credentials were detected by the scan. Once this is removed (and any required placeholder logic added), the critical security issue will be resolved.
📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
<Text color={Info}> | |
{" (password: testing)"->React.string} | |
</Text> |
🤖 Prompt for AI Agents
In codegenerator/cli/templates/static/codegen/src/ink/EnvioInkApp.res around
lines 58-60 there is a hard-coded credential string " (password: testing)" that
must be removed; delete this literal from the TUI and either omit the password
display entirely or read a non-sensitive placeholder from
configuration/environment (e.g., process.env or app config) and render that
value only when present, avoiding any embedded plaintext secrets and ensuring
any display is gated by a feature flag or conditional check.
I'll test locally and approve 🫡 |
Summary by CodeRabbit