fix: accept literals instead of labels#1164
Conversation
🦋 Changeset detectedLatest commit: d12ede1 The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
1 Skipped Deployment
|
WalkthroughThis pull request introduces a new changeset file documenting a patch for the "uploadthing" component configuration validator. It updates internal logger functionality by adding a new function, Changes
Sequence Diagram(s)sequenceDiagram
participant C as Caller
participant L as ConfigLogLevel
participant M as Config.mapOrFail
participant E as Error Handler
C->>L: Request log level configuration
L->>M: Validate input string for log level
alt Valid log level found
M-->>L: Return valid log level (Right)
L-->>C: Respond with log level configuration
else Invalid log level
M-->>L: Return error indicator
L->>E: Generate ConfigError.InvalidData
L-->>C: Respond with error (Left)
end
Warning There were issues while running some tools. Please review the errors and either fix the tool’s configuration or disable the tool if it’s a critical failure. 🔧 ESLint
Scope: all 3 workspace projects This error happened while installing a direct dependency of /tmp/eslint/packages/uploadthing Packages found in the workspace: 📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
⏰ Context from checks skipped due to timeout of 90000ms (9)
🔇 Additional comments (5)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
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 using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
| * Config.logLevel counter-intuitively accepts LogLevel["label"] | ||
| * instead of a literal, ripping it and changing to accept literal | ||
| */ | ||
| export const ConfigLogLevel = ( |
There was a problem hiding this comment.
this is taken from the official Config.logLevel and just change to accept literal instead.
More templates
commit: |
📦 Bundle size comparison
|
Closes #1163
Config.logLevelaccepts a label and not a literal, but have gotten a hint that this will change in Effect 4.0 so instead of changing our types to match the current behavior, I figured we'll just start accepting literalsSummary by CodeRabbit
Bug Fixes
New Features