interrupted by signal 11: SIGSEGV when running bpy module from Flask app
Haven't done much with flask, will offer this up as a suggested workaround.

Try loading the mainfile outside of @route decorated methods.

Putting the load operator in any route method also caused a segfault for me (Ubuntu 18, blender 2.90, python 3.82)  Suspect a threading issue.

The following works as expected,

# batTOOLS...........

from flask import Flask
import bpy

app = Flask(__name__)
bpy.ops.wm.open_mainfile(filepath="/home/batfinger/Documents/blender/tests/BISECTO.blend")


@app.route('/')
def hello_world():
    lines = []
    for o in bpy.data.objects:
        lines.append(f"{o.name}&lt;/br&gt;")

    return "\n".join(lines)