How to handle audit enabling/disabling for DEFAULT_ORGANIZATION_ID sites
- Dominant language
- JavaScript
- Stars
- 5
- Forks
- 2
- Avg merge
- 19h 55m
- Merged PRs (30d)
- 33
Description
## Overview
How to handle audit enabling/disabling for DEFAULT_ORGANIZATION_ID sites
## Details
https://cq-dev.slack.com/archives/C05A45JBP9N/p1712563602198179
https://github.com/adobe/spacecat-api-service/blob/main/src/controllers/trigger/common/trigger.js#L56
https://github.com/adobe/spacecat-shared/blob/528b370751b275c309c050c59de77eac0ccccf62/packages/spacecat-shared-utils/src/helpers.js#L41
All created sites land in the `default` organization, if not otherwise set to a proper organization.
=> all audits (yes, there are exceptions that were not migrated to checking `isAuditsDisabled` common helper) for sites in the "default" organization are disabled, even if they are later set to enabled at site-level.
If we enable `default` organization for all audits, then we have to disable all audits for all sites created in the `default` org first, and re-enable manually for selected ones.
If we create a separate org for the site that revealed this issue to overcome the above, then that org is not DEFAULT_ORGANIZATION_ID and might break reporting about how many real validated customer orgs/sites vs DEFAULT_ORGANIZATION_ID.
## Proposed Actions
and now?
Contributor guide
Assessment
This issue has not been assessed yet.