MCPcopy Create free account
hub / github.com/dot-agent/nextpy / session

Function session

nextpy/data/model.py:315–324  ·  view source on GitHub ↗

Get a session to interact with the database. Args: url: The database url. Returns: A database session.

(url: str | None = None)

Source from the content-addressed store, hash-verified

313
314
315def session(url: str | None = None) -> sqlmodel.Session:
316 """Get a session to interact with the database.
317
318 Args:
319 url: The database url.
320
321 Returns:
322 A database session.
323 """
324 return sqlmodel.Session(get_engine(url))

Callers

nothing calls this directly

Calls 1

get_engineFunction · 0.85

Tested by

no test coverage detected