Skip to content

Commit

Permalink
Re-lint files
Browse files Browse the repository at this point in the history
  • Loading branch information
aditya-balachander committed Nov 19, 2024
1 parent 44fff95 commit db230ce
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 21 deletions.
6 changes: 3 additions & 3 deletions cumulusci/tasks/bulkdata/mapping_parser.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,9 @@ class MappingStep(CCIDictModel):
batch_size: int = None
oid_as_pk: bool = False # this one should be discussed and probably deprecated
record_type: Optional[str] = None # should be discussed and probably deprecated
bulk_mode: Optional[Literal["Serial", "Parallel"]] = (
None # default should come from task options
)
bulk_mode: Optional[
Literal["Serial", "Parallel"]
] = None # default should come from task options
anchor_date: Optional[Union[str, date]] = None
soql_filter: Optional[str] = None # soql_filter property
select_options: Optional[SelectOptions] = Field(
Expand Down
39 changes: 21 additions & 18 deletions cumulusci/tasks/bulkdata/step.py
Original file line number Diff line number Diff line change
Expand Up @@ -883,30 +883,33 @@ def select_records(self, records):
limit_clause = self._determine_limit_clause(total_num_records)

# Generate the SOQL query based on the selection strategy
select_query, query_fields = (
self.select_operation_executor.select_generate_query(
sobject=self.sobject,
fields=self.fields,
user_filter=self.selection_filter or None,
limit=limit_clause,
offset=None,
)
(
select_query,
query_fields,
) = self.select_operation_executor.select_generate_query(
sobject=self.sobject,
fields=self.fields,
user_filter=self.selection_filter or None,
limit=limit_clause,
offset=None,
)

# Execute the query and gather the records
query_records = self._execute_soql_query(select_query, query_fields)

# Post-process the query results for this batch
selected_records, insert_records, error_message = (
self.select_operation_executor.select_post_process(
load_records=records,
query_records=query_records,
fields=self.fields,
num_records=total_num_records,
sobject=self.sobject,
weights=self.weights,
threshold=self.threshold,
)
(
selected_records,
insert_records,
error_message,
) = self.select_operation_executor.select_post_process(
load_records=records,
query_records=query_records,
fields=self.fields,
num_records=total_num_records,
sobject=self.sobject,
weights=self.weights,
threshold=self.threshold,
)

# Log the number of selected and prepared for insertion records
Expand Down

0 comments on commit db230ce

Please sign in to comment.