#!/bin/bash set -e if [ "$1" = "configure" ] || [ "$1" = "upgrade" ]; then # Clear Python bytecode cache find /usr/lib/python3/dist-packages/vmmsclient -name "*.pyc" -delete 2>/dev/null || true find /usr/lib/python3/dist-packages/vmmsclient -name "__pycache__" -type d -exec rm -rf {} + 2>/dev/null || true # Force Python to regenerate entry point cache python3 -c "import importlib; import sys; [sys.modules.pop(key) for key in list(sys.modules.keys()) if key.startswith('vmmsclient')];" 2>/dev/null || true fi # Automatically added by dh_python3 if command -v py3compile >/dev/null 2>&1; then py3compile -p python3-vmmsclient fi if command -v pypy3compile >/dev/null 2>&1; then pypy3compile -p python3-vmmsclient || true fi # End automatically added section exit 0