Skip to content

Commit

Permalink
make autoformat
Browse files Browse the repository at this point in the history
  • Loading branch information
artem-shelkovnikov committed Dec 25, 2024
1 parent eb75bac commit 30e46e7
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 7 deletions.
6 changes: 1 addition & 5 deletions connectors/protocol/connectors.py
Original file line number Diff line number Diff line change
Expand Up @@ -820,11 +820,7 @@ async def error(self, error):
await self.index.update(doc_id=self.id, doc=doc)

async def connected(self):
doc = {
"status": Status.CONNECTED.value,
"error": None

}
doc = {"status": Status.CONNECTED.value, "error": None}
await self.index.update(doc_id=self.id, doc=doc)

async def sync_done(self, job, cursor=None):
Expand Down
4 changes: 3 additions & 1 deletion connectors/services/job_scheduling.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,9 @@ async def _schedule(self, connector):
if connector.features.sync_rules_enabled():
await connector.validate_filtering(validator=data_source)

self.logger.info("Connector is configured correctly and can reach the data source")
self.logger.info(
"Connector is configured correctly and can reach the data source"
)
await connector.connected()
except Exception as e:
connector.log_error(e, exc_info=True)
Expand Down
4 changes: 3 additions & 1 deletion tests/services/test_job_scheduling.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,7 +403,9 @@ def _error_once():
data_source_mock.close = AsyncMock()

connector = mock_connector(next_sync=datetime.now(timezone.utc))
connector_index_mock.supported_connectors.return_value = AsyncIterator([connector], reusable=True)
connector_index_mock.supported_connectors.return_value = AsyncIterator(
[connector], reusable=True
)
await create_and_run_service(JobSchedulingService, stop_after=0.15)

data_source_mock.validate_config_fields.assert_called()
Expand Down

0 comments on commit 30e46e7

Please sign in to comment.