Fix 'pip externally managed environment' Error on Python 3.11 - How to Resolve Defender Configuration Error-Python UnicodeDecodeError: Using ignore to Skip Bad Bytes

Final checklist
- Confirm that the same symptom is gone after a restart or refresh.
- Keep the smallest working change and undo temporary diagnostic settings.