laravel

How to run python function in laravel with symfony process?

How to run python function in laravel with symfony process? Question: I have a python function which returns string data, code runs fine after run import mysql.connector mydb = mysql.connector.connect( host="localhost", user="root", passwd="", database="db_absensi" ) mycursor = mydb.cursor() def example(): mycursor.execute("SELECT * FROM examples) data = mycursor.fetchall() return data this is my symfony code public …

Total answers: 1

Manually run python file with command it runs fine but when i'm using for process its gives error.(composer require symfony/process)

Manually run python file with command it runs fine but when i'm using for process its gives error.(composer require symfony/process) Question: "The command "’python3′ ‘/var/www/html/vino_python/rembg-main/app.py’" failed.nnExit Code: 1(General error)nnWorking directory: /var/www/html/vino_pythonnnOutput:n================nnnError Output:n================nTraceback (most recent call last):n File "/var/www/html/vino_python/rembg-main/app.py", line 1, in n from rembg.bg import removen File "/var/www/html/vino_python/rembg-main/rembg/bg.py", line 7, in n from pymatting.alpha.estimate_alpha_cf import …

Total answers: 1

Laravel: Fatal Python error: _Py_HashRandomization_Init: failed to get random numbers to initialize Python Python runtime state: preinitialized

Laravel: Fatal Python error: _Py_HashRandomization_Init: failed to get random numbers to initialize Python Python runtime state: preinitialized Question: I can try to run Python script in Laravel. I am using composer require symfony/process for this. Actually, I don’t want to use shell_exec(). When I try to run it, an error is returned. In the command …

Total answers: 2

laravel 8 installation failed

laravel 8 installation failed Question: i use this command for install laravel + Authentication composer global require laravel/installer laravel new laravel–jet Laravel Installer 4.0.2 but showing this error on cmd: Which Jetstream stack do you prefer? [0] livewire [1] inertia > Aborted. and i using this commands: composer create-project –prefer-dist laravel/laravel laravel composer require laravel/jetstream …

Total answers: 7