I have created python script which is a windows service. Below is the code:
client_service.py
import logging import os import sys import p