Skip to content
This repository was archived by the owner on Oct 22, 2025. It is now read-only.

fix(core): fix endpoint undefined log#1380

Closed
NathanFlurry wants to merge 1 commit intomainfrom
10-13-fix_core_fix_endpoint_undefined_log
Closed

fix(core): fix endpoint undefined log#1380
NathanFlurry wants to merge 1 commit intomainfrom
10-13-fix_core_fix_endpoint_undefined_log

Conversation

@NathanFlurry
Copy link
Member

No description provided.

@vercel
Copy link

vercel bot commented Oct 13, 2025

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Preview Comments Updated (UTC)
rivetkit-serverless Ready Ready Preview Comment Oct 13, 2025 6:38pm

@claude
Copy link

claude bot commented Oct 13, 2025

Claude finished @NathanFlurry's task —— View job


PR Review: fix(core): fix endpoint undefined log

Todo List:

  • Read and analyze the modified file
  • Review code quality and best practices
  • Check for potential bugs or issues
  • Assess performance considerations
  • Evaluate security concerns
  • Review test coverage implications
  • Provide comprehensive feedback

Code Analysis

What Changed:
The PR fixes a potential undefined logging issue in the startup welcome message. The change replaces direct access to config.endpoint with a call to getEndpoint(config) utility function.

Files Modified:

  • packages/rivetkit/src/registry/mod.ts:164 - Updated endpoint logging to use getEndpoint() helper

Review Feedback

Code Quality & Best Practices

  • Good: The fix follows the existing pattern already used elsewhere in the codebase (line 254-258 in configureServerlessRunner)
  • Good: Uses the established utility function getEndpoint() which provides consistent endpoint resolution
  • Good: Maintains consistent code style and formatting
  • Good: The import statement is properly added at the top with other imports

Bug Fix Analysis

  • Issue Fixed: Previously, when config.endpoint was undefined, the welcome message would display undefined in the console output
  • Solution: The getEndpoint() function provides a fallback default of "http://127.0.0.1:6420" when config.endpoint is undefined (api-utils.ts:19)
  • Impact: Users will now see a proper endpoint URL instead of "undefined" in the startup logs

Performance Considerations

  • Minimal Impact: The change adds a simple function call with negligible performance overhead
  • No Issues: The getEndpoint() function is lightweight and only does a nullish coalescing operation

Security Considerations

  • No Concerns: The change doesn't introduce any security vulnerabilities
  • Safe: The default endpoint (127.0.0.1:6420) is localhost-bound, maintaining security posture

⚠️ Test Coverage

  • Gap: No tests were added for this specific scenario
  • Recommendation: Consider adding a test case that verifies the welcome message displays the correct endpoint when config.endpoint is undefined
  • Low Risk: This is a minor logging fix with minimal risk of regression

Consistency

  • Good: The fix aligns with how endpoints are handled elsewhere in the same file (configureServerlessRunner function uses the same pattern)
  • Good: Follows the established pattern of using utility functions rather than direct property access

Summary

This is a well-executed bug fix that addresses a minor but noticeable UX issue where "undefined" would appear in startup logs. The implementation:

  • Uses an existing, tested utility function
  • Follows established patterns in the codebase
  • Has minimal risk and impact
  • Improves user experience with more informative logging

Recommendation:Approve - This is a solid, low-risk improvement that fixes a genuine issue.


Copy link
Member Author

NathanFlurry commented Oct 13, 2025


How to use the Graphite Merge Queue

Add either label to this PR to merge it via the merge queue:

  • merge queue - adds this PR to the back of the merge queue
  • hotfix - for urgent hot fixes, skip the queue and merge this PR next

You must have a Graphite account in order to use the merge queue. Sign up using this link.

An organization admin has enabled the Graphite Merge Queue in this repository.

Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue.

This stack of pull requests is managed by Graphite. Learn more about stacking.

@pkg-pr-new
Copy link

pkg-pr-new bot commented Oct 13, 2025

More templates

@rivetkit/actor

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/actor@1380

@rivetkit/cloudflare-workers

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/cloudflare-workers@1380

@rivetkit/core

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/core@1380

@rivetkit/db

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/db@1380

@rivetkit/framework-base

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/framework-base@1380

@rivetkit/next-js

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/next-js@1380

@rivetkit/react

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/react@1380

rivetkit

pnpm add https://pkg.pr.new/rivet-dev/rivetkit@1380

@rivetkit/sql-loader

pnpm add https://pkg.pr.new/rivet-dev/rivetkit/@rivetkit/sql-loader@1380

commit: 6808fc1

@graphite-app
Copy link

graphite-app bot commented Oct 13, 2025

Merge activity

  • Oct 13, 6:24 PM UTC: NathanFlurry added this pull request to the Graphite merge queue.
  • Oct 13, 6:25 PM UTC: CI is running for this pull request on a draft pull request (#1383) due to your merge queue CI optimization settings.
  • Oct 13, 6:26 PM UTC: Merged by the Graphite merge queue via draft PR: #1383.

graphite-app bot pushed a commit that referenced this pull request Oct 13, 2025
@graphite-app graphite-app bot closed this Oct 13, 2025
@graphite-app graphite-app bot deleted the 10-13-fix_core_fix_endpoint_undefined_log branch October 13, 2025 18:26
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant