Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add console.warn() for all workers process #2146

Merged
merged 2 commits into from
Sep 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/lodex-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ jobs:

# Upload debug screenshots on failure
- name: Upload screenshots
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
if: failure()
with:
name: cypress-screenshots
Expand Down
2 changes: 2 additions & 0 deletions src/api/services/enrichment/enrichment.js
Original file line number Diff line number Diff line change
Expand Up @@ -400,6 +400,8 @@ export const setEnrichmentError = async (ctx, err) => {
});
jobLogger.info(ctx.job, logData);
notifyListeners(room, logData);
// very useful for identifying the origin of production errors.
console.warn('handleEnrichmentError', err);
notifyListeners(`${ctx.tenant}-enricher`, {
isEnriching: false,
success: false,
Expand Down
1 change: 1 addition & 0 deletions src/api/services/precomputed/precomputed.js
Original file line number Diff line number Diff line change
Expand Up @@ -531,6 +531,7 @@ export const setPrecomputedError = async (ctx, err) => {
progress.finish(ctx.tenant);
jobLogger.info(ctx.job, logData);
notifyListeners(room, logData);
console.warn('handlePrecomputedError', err);
notifyListeners(`${ctx.tenant}-precomputer`, {
isPrecomputing: false,
success: false,
Expand Down
2 changes: 2 additions & 0 deletions src/api/workers/import.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,8 @@ const handleImportError = async (job, err) => {
if (err instanceof CancelWorkerError) {
await ctx.dataset.drop();
}
// very useful for identifying the origin of production errors.
console.warn('handleImportError', err);
notifyListeners(`${job.data.tenant}-import`, {
isImporting: false,
success: false,
Expand Down
2 changes: 2 additions & 0 deletions src/api/workers/publisher.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,8 @@ const startPublishing = async (job) => {
const handlePublishError = async (job, error) => {
const ctx = await prepareContext({ job });
await clearPublished(ctx);
// very useful for identifying the origin of production errors.
console.warn('handlePublisherError', error);
notifyListeners(`${job.data.tenant}-publisher`, {
isPublishing: false,
success: false,
Expand Down
Loading