I have a connection manager that works as follows:
def connect(self):
if len(connections) >= max_connections:
raise RuntimeError("Cannot initiate new connection.")
Is a RuntimeError the proper error to raise in this circumstance, or what would be a better approach?