Sorry my friend, we are on the same boat, no luck to get access to the GPIO as user.
You may try to add an udev rule
$this->bbcode_second_pass_code('', '# To allow additional features like edge detection
SUBSYSTEM=="gpio*", PROGRAM="/bin/sh -c '\
chown -R root:gpio /sys/class/gpio && chmod -R 770 /sys/class/gpio;\
chown -R root:gpio /sys/devices/virtual/gpio && chmod -R 770 /sys/devices/virtual/gpio;\
chown -R root:gpio /sys$devpath && chmod -R 770 /sys$devpath\
'"')
Then you should add your user to the gpio group
$this->bbcode_second_pass_code('', '
sudo groupadd gpio ### optional if you don't have such group
sudo gpasswd -a <your_user_name> gpio')
Anyways, this doesn't solve the problem, I still facing permission blockage as normal use, including python-periphery
The only feasible approach it might be to use a
daemon which will serve your commands to the GPIO. But you need to have some python experience and you have to rearrange the source to adjust to your goals.
For my own purposes I did get through this phase, because I need to know how it would interface with the home-assistant framework.