Run Grasshopper Script via PyRevit

Hello everyone,
I’m trying to run a Grasshopper script via pyRevit. After creating a pushbutton extension and loading the script into the pyRevit tab, the script doesn’t work. The message shown in the attached image appeared.

When I attempted to open the Grasshopper script using Rhino.Inside.Revit and pressed the button in pyRevit, these warnings appeared in the Grasshopper components
“Revit API: Writing of entities of this schema is not allowed to the current add-in.”
“Transaction rolled back and aborted”

The script is just a test to run Grasshopper script via PyRevit, and it is only to create a str. framing.

Any suggestions on how to properly run the script?

2