feat: Handle "scope" context in error logs (#2772)
Resolves https://github.com/webrecorder/browsertrix/issues/2771 ## Changes Handles new `scope` crawl error log context.
This commit is contained in:
parent
ed580c41e4
commit
1c814cad6b
@ -12,6 +12,7 @@ import { tw } from "@/utils/tailwind";
|
|||||||
|
|
||||||
const labelFor: Record<CrawlLogContext, string> = {
|
const labelFor: Record<CrawlLogContext, string> = {
|
||||||
[CrawlLogContext.General]: msg("General"),
|
[CrawlLogContext.General]: msg("General"),
|
||||||
|
[CrawlLogContext.Scope]: msg("Crawl Scope"),
|
||||||
[CrawlLogContext.Behavior]: msg("Page Behavior"),
|
[CrawlLogContext.Behavior]: msg("Page Behavior"),
|
||||||
[CrawlLogContext.BehaviorScript]: msg("Built-in Behavior"),
|
[CrawlLogContext.BehaviorScript]: msg("Built-in Behavior"),
|
||||||
[CrawlLogContext.BehaviorScriptCustom]: msg("Custom Behavior Script"),
|
[CrawlLogContext.BehaviorScriptCustom]: msg("Custom Behavior Script"),
|
||||||
@ -21,6 +22,7 @@ const contextLevelFor: Record<CrawlLogContext, number> = {
|
|||||||
[CrawlLogContext.Behavior]: 1,
|
[CrawlLogContext.Behavior]: 1,
|
||||||
[CrawlLogContext.BehaviorScript]: 2,
|
[CrawlLogContext.BehaviorScript]: 2,
|
||||||
[CrawlLogContext.General]: 3,
|
[CrawlLogContext.General]: 3,
|
||||||
|
[CrawlLogContext.Scope]: 3,
|
||||||
[CrawlLogContext.BehaviorScriptCustom]: 4,
|
[CrawlLogContext.BehaviorScriptCustom]: 4,
|
||||||
};
|
};
|
||||||
// Minimum context level to highlight
|
// Minimum context level to highlight
|
||||||
|
@ -256,6 +256,7 @@ export enum CrawlLogLevel {
|
|||||||
|
|
||||||
export enum CrawlLogContext {
|
export enum CrawlLogContext {
|
||||||
General = "general",
|
General = "general",
|
||||||
|
Scope = "scope",
|
||||||
Behavior = "behavior",
|
Behavior = "behavior",
|
||||||
BehaviorScript = "behaviorScript",
|
BehaviorScript = "behaviorScript",
|
||||||
BehaviorScriptCustom = "behaviorScriptCustom",
|
BehaviorScriptCustom = "behaviorScriptCustom",
|
||||||
|
Loading…
Reference in New Issue
Block a user