MCPcopy Create free account
hub / github.com/crewAIInc/crewAI / assert_anonymous

Function assert_anonymous

lib/cli/tests/experimental/test_eval_crew.py:976–981  ·  view source on GitHub ↗

A random uuid4: not the run's id, not the project's, nothing derived.

(eval_id: str)

Source from the content-addressed store, hash-verified

974
975
976def assert_anonymous(eval_id: str) -> None:
977 """A random uuid4: not the run's id, not the project's, nothing derived."""
978 assert uuid.UUID(eval_id).version == 4 and str(uuid.UUID(eval_id)) == eval_id
979 assert eval_id not in (EXECUTION_ID, "proj-1")
980 for name in (EXECUTION_ID, "proj-1"):
981 assert eval_id not in {str(uuid.uuid5(uuid.NAMESPACE_OID, name)), str(uuid.uuid3(uuid.NAMESPACE_OID, name))}
982
983
984@pytest.mark.parametrize(("run_id", "target"), [(None, "last_run"), (EXECUTION_ID, "given_run")])

Calls

no outgoing calls

Tested by

no test coverage detected