Skip to content
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions backend/onyx/connectors/file/connector.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@
from onyx.file_store.file_store import get_default_file_store
from onyx.utils.logger import setup_logger


logger = setup_logger()


Expand Down Expand Up @@ -234,16 +235,14 @@ class LocalFileConnector(LoadConnector):
def __init__(
self,
file_locations: list[Path | str],
file_names: list[
str
], # Must accept this parameter as connector_specific_config is unpacked as args
zip_metadata: dict[str, Any],
file_names: list[str] | None = None,
zip_metadata: dict[str, Any] | None = None,
batch_size: int = INDEX_BATCH_SIZE,
) -> None:
self.file_locations = [str(loc) for loc in file_locations]
self.batch_size = batch_size
self.pdf_pass: str | None = None
self.zip_metadata = zip_metadata
self.zip_metadata = zip_metadata or {}

def load_credentials(self, credentials: dict[str, Any]) -> dict[str, Any] | None:
self.pdf_pass = credentials.get("pdf_password")
Expand Down Expand Up @@ -299,4 +298,4 @@ def load_from_state(self) -> GenerateDocumentsOutput:
connector.load_credentials({"pdf_password": os.environ.get("PDF_PASSWORD")})
doc_batches = connector.load_from_state()
for batch in doc_batches:
print("BATCH:", batch)
print("BATCH:", batch)
2 changes: 1 addition & 1 deletion deployment/helm/charts/onyx/Chart.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ home: https://www.onyx.app/
sources:
- "https://github.com/onyx-dot-app/onyx"
type: application
version: 0.2.5
version: 0.2.6
appVersion: latest
annotations:
category: Productivity
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ spec:
[
"celery",
"-A",
"onyx.background.celery.versioned_apps.docprocessing",
"onyx.background.celery.versioned_apps.docfetching",
"worker",
"--loglevel=INFO",
"--hostname=user-files-indexing@%n",
Expand Down
Loading