@percy/logger
Advanced tools
Comparing version 1.28.3 to 1.28.4-beta.0
@@ -25,2 +25,3 @@ import { colors } from './utils.js'; | ||
messages = new Set(); | ||
ciMessages = new Set(); | ||
@@ -93,3 +94,6 @@ // track deprecations to limit noisy logging | ||
// Query for a set of logs by filtering the in-memory store | ||
query(filter) { | ||
query(filter, ciLogs = false) { | ||
if (ciLogs) { | ||
return Array.from(this.ciMessages).filter(filter); | ||
} | ||
return Array.from(this.messages).filter(filter); | ||
@@ -178,3 +182,3 @@ } | ||
// information to store with the message and other info | ||
log(debug, level, message, meta = {}) { | ||
log(debug, level, message, meta = {}, ciLogs = false) { | ||
// message might be an error-like object | ||
@@ -195,3 +199,8 @@ let err = typeof message !== 'string' && (level === 'debug' || level === 'error'); | ||
}; | ||
this.messages.add(entry); | ||
if (ciLogs) { | ||
this.ciMessages.add(entry); | ||
return; | ||
} else { | ||
this.messages.add(entry); | ||
} | ||
@@ -198,0 +207,0 @@ // maybe write the message to stdio |
{ | ||
"name": "@percy/logger", | ||
"version": "1.28.3", | ||
"version": "1.28.4-beta.0", | ||
"license": "MIT", | ||
@@ -12,3 +12,3 @@ "repository": { | ||
"access": "public", | ||
"tag": "latest" | ||
"tag": "beta" | ||
}, | ||
@@ -36,3 +36,3 @@ "engines": { | ||
}, | ||
"gitHead": "5d41045921c7ac06329c4b72caaf291d34e3f699" | ||
"gitHead": "fe4d7e944acd2081d901eb2eed202ccb64098576" | ||
} |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
16081
361
2