Skip to content

Withhold Content Screening from the 1.0 release - #2001

Open
Paul Lizer (paullizer) wants to merge 1 commit into
microsoft:Developmentfrom
paullizer:claude/content-screening-viability-c42379
Open

Paul Lizer (paullizer) wants to merge 1 commit into
microsoft:Developmentfrom
paullizer:claude/content-screening-viability-c42379

Conversation

@paullizer

Copy link
Copy Markdown
Collaborator

Summary

Content Screening caused problems across the application when it was turned on, and it is planned to return after 1.0 (December or January). This PR withholds it without removing any code. One constant, CONTENT_SCREENING_AVAILABLE = False in content_screening/contracts.py, controls it, and setting it to True restores the capability as it was.

  • Cannot be turned on. Stored settings load with enable_content_screening off, and the loader saves that change. A save that turns it on returns 400 content_screening_unavailable. All three save paths (classic admin form, V2 admin save, PUT /api/content-screening/configuration) go through validate_content_screening_settings().
  • Hidden. The Content Screening admin tab is gone from both admin UIs (WITHHELD_TAB_IDS in admin_settings_nav.py), along with its classic pane and the Extraction tab notice. The classic workspace screening toolbar and the V2 "Screening scans" button now render only while the capability is on. Before, the button showed in every personal workspace even with it off.
  • Shared settings moved. "When to show AI replies" and "When a chat check cannot finish" apply to Content Safety too, so they move into the Content Safety section, in both the schema and the classic pane. The chat_content_settings_present form marker moves with them. Without it, a classic save would ignore every chat content setting.
  • Held documents are not released. Documents enrolled while screening was on keep their marker and their hold:
    • Owners can still delete them, because deletion does not depend on the switch, and re-uploading takes normal processing.
    • /content-review still resolves them.
    • Releasing them in bulk was left out on purpose. A hold can come from findings that need a reviewer, and an enrolled document's readable copy can be a screened version rather than the original file.
    • content_screening/access.py is the application's document authorization layer and is unchanged.

Linked issue

None.

Release Notes & Latest Features

  • New Feature
  • Bug Fix
  • UI Enhancement
  • Breaking Change
  • Internal only

Is this visible to end users?

  • Yes
  • No

Is this admin-facing (Admin Settings, governance, deployment, config)?

  • Yes
  • No

Should this become a Latest Feature card?

  • Yes
  • No
  • Already added

Screenshot needed for the card?

  • Yes
  • No
  • Attached

Version bump

  • application/single_app/config.py VERSION third segment bumped (0.261.511 → 0.261.512)
  • deployers/version.txt not needed because deployers/ was not changed

Testing / validation

  • New functional_tests/test_content_screening_release_withheld.py (9 passed). It covers loading, the refused save, other saves that still validate, the navigation, where the shared fields now live, the classic templates and the workspace controls.
  • Ran the 77 functional test files that reference the changed surfaces, one pytest process per file. 8 failed at first, and all pass after the updates below:
    • test_admin_settings_fields_registry_integrity, test_v2_admin_appearance_parity, test_v2_admin_workspaces_parity and test_v2_admin_security_parity now check the schema against DECLARED_ADMIN_NAV, which still includes the withheld tab.
    • test_content_screening_settings_api and test_content_screening_empty_policy (through its loader) run with CONTENT_SCREENING_AVAILABLE=True, so they still cover activation as it will return. test_content_screening_admin_settings_fix reads the declared navigation. test_app_settings_store_consistency supplies the new names its loader reads.
  • test_group_document_management.py (239 passed) and test_group_document_read_apis.py (211 passed) were run on their own, because they time out under parallel load.
  • scripts/check_cosmos_response_boundaries.py: 0 review gaps after re-reviewing functions_settings.py (module digest only) and the test_content_screening_settings_api.py seam (import digest only). test_cosmos_document_boundaries.py 51 passed.
  • V2 tsc --noEmit shows only the two existing missing-package errors (qrcode-generator, jsqr) from the local node_modules.
  • I did not run the full suite locally. CI runs it.
  • Known limitation: the browser suites ui_tests/test_content_screening_classic.py, test_v2_content_screening.py and test_content_screening_policy_parity.py turn screening on through the UI, so they cannot pass while it is withheld. CI does not run them.

Documentation

  • Release notes updated (Breaking Changes under v0.261.512)
  • Feature documentation not needed
  • Fix documentation updated: docs/explanation/fixes/CONTENT_SCREENING_WITHHELD_FROM_RELEASE_FIX.md

Security checklist

  • No new Flask routes
  • No change to how settings reach non-admin frontends
  • No CDN-hosted JS added
  • No secrets, keys, connection strings, or local-only artifacts are included

🤖 Generated with Claude Code

Content Screening caused problems across the application when turned on and
is planned to return after 1.0. One constant, CONTENT_SCREENING_AVAILABLE in
content_screening/contracts.py, now withholds it:

- Stored settings load with enable_content_screening off, and a save that
  turns it on is refused with content_screening_unavailable (all three save
  paths go through validate_content_screening_settings).
- The admin Content Screening tab, its classic pane and the Extraction notice
  are hidden; the classic workspace toolbar and the V2 "Screening scans"
  button follow the capability flag.
- The chat check behavior settings that Content Safety also uses move to the
  Content Safety section, with the classic form marker that gates them.

Documents already held keep their hold; owners can delete and re-upload them,
and /content-review still resolves them. access.py is the document
authorization layer and is unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

from test_support.app_stubs import import_app_module
from test_support.nav import ADMIN_NAV
from test_support.nav import ADMIN_NAV, DECLARED_ADMIN_NAV

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants