Files
clientflow_backend/docs/CLIENTFLOW_V4926_7_1_NOTES.md
2026-06-09 22:55:58 +01:00

1.4 KiB

ClientFlow v4.9.26.7.1 — stale email identity review cleanup

Context

The SEMENTENERGIAS opportunity had been corrected at fiscal-customer level, but the technical fiscal-association panel still displayed a stale email identity extraction where pt was treated as a company mention and an old PLANETOPTION suggestion was shown.

Changes

  • Applies current company-mention guardrails when reading already-stored email_identity_extractions.
  • Filters invalid company mentions such as pt, com, www, http, domains and TLDs even if they were saved before the guardrail existed.
  • Prevents conflict calculation when there is no valid explicit company mention.
  • Prevents internal customer suggestion display when the only mention is invalid/stale.
  • Fixes identity confidence display: 0.95 is now shown as 95%, not 1%.
  • Hides stale accepted suggestions that duplicate the currently linked fiscal customer without NIF.
  • Improves scripts/cleanup_invalid_email_identity_suggestions.py:
    • no longer writes to non-existent resolution_note column;
    • can reject invalid suggestions;
    • can rewrite stored email identity extractions with current filters.
PYTHONPATH=. python scripts/cleanup_invalid_email_identity_suggestions.py \
  --opportunity-id <OPPORTUNITY_ID> \
  --include-accepted \
  --fix-extractions \
  --apply

Then restart the service and reload the opportunity detail.