Rocky_Mountain_Vending/.pnpm-store/v10/files/ed/7e98e278b140ba2767ff50c8258074a7cbd8724b82b82f6599a4e5528b7334accda33033fa18f2fe811884df5f834e825315b543a5cd398db46b06aa1c15e7
DMleadgen 46d973904b
Initial commit: Rocky Mountain Vending website
Next.js website for Rocky Mountain Vending company featuring:
- Product catalog with Stripe integration
- Service areas and parts pages
- Admin dashboard with Clerk authentication
- SEO optimized pages with JSON-LD structured data

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-02-12 16:22:15 -07:00

60 lines
1.9 KiB
Text

Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
const debugBuild = require('../debug-build.js');
const debugLogger = require('../utils/debug-logger.js');
const spanUtils = require('../utils/spanUtils.js');
/**
* Print a log message for a started span.
*/
function logSpanStart(span) {
if (!debugBuild.DEBUG_BUILD) return;
const { description = '< unknown name >', op = '< unknown op >', parent_span_id: parentSpanId } = spanUtils.spanToJSON(span);
const { spanId } = span.spanContext();
const sampled = spanUtils.spanIsSampled(span);
const rootSpan = spanUtils.getRootSpan(span);
const isRootSpan = rootSpan === span;
const header = `[Tracing] Starting ${sampled ? 'sampled' : 'unsampled'} ${isRootSpan ? 'root ' : ''}span`;
const infoParts = [`op: ${op}`, `name: ${description}`, `ID: ${spanId}`];
if (parentSpanId) {
infoParts.push(`parent ID: ${parentSpanId}`);
}
if (!isRootSpan) {
const { op, description } = spanUtils.spanToJSON(rootSpan);
infoParts.push(`root ID: ${rootSpan.spanContext().spanId}`);
if (op) {
infoParts.push(`root op: ${op}`);
}
if (description) {
infoParts.push(`root description: ${description}`);
}
}
debugLogger.debug.log(`${header}
${infoParts.join('\n ')}`);
}
/**
* Print a log message for an ended span.
*/
function logSpanEnd(span) {
if (!debugBuild.DEBUG_BUILD) return;
const { description = '< unknown name >', op = '< unknown op >' } = spanUtils.spanToJSON(span);
const { spanId } = span.spanContext();
const rootSpan = spanUtils.getRootSpan(span);
const isRootSpan = rootSpan === span;
const msg = `[Tracing] Finishing "${op}" ${isRootSpan ? 'root ' : ''}span "${description}" with ID ${spanId}`;
debugLogger.debug.log(msg);
}
exports.logSpanEnd = logSpanEnd;
exports.logSpanStart = logSpanStart;
//# sourceMappingURL=logSpans.js.map