MCPcopy Create free account
hub / github.com/AutoForgeAI/autoforge / get_project_concurrency

Function get_project_concurrency

registry.py:412–430  ·  view source on GitHub ↗

Get project's default concurrency (1-5). Args: name: The project name. Returns: The default concurrency value (defaults to 3 if not set or project not found).

(name: str)

Source from the content-addressed store, hash-verified

410
411
412def get_project_concurrency(name: str) -> int:
413 """
414 Get project's default concurrency (1-5).
415
416 Args:
417 name: The project name.
418
419 Returns:
420 The default concurrency value (defaults to 3 if not set or project not found).
421 """
422 _, SessionLocal = _get_engine()
423 session = SessionLocal()
424 try:
425 project = session.query(Project).filter(Project.name == name).first()
426 if project is None:
427 return 3
428 return getattr(project, 'default_concurrency', 3) or 3
429 finally:
430 session.close()
431
432
433def set_project_concurrency(name: str, concurrency: int) -> bool:

Callers 2

get_projectFunction · 0.90
update_project_settingsFunction · 0.90

Calls 2

_get_engineFunction · 0.85
closeMethod · 0.45

Tested by

no test coverage detected