I made a test with a basic python script /home/pi/Documents/sample.py:
print("hello word")
then I wrote a service script /etc/systemd/system/my_boot.service:
[unit]
Description=Raspberry Pi My test
After=network.target
[Service]
Type=idle
ExecStart=/usr/bin/python3 /home/pi/Documents/sample.py
User=pi
[Install]
WantedBy=default.target
Then I Typed:
systemctl daemon-reload
systemctl enable my_boot.service
systemctl start my_boot.service
When I reboot, nothing happens although I can see the name of the service displayed in the boot sequence. I tried with python instead of python3. When I use the rc.local instead of systemd 'Hello world' is displayed correctly at boot. My config is Console mode automatic login. I'm using Wifi and SSH.