Skip to content

Commit 3b729ea

Browse files
author
Richard Kuo (Onyx)
committed
black format again
1 parent 12749da commit 3b729ea

34 files changed

+34
-0
lines changed

Diff for: backend/alembic_tenants/versions/34e3630c7f32_lowercase_multi_tenant_user_auth.py

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
Create Date: 2025-02-26 15:03:01.211894
66
77
"""
8+
89
from alembic import op
910

1011

Diff for: backend/alembic_tenants/versions/3b45e0018bf1_add_new_available_tenant_table.py

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
Create Date: 2025-03-06 09:55:18.229910
66
77
"""
8+
89
import sqlalchemy as sa
910

1011
from alembic import op

Diff for: backend/alembic_tenants/versions/a4f6ee863c47_mapping_for_anonymous_user_path.py

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
Create Date: 2025-01-04 14:16:58.697451
66
77
"""
8+
89
import sqlalchemy as sa
910

1011
from alembic import op

Diff for: backend/alembic_tenants/versions/ac842f85f932_new_column_user_tenant_mapping.py

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
Create Date: 2025-03-03 13:30:14.802874
66
77
"""
8+
89
import sqlalchemy as sa
910

1011
from alembic import op

Diff for: backend/ee/onyx/external_permissions/confluence/doc_sync.py

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
Rules defined here:
33
https://confluence.atlassian.com/conf85/check-who-can-view-a-page-1283360557.html
44
"""
5+
56
from collections.abc import Generator
67
from typing import Any
78

Diff for: backend/ee/onyx/external_permissions/slack/group_sync.py

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
SO WHEN CHECKING IF A USER CAN ACCESS A DOCUMENT, WE ONLY NEED TO CHECK THEIR EMAIL
55
THERE IS NO USERGROUP <-> DOCUMENT PERMISSION MAPPING
66
"""
7+
78
from slack_sdk import WebClient
89

910
from ee.onyx.db.external_perm import ExternalUserGroup

Diff for: backend/onyx/background/celery/tasks/tenant_provisioning/tasks.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
Periodic tasks for tenant pre-provisioning.
33
"""
4+
45
import asyncio
56
import datetime
67
import uuid

Diff for: backend/onyx/background/celery/versioned_apps/beat.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Factory stub for running celery worker / celery beat."""
2+
23
from celery import Celery
34

45
from onyx.background.celery.apps.beat import celery_app

Diff for: backend/onyx/background/celery/versioned_apps/client.py

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
55
This is an app stub purely for sending tasks as a client.
66
"""
7+
78
from celery import Celery
89

910
from onyx.utils.variable_functionality import set_is_ee_based_on_env_variable

Diff for: backend/onyx/background/celery/versioned_apps/heavy.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""Factory stub for running celery worker / celery beat.
22
This code is different from the primary/beat stubs because there is no EE version to
33
fetch. Port over the code in those files if we add an EE version of this worker."""
4+
45
from celery import Celery
56

67
from onyx.utils.variable_functionality import set_is_ee_based_on_env_variable

Diff for: backend/onyx/background/celery/versioned_apps/indexing.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""Factory stub for running celery worker / celery beat.
22
This code is different from the primary/beat stubs because there is no EE version to
33
fetch. Port over the code in those files if we add an EE version of this worker."""
4+
45
from celery import Celery
56

67
from onyx.utils.variable_functionality import set_is_ee_based_on_env_variable

Diff for: backend/onyx/background/celery/versioned_apps/light.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""Factory stub for running celery worker / celery beat.
22
This code is different from the primary/beat stubs because there is no EE version to
33
fetch. Port over the code in those files if we add an EE version of this worker."""
4+
45
from celery import Celery
56

67
from onyx.utils.variable_functionality import set_is_ee_based_on_env_variable

Diff for: backend/onyx/background/celery/versioned_apps/monitoring.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Factory stub for running celery worker / celery beat."""
2+
23
from celery import Celery
34

45
from onyx.utils.variable_functionality import set_is_ee_based_on_env_variable

Diff for: backend/onyx/background/celery/versioned_apps/primary.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Factory stub for running celery worker / celery beat."""
2+
23
from celery import Celery
34

45
from onyx.utils.variable_functionality import fetch_versioned_implementation

Diff for: backend/onyx/background/indexing/job_client.py

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
55
NOTE: cannot use Celery directly due to
66
https://github.com/celery/celery/issues/7007#issuecomment-1740139367"""
7+
78
import multiprocessing as mp
89
import sys
910
import traceback

Diff for: backend/onyx/connectors/onyx_jira/utils.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
"""Module with custom fields processing functions"""
2+
23
import os
34
from typing import Any
45
from typing import List

Diff for: backend/onyx/connectors/xenforo/connector.py

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
The `load_from_state` method is used to load documents from the forum. It takes an optional `state` parameter, which
1111
can be used to specify a state from which to start loading documents.
1212
"""
13+
1314
import re
1415
from datetime import datetime
1516
from datetime import timedelta

Diff for: backend/onyx/context/search/enums.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""NOTE: this needs to be separate from models.py because of circular imports.
22
Both search/models.py and db/models.py import enums from this file AND
33
search/models.py imports from db/models.py."""
4+
45
from enum import Enum
56

67

Diff for: backend/onyx/file_processing/file_validation.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
Centralized file type validation utilities.
33
"""
4+
45
# Standard image MIME types supported by most vision LLMs
56
IMAGE_MIME_TYPES = [
67
"image/png",

Diff for: backend/onyx/llm/override_models.py

+1
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
NOTE: these models are used in many places, so have to be
44
kepy in a separate file to avoid circular imports.
55
"""
6+
67
from pydantic import BaseModel
78

89

Diff for: backend/onyx/utils/error_handling.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
Standardized error handling utilities.
33
"""
4+
45
from onyx.configs.app_configs import CONTINUE_ON_CONNECTOR_FAILURE
56
from onyx.utils.logger import setup_logger
67

Diff for: backend/scripts/chat_loadtest.py

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
99
For more options, checkout the bottom of the file.
1010
"""
11+
1112
import argparse
1213
import asyncio
1314
import logging

Diff for: backend/scripts/debugging/onyx_vespa.py

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
python vespa_debug_tool.py --action list_docs --tenant-id my_tenant --connector-id 1 --n 5
2828
python vespa_debug_tool.py --action list_connector --tenant-id my_tenant --cc-pair-id 1 --n 5
2929
"""
30+
3031
import argparse
3132
import json
3233
from datetime import datetime

Diff for: backend/scripts/query_time_check/seed_dummy_docs.py

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
Run this script to seed the database with dummy documents.
99
Then run test_query_times.py to test query times.
1010
"""
11+
1112
import random
1213
from datetime import datetime
1314

Diff for: backend/scripts/query_time_check/test_query_times.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
RUN THIS AFTER SEED_DUMMY_DOCS.PY
33
"""
4+
45
import random
56
import time
67

Diff for: backend/tests/integration/connector_job_tests/slack/slack_api_utils.py

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- chat:write
99
- chat:write.public
1010
"""
11+
1112
from typing import Any
1213
from uuid import uuid4
1314

Diff for: backend/tests/integration/tests/connector/test_connector_deletion.py

+1
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
- updates the document sets and user groups to remove the connector
66
- Ensure that deleting a connector that is part of an overlapping document set and/or user group works as expected
77
"""
8+
89
import os
910
from uuid import uuid4
1011

Diff for: backend/tests/integration/tests/permissions/test_cc_pair_permissions.py

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
This file takes the happy path to adding a curator to a user group and then tests
33
the permissions of the curator manipulating connector-credential pairs.
44
"""
5+
56
import os
67

78
import pytest

Diff for: backend/tests/integration/tests/permissions/test_connector_permissions.py

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
This file takes the happy path to adding a curator to a user group and then tests
33
the permissions of the curator manipulating connectors.
44
"""
5+
56
import os
67

78
import pytest

Diff for: backend/tests/integration/tests/permissions/test_credential_permissions.py

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
This file takes the happy path to adding a curator to a user group and then tests
33
the permissions of the curator manipulating credentials.
44
"""
5+
56
import os
67

78
import pytest

Diff for: backend/tests/integration/tests/permissions/test_persona_permissions.py

+1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
- Curators can edit personas that belong exclusively to groups they curate
55
- Admins can edit all personas
66
"""
7+
78
import os
89

910
import pytest

Diff for: backend/tests/integration/tests/permissions/test_user_role_permissions.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
This file tests the ability of different user types to set the role of other users.
33
"""
4+
45
import os
56

67
import pytest

Diff for: backend/tests/integration/tests/permissions/test_whole_curator_flow.py

+1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
"""
22
This test tests the happy path for curator permissions
33
"""
4+
45
import os
56

67
import pytest

Diff for: backend/tests/integration/tests/usergroup/test_user_group_deletion.py

+1
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
- token_rate_limit (Not Implemented)
99
- persona
1010
"""
11+
1112
import os
1213

1314
import pytest

0 commit comments

Comments
 (0)