def METHOD_NAME(hostname, port, database, auth):
    connect = {
        'host': hostname,
        'port': port}
    connect = {k: v for k, v in connect.items() if v is not None}
    client = pyorient.OrientDB(**connect)
    client.db_open(database, *auth)
    return client