Skip to content
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

chore: env updates #288

Closed
wants to merge 3 commits into from
Closed

chore: env updates #288

wants to merge 3 commits into from

Conversation

gaboesquivel
Copy link
Member

@gaboesquivel gaboesquivel commented Jul 24, 2024

Summary by Sourcery

This pull request updates the environment configurations by adding new USDT and USDC contracts to the production settings and simplifying the test settings. It also removes the canary environment configuration and adds documentation for the environment settings.

  • Enhancements:
    • Updated the production environment configuration to include additional USDT and USDC contracts.
    • Simplified the test environment configuration by extending the production configuration.
  • Documentation:
    • Added a README.md file to the app-env package, detailing the environment configurations for production, pre-production, and development.
  • Chores:
    • Removed the canary environment configuration from the environment settings.

Summary by CodeRabbit

  • New Features

    • Introduced a new environment configuration file for the web application, allowing developers to toggle features during development.
    • Updated environment variables for wallet redirection, new navigation structure, presale feature, and more.
  • Bug Fixes

    • Updated dependency versions across multiple applications to enhance compatibility and introduce improvements.
  • Documentation

    • Added a README file outlining environment configurations, helping developers understand deployment practices more clearly.
  • Chores

    • General maintenance updates to various package versions to keep dependencies current and functional.

* debug: vercel install scripts

* debug: vercel install scripts

* chore: default to dev env

* debug: node-gyp dependency (#285)

* debug: node-gyp dependency

* debug: restore contracts

* chore: remove hardhat from bun workspace

* chore: update app-env package

* chore: update dependencies
Copy link

vercel bot commented Jul 24, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
bitlauncher ❌ Failed (Inspect) Jul 24, 2024 6:04pm
smartsale-faucet ❌ Failed (Inspect) Jul 24, 2024 6:04pm

Copy link
Contributor

sourcery-ai bot commented Jul 24, 2024

Reviewer's Guide by Sourcery

This pull request updates the environment configurations for the smartsale project. The changes include modifying the usdt array in the production environment, cleaning up commented-out code in the development environment, removing the canary environment configuration, and simplifying the test environment configuration by extending the production settings. Additionally, a README file has been added to document the environment configurations, and an unused types file has been deleted.

File-Level Changes

Files Changes
packages/app-env/src/env.ts
packages/app-env/README.md
Updated environment configurations and added documentation for the smartsale project.
apps/webapp/types/index.ts Removed an unused types file.

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

Copy link
Contributor

coderabbitai bot commented Jul 24, 2024

Caution

Review failed

The pull request is closed.

Walkthrough

The recent updates primarily focus on version upgrades for various dependencies across different applications within the project. These changes include locking certain packages to specific versions, incrementing others to newer versions, and introducing new environment configurations. This maintenance effort enhances compatibility, introduces new features, and ensures the development environment is flexible for testing and feature toggling.

Changes

File(s) Change Summary
apps/faucet/package.json Updated dependency versions; locked @wagmi/connectors to exact version, upgraded others like lucide-react.
apps/indexer/package.json Incremented node-fetch (major update), resend, and updated TypeScript version; downgraded @types/node-fetch.
apps/supabase/package.json Incremented versions for supabase and supabase-to-zod dependencies.
apps/webapp/.env.development Introduced new environment variables to manage application features during development.
apps/webapp/package.json Upgraded various dependencies including @ai-sdk packages and typescript.
packages/app-env/README.md Added a README detailing the management of environment configurations for the project.
packages/app-env/src/env.ts Modified SmartsaleEnvConfig, expanded usdt contracts, streamlined configurations, and removed canary.

Sequence Diagram(s)

sequenceDiagram
    participant Developer
    participant Environment
    participant DependencyManager

    Developer->>Environment: Set environment variables
    Environment->>DependencyManager: Check for updated dependencies
    DependencyManager-->>Environment: Returns updated versions
    Environment->>Developer: Confirms updates and configuration
Loading

🐰 In the garden of code, changes abound,
With versions upgraded, new features found.
Dependencies dance in a fresh new light,
Making our project a wonderful sight!
Hops of joy in the developer's lair,
For smoother paths, our code is now fair! 🌼✨


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

Share
Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai generate interesting stats about this repository and render them as a table.
    • @coderabbitai show all the console.log statements in this repository.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (invoked as PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Additionally, you can add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@gaboesquivel gaboesquivel deleted the main branch July 24, 2024 18:05
Copy link
Contributor

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @gaboesquivel - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider removing the commented-out Supabase configuration in the 'test' environment or provide a clear explanation for why it's kept.
  • Please add a brief comment explaining the expansion of the 'usdt' array in the production environment. Why are all these contracts needed?
Here's what I looked at during the review
  • 🟡 General issues: 3 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟡 Documentation: 2 issues found

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

@@ -31,7 +31,7 @@ const prod: SmartsaleEnvConfig = {
auction: "0x",
bk: "launchpad.bk",
},
usdt: [EOSUSDT],
usdt: [EOSUSDT,...usdcContracts, ...usdtContracts],
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue (bug_risk): Potential issue with spread operator usage.

Ensure that usdcContracts and usdtContracts are arrays. If they are not, this could lead to unexpected behavior.

@@ -41,7 +41,6 @@ const dev: SmartsaleEnvConfig = {
},
chains: smartsaleChains.dev,
esrCallbackUrl: "https://dev.bitlauncher.ai/api/esr",
// esrCallbackUrl: "https://192.168.23.3:3000/api/esr",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Consider removing commented-out code.

Leaving commented-out code can clutter the codebase and make it harder to maintain. If this line is no longer needed, consider removing it entirely.

Suggested change
// esrCallbackUrl: "https://192.168.23.3:3000/api/esr",
},
chains: smartsaleChains.dev,
esrCallbackUrl: "https://dev.bitlauncher.ai/api/esr",
issuer: {
eos: "gaboesquivel",

usdt: [EOSFakeBITUSD, EOSFakeUSDT, SepoliaUSDT, TestnetUSDT, ...usdcContracts, ...usdtContracts],
};

// pre production tests
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Unclear comment.

The comment // pre production tests is vague. If it is necessary, consider making it more descriptive or removing it if it does not add value.

Suggested change
// pre production tests
/**
* Configuration for pre-production testing environment.
* This includes settings and contracts for testing purposes.
*/

@@ -0,0 +1,11 @@
# app-env

This package manages the environment configurations for the smartsale project, covering production, pre-production, and development settings.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (documentation): Consider capitalizing 'smartsale' to 'SmartSale'.

It might be a proper noun or brand name, so capitalizing it could be more appropriate.

Suggested change
This package manages the environment configurations for the smartsale project, covering production, pre-production, and development settings.
This package manages the environment configurations for the SmartSale project, covering production, pre-production, and development settings.

## Environments

- **Production (prod)**: [bitlauncher.ai](https://bitlauncher.ai) - Mainnet auction contracts with real tokens.
- **Pre-Production (test)**: [test.bitlauncher.ai](https://test.bitlauncher.ai) - Mainnet pre-prod auction contracts with real tokens.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion (documentation): Consider changing 'pre-prod' to 'pre-production' for consistency.

Using 'pre-production' instead of 'pre-prod' would maintain consistency with the rest of the document.

Suggested change
- **Pre-Production (test)**: [test.bitlauncher.ai](https://test.bitlauncher.ai) - Mainnet pre-prod auction contracts with real tokens.
**Pre-Production (test)**: [test.bitlauncher.ai](https://test.bitlauncher.ai) - Mainnet pre-production auction contracts with real tokens.

Copy link

⚡️ Lighthouse report

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844678207-86504.report.html

Category Score
🟠 Performance 88
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🟠 PWA 63

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/about
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844678493-11882.report.html

Category Score
🟠 Performance 87
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🔴 PWA 38

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/security
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844678871-88622.report.html

Category Score
🟠 Performance 87
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🔴 PWA 38

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/bitcash-bitlauncher
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844679167-57431.report.html

Category Score
🟠 Performance 88
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🔴 PWA 38

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/blog
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844679472-25607.report.html

Category Score
🟠 Performance 88
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🔴 PWA 38

Page: https://bitlauncher-qidslqip0-bitcash.vercel.app/blog/ai
Report https://storage.googleapis.com/lighthouse-infrastructure.appspot.com/reports/1721844679794-84887.report.html

Category Score
🟠 Performance 88
🟢 Accessibility 93
🟢 Best practices 100
🟠 SEO 67
🔴 PWA 38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant