Skip to content

Commit

Permalink
more changelog fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
pedroslopez committed May 6, 2022
1 parent 4eefb71 commit 0229a5e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion docs/integrations/sources/exchangeratesapi.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,8 @@ If you have `free` subscription plan \(you may check it [here](https://manage.ex
|:--------| :--- | :--- | :--- |
| 0.2.6 | 2022-04-20 | [12230](https://github.com/airbytehq/airbyte/pull/12230) | Update connector to use a `spec.yaml` |
| 0.2.5 | 2021-11-12 | [7936](https://github.com/airbytehq/airbyte/pull/7936) | Add ignore_weekends boolean option |
| 0.2.3 | 2021-11-08 | [7499](https://github.com/airbytehq/airbyte/pull/7499) | Remove base-python dependencies |
| 0.2.4 | 2021-11-08 | [7499](https://github.com/airbytehq/airbyte/pull/7499) | Remove base-python dependencies |
| 0.2.3 | 2021-06-06 | [3973](https://github.com/airbytehq/airbyte/pull/3973) | Add `AIRBYTE_ENTRYPOINT` for kubernetes support |
| 0.2.2 | 2021-05-28 | [3677](https://github.com/airbytehq/airbyte/pull/3677) | Adding clearer error message when a currency isn't supported. access_key field in spec.json was marked as sensitive |
| 0.2.0 | 2021-05-26 | [3566](https://github.com/airbytehq/airbyte/pull/3566) | Move from `api.ratesapi.io/` to `api.exchangeratesapi.io/`. Add required field `access_key` to `config.json`. |
| 0.1.0 | 2021-04-19 | [2942](https://github.com/airbytehq/airbyte/pull/2942) | Implement Exchange API using the CDK |

3 comments on commit 0229a5e

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SonarQube Report

SonarQube report for Airbyte Connectors Source Google Sheets(#12685)

Measures

Name Value Name Value Name Value
Bugs 0 Coverage 63.4 Lines of Code 349
Code Smells 30 Reliability Rating A Duplicated Blocks 0
Lines to Cover 314 Duplicated Lines (%) 0.0 Security Rating A
Quality Gate Status OK Vulnerabilities 0 Blocker Issues 0
Critical Issues 1 Major Issues 5 Minor Issues 24

Detected Issues

Rule File Description Message
python:mypy_index (MINOR) google_sheets_source/google_sheets_source.py:45 Check indexing operations Value of type json? is not indexable . Code line: ... spreadsheet_id = Helpers.get_spreadsheet_id(config["spreadsheet_i...
python:mypy_index (MINOR) google_sheets_source/google_sheets_source.py:97 Check indexing operations Value of type json? is not indexable . Code line: ... spreadsheet_id = Helpers.get_spreadsheet_id(config["spreadsheet_i...
python:mypy_index (MINOR) google_sheets_source/google_sheets_source.py:127 Check indexing operations Value of type json? is not indexable . Code line: ... spreadsheet_id = Helpers.get_spreadsheet_id(config["spreadsheet_i...
python:mypy_return (MINOR) google_sheets_source/helpers.py:201 Check that function always returns a value Missing return statement . Code line: def get_spreadsheet_id(id_or_url: str) -> str:
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:205 Check that attribute exists in each item of a union Item "None" of "Optional[Match[str]]" has no attribute "group" . Code line: if m.group(2):
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:206 Check that attribute exists in each item of a union Item "None" of "Optional[Match[str]]" has no attribute "group" . Code line: return m.group(2)
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:164 Check that attribute exists in each item of a union Item "None" of "Optional[SheetProperties]" has no attribute "title" . Code line: return {sheet.properties.title: sheet.properties.gridPropertie...
python:mypy_misc (MINOR) google_sheets_source/helpers.py:164 Miscellaneous other checks Key expression in dictionary comprehension has incompatible type "Union[str, None, Any]"; expected type "str" . Code line: return {sheet.properties.title: sheet.properties.gridPropertie...
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:164 Check that attribute exists in each item of a union Item "SheetProperties" of "Optional[SheetProperties]" has no attribute "gridProperties" . Code line: return {sheet.properties.title: sheet.properties.gridPropertie...
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:164 Check that attribute exists in each item of a union Item "None" of "Optional[SheetProperties]" has no attribute "gridProperties" . Code line: return {sheet.properties.title: sheet.properties.gridPropertie...
python:mypy_syntax (MINOR) google_sheets_source/helpers.py:66 Report syntax errors Syntax error in type annotation . Code line: ..._and_duplicates(header_row_values: List[str]) -> (List[str], List[str]...
python:S3776 (CRITICAL) google_sheets_source/google_sheets_source.py:121 Cognitive Complexity of functions should not be too high Refactor this function to reduce its Cognitive Complexity from 17 to the 15 allowed.
python:mypy_import (MINOR) google_sheets_source/client.py:10 Require that imported module can be found or has stubs Library stubs not installed for "requests" (or incompatible with Python 3.9) . Code line: from requests import codes as status_codes
python:mypy_import (MINOR) google_sheets_source/google_sheets_source.py:20 Require that imported module can be found or has stubs Library stubs not installed for "requests.status_codes" (or incompatible with Python 3.9) . Code line: from requests.status_codes import codes as status_codes
python:mypy_valid_type (MINOR) google_sheets_source/google_sheets_source.py:38 Check that type (annotation) is valid Module "json" is not valid as a type . Code line: ... def check(self, logger: AirbyteLogger, config: json) -> AirbyteConne...
python:mypy_valid_type (MINOR) google_sheets_source/google_sheets_source.py:95 Check that type (annotation) is valid Module "json" is not valid as a type . Code line: ...ef discover(self, logger: AirbyteLogger, config: json) -> AirbyteCatal...
python:mypy_valid_type (MINOR) google_sheets_source/google_sheets_source.py:122 Check that type (annotation) is valid Module "json" is not valid as a type . Code line: self, logger: AirbyteLogger, config: json, catalog: Configured...
python:mypy_valid_type (MINOR) google_sheets_source/google_sheets_source.py:122 Check that type (annotation) is valid Function "builtins.any" is not valid as a type . Code line: ...config: json, catalog: ConfiguredAirbyteCatalog, state: Dict[str, any]
python:S112 (MAJOR) google_sheets_source/google_sheets_source.py:119 "Exception" and "BaseException" should not be raised Replace this generic exception class with a more specific one.
python:S5806 (MAJOR) google_sheets_source/google_sheets_source.py:143 Builtins should not be shadowed by local variables Rename this variable; it shadows a builtin.
python:mypy_misc (MINOR) google_sheets_source/helpers.py:90 Miscellaneous other checks List comprehension has incompatible type List[Union[str, None, Any]]; expected List[str] . Code line: return [value.formattedValue for value in row_data.values]
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:90 Check that attribute exists in each item of a union Item "None" of "Optional[List[CellData]]" has no attribute "iter" (not iterable) . Code line: return [value.formattedValue for value in row_data.values]
python:S112 (MAJOR) google_sheets_source/helpers.py:99 "Exception" and "BaseException" should not be raised Replace this generic exception class with a more specific one.
python:mypy_arg_type (MINOR) google_sheets_source/helpers.py:102 Check argument types in calls Argument 1 to "len" has incompatible type "Optional[List[GridData]]"; expected "Sized" . Code line: if len(range_data) != 1:
python:S112 (MAJOR) google_sheets_source/helpers.py:103 "Exception" and "BaseException" should not be raised Replace this generic exception class with a more specific one.
python:mypy_index (MINOR) google_sheets_source/helpers.py:105 Check indexing operations Value of type "Optional[List[GridData]]" is not indexable . Code line: all_row_data = range_data[0].rowData
python:S112 (MAJOR) google_sheets_source/helpers.py:107 "Exception" and "BaseException" should not be raised Replace this generic exception class with a more specific one.
python:mypy_var_annotated (MINOR) google_sheets_source/helpers.py:142 Require variable annotation if type can't be inferred Need type annotation for "available_sheets_to_column_index_to_name" . Code line: available_sheets_to_column_index_to_name = defaultdict(dict)
python:mypy_union_attr (MINOR) google_sheets_source/helpers.py:157 Check that attribute exists in each item of a union Item "None" of "Optional[SheetProperties]" has no attribute "title" . Code line: return [sheet.properties.title for sheet in spreadsheet_metada...
python:mypy_misc (MINOR) google_sheets_source/helpers.py:157 Miscellaneous other checks List comprehension has incompatible type List[Union[str, None, Any]]; expected List[str] . Code line: return [sheet.properties.title for sheet in spreadsheet_metada...

Coverage (63.4%)

File Coverage File Coverage
google_sheets_source/init.py 100.0 google_sheets_source/client.py 77.3
google_sheets_source/google_sheets_source.py 18.4 google_sheets_source/helpers.py 81.3
google_sheets_source/models/init.py 100.0 google_sheets_source/models/spreadsheet.py 100.0
google_sheets_source/models/spreadsheet_values.py 100.0

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SonarQube Report

SonarQube report for Airbyte Connectors Source Facebook Marketing(#12685)

Measures

Name Value Name Value Name Value
Lines of Code 1236 Bugs 0 Coverage 90.8
Security Rating A Vulnerabilities 0 Lines to Cover 855
Duplicated Blocks 0 Code Smells 108 Reliability Rating A
Quality Gate Status OK Duplicated Lines (%) 0.0 Blocker Issues 0
Critical Issues 2 Major Issues 0 Minor Issues 198

Detected Issues

Rule File Description Message
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:72 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:73 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:74 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:75 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:79 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:80 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:81 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:82 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:84 Check that attribute exists "Mapping[str, Any]" has no attribute "fetch_thumbnail_images" . Code line: ... AdCreatives(api=api, fetch_thumbnail_images=config.fetch_thumbnai...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:84 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: ...ail_images=config.fetch_thumbnail_images, page_size=config.page_size),
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:85 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsights(page_size=config.page_size, **insights_args),
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:86 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsAgeAndGender(page_size=config.page_size, **insi...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:87 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsCountry(page_size=config.page_size, **insights_...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:88 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsRegion(page_size=config.page_size, **insights_a...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:89 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsDma(page_size=config.page_size, **insights_args...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:90 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: ... AdsInsightsPlatformAndDevice(page_size=config.page_size, **i...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:91 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsActionType(page_size=config.page_size, **insigh...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:94 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:95 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:96 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:97 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:101 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:102 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:103 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:104 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:108 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:109 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:110 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:111 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:115 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:116 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:117 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:118 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:S3776 (CRITICAL) streams/async_job_manager.py:84 Cognitive Complexity of functions should not be too high Refactor this function to reduce its Cognitive Complexity from 22 to the 15 allowed.
python:mypy_import (MINOR) source_facebook_marketing/source.py:9 Require that imported module can be found or has stubs Library stubs not installed for "requests" (or incompatible with Python 3.9) . Code line: import requests
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:122 Check that attribute exists "Mapping[str, Any]" has no attribute "custom_insights" . Code line: ... return self._update_insights_streams(insights=config.custom_insight...
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:156 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidFields]]"; expected "Iterable[ValidFields]" . Code line: fields=list(set(insight.fields)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:156 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidFields]]"; expected "Iterable[Any]" . Code line: fields=list(set(insight.fields)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:157 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidBreakdowns]]"; expected "Iterable[ValidBreakdowns]" . Code line: breakdowns=list(set(insight.breakdowns)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:157 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidBreakdowns]]"; expected "Iterable[Any]" . Code line: breakdowns=list(set(insight.breakdowns)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:158 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidActionBreakdowns]]"; expected "Iterable[ValidActionBreakdowns]" . Code line: action_breakdowns=list(set(insight.action_breakdowns))...
python:mypy_attr_defined (MINOR) streams/base_streams.py:245 Check that attribute exists Module has no attribute "parse" . Code line: record_cursor_value = pendulum.parse(record[self.cursor_fi...
python:mypy_assignment (MINOR) streams/streams.py:101 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "activity"
python:mypy_assignment (MINOR) streams/streams.py:103 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "None", base class "FBMarketingStream" defined the type as "str") . Code line: primary_key = None
python:mypy_override (MINOR) streams/streams.py:105 Check that method override is compatible with base class Signature of "list_objects" incompatible with supertype "FBMarketingStream" . Code line: def list_objects(self, fields: List[str], params: Mapping[str, Any...
python:mypy_no_any_return (MINOR) streams/streams.py:106 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_activities(fields=fields, params=...
python:mypy_arg_type (MINOR) streams/streams.py:116 Check argument types in calls Argument "stream_state" to "request_params" of "FBMarketingIncrementalStream" has incompatible type "Optional[Mapping[str, Any]]"; expected "Mapping[str, Any]" . Code line: ...ds=self.fields, params=self.request_params(stream_state=stream_state))
python:mypy_attr_defined (MINOR) streams/streams.py:127 Check that attribute exists Module has no attribute "parse" . Code line: ...since = self.start_date if not state_value else pendulum.parse(state...
python:mypy_no_redef (MINOR) streams/base_streams.py:75 Check that each name is defined once Name "api_batch" already defined on line 68 . Code line: api_batch: FacebookAdsApiBatch = self._api.api.new_bat...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:45 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: if pendulum.instance(config.end_date) < pendulum.instance(conf...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:45 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: ...ulum.instance(config.end_date) < pendulum.instance(config.start_date):
python:mypy_no_redef (MINOR) source_facebook_marketing/source.py:60 Check that each name is defined once Name "config" already defined on line 54 . Code line: config: ConnectorConfig = ConnectorConfig.parse_obj(config)
python:mypy_misc (MINOR) source_facebook_marketing/spec.py:18 Miscellaneous other checks Enum() expects a string, tuple, list or dict literal as the second argument . Code line: ValidFields = Enum("ValidEnums", AdsInsights.Field.dict)
python:mypy_misc (MINOR) source_facebook_marketing/spec.py:19 Miscellaneous other checks Enum() expects a string, tuple, list or dict literal as the second argument . Code line: ValidBreakdowns = Enum("ValidBreakdowns", AdsInsights.Breakdowns.__dic...
python:mypy_name_defined (MINOR) source_facebook_marketing/spec.py:20 Check that name is defined Enum() expects a string, tuple, list or dict literal as the second argument [misc] ValidActionBreakdowns = Enum("ValidActionBreakdowns", AdsInsights.Acti...
python:mypy_attr_defined (MINOR) streams/init.py:5 Check that attribute exists Module "source_facebook_marketing.streams.streams" does not explicitly export attribute "AdsInsights"; implicit reexport disabled . Code line: from .streams import (
python:mypy_arg_type (MINOR) streams/async_job.py:149 Check argument types in calls Argument "jobs" to "update_in_batch" has incompatible type "List[InsightAsyncJob]"; expected "List[AsyncJob]" . Code line: update_in_batch(api=self._api, jobs=self._jobs)
python:mypy_return_value (MINOR) streams/async_job.py:242 Check that return value is compatible with signature Incompatible return value type (got "List[InsightAsyncJob]", expected "List[AsyncJob]") . Code line: return jobs
python:mypy_unreachable (MINOR) streams/async_job.py:272 Warn about unreachable statements or expressions Statement is unreachable . Code line: end_time = self._finish_time or pendulum.now()
python:mypy_index (MINOR) streams/async_job.py:321 Check indexing operations Value of type "Optional[Any]" is not indexable . Code line: job_status = self._job["async_status"]
python:mypy_index (MINOR) streams/async_job.py:322 Check indexing operations Value of type "Optional[Any]" is not indexable . Code line: percent = self._job["async_percent_completion"]
python:mypy_operator (MINOR) streams/async_job.py:325 Check that operator is valid for operands Unsupported operand types for < ("Duration" and "None") . Code line: if self.elapsed_time > self.job_timeout:
python:mypy_assignment (MINOR) streams/async_job.py:327 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now()
python:mypy_assignment (MINOR) streams/async_job.py:331 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now() # TODO: is not actual ...
python:mypy_assignment (MINOR) streams/async_job.py:334 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now()
python:mypy_attr_defined (MINOR) streams/async_job.py:336 Check that attribute exists "None" has no attribute "in_seconds" . Code line: ...er.info(f"{self}: has status {job_status} after {self.elapsed_time.in_...
python:mypy_var_annotated (MINOR) streams/async_job_manager.py:43 Require variable annotation if type can't be inferred Need type annotation for "_running_jobs" (hint: "_running_jobs: List[] = ...") . Code line: self._running_jobs = []
python:mypy_no_any_return (MINOR) streams/async_job_manager.py:142 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "float" . Code line: return min(throttle.per_account, throttle.per_application)
python:mypy_name_defined (MINOR) streams/base_insight_streams.py:58 Check that name is defined Need type annotation for "breakdowns" (hint: "breakdowns: List[] = ...") [var-annotated] breakdowns = []
python:mypy_var_annotated (MINOR) streams/base_insight_streams.py:81 Require variable annotation if type can't be inferred Need type annotation for "_completed_slices" (hint: "_completed_slices: Set[] = ...") . Code line: self._completed_slices = set()
python:mypy_no_any_return (MINOR) streams/base_insight_streams.py:87 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "str" . Code line: return casing.camel_to_snake(name)
python:mypy_override (MINOR) streams/base_insight_streams.py:90 Check that method override is compatible with base class Signature of "primary_key" incompatible with supertype "FBMarketingStream" . Code line: def primary_key(self) -> Optional[Union[str, List[str], List[List[...
python:mypy_index (MINOR) streams/base_insight_streams.py:105 Check indexing operations Value of type "Optional[Mapping[str, Any]]" is not indexable . Code line: job = stream_slice["insight_job"]
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:141 Check that attribute exists Module has no attribute "parse" . Code line: self._cursor_value = pendulum.parse(value[self.cursor_field])....
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:142 Check that attribute exists Module has no attribute "parse" . Code line: self._completed_slices = set(pendulum.parse(v).date() for v in...
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:180 Check that attribute exists Module has no attribute "Period"; maybe "period"? . Code line: interval = pendulum.Period(ts_start, ts_end)
python:mypy_name_defined (MINOR) streams/base_insight_streams.py:200 Check that name is defined Incompatible types in assignment (expression has type "Mapping[str, Any]", variable has type "MutableMapping[str, Any]") [assignment] self.state = stream_state
python:mypy_override (MINOR) streams/base_insight_streams.py:240 Check that method override is compatible with base class Signature of "request_params" incompatible with supertype "FBMarketingIncrementalStream" . Code line: def request_params(self, **kwargs) -> MutableMapping[str, Any]:
python:mypy_no_any_return (MINOR) streams/base_insight_streams.py:265 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Mapping[str, Any]" . Code line: return schema
python:mypy_assignment (MINOR) streams/base_streams.py:91 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "Iterable[MutableMapping[str, Any]]", variable has type "Generator[Any, None, None]") . Code line: loaded_records_iter = self.execute_in_batch(loaded_records...
python:mypy_attr_defined (MINOR) streams/base_streams.py:160 Check that attribute exists Module has no attribute "parse" . Code line: max_cursor = max(pendulum.parse(state_value), pendulum.parse(r...
python:mypy_override (MINOR) streams/base_streams.py:169 Check that method override is compatible with base class Signature of "request_params" incompatible with supertype "FBMarketingStream" . Code line: def request_params(self, stream_state: Mapping[str, Any], **kwargs...
python:mypy_attr_defined (MINOR) streams/base_streams.py:178 Check that attribute exists Module has no attribute "parse" . Code line: ...value = self.start_date if not state_value else pendulum.parse(state...
python:mypy_attr_defined (MINOR) streams/base_streams.py:224 Check that attribute exists Module has no attribute "parse" . Code line: self._cursor_value = pendulum.parse(value[self.cursor_field])
python:mypy_arg_type (MINOR) streams/base_streams.py:243 Check argument types in calls Argument "stream_state" to "request_params" of "FBMarketingIncrementalStream" has incompatible type "Optional[Mapping[str, Any]]"; expected "Mapping[str, Any]" . Code line: ...lf.list_objects(params=self.request_params(stream_state=stream_state))
python:mypy_import (MINOR) streams/streams.py:10 Require that imported module can be found or has stubs Library stubs not installed for "requests" (or incompatible with Python 3.9) . Code line: import requests
python:mypy_assignment (MINOR) streams/streams.py:42 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "adcreative"
python:mypy_index (MINOR) streams/streams.py:64 Check indexing operations Unsupported target for indexed assignment ("Mapping[str, Any]") . Code line: record["thumbnail_data_url"] = fetch_thumbnail_data_ur...
python:mypy_arg_type (MINOR) streams/streams.py:64 Check argument types in calls Argument 1 to "fetch_thumbnail_data_url" has incompatible type "Optional[Any]"; expected "str" . Code line: ..."thumbnail_data_url"] = fetch_thumbnail_data_url(record.get("thumbnail...
python:mypy_no_any_return (MINOR) streams/streams.py:68 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_creatives(params=params)
python:mypy_assignment (MINOR) streams/streams.py:74 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "ad"
python:mypy_no_any_return (MINOR) streams/streams.py:77 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ads(params=params)
python:mypy_assignment (MINOR) streams/streams.py:83 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "adset"
python:mypy_no_any_return (MINOR) streams/streams.py:86 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_sets(params=params)
python:mypy_assignment (MINOR) streams/streams.py:92 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "campaign"
python:mypy_no_any_return (MINOR) streams/streams.py:95 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_campaigns(params=params)
python:mypy_assignment (MINOR) streams/streams.py:140 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "video"
python:mypy_no_any_return (MINOR) streams/streams.py:143 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_videos(params=params)
python:mypy_no_any_return (MINOR) streams/streams.py:161 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_images(params=params, fields=s...
python:mypy_var_annotated (MINOR) streams/streams.py:188 Require variable annotation if type can't be inferred Need type annotation for "breakdowns" (hint: "breakdowns: List[] = ...") . Code line: breakdowns = []
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:72 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:73 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:74 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:75 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:79 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:80 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:81 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:82 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:84 Check that attribute exists "Mapping[str, Any]" has no attribute "fetch_thumbnail_images" . Code line: ... AdCreatives(api=api, fetch_thumbnail_images=config.fetch_thumbnai...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:84 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: ...ail_images=config.fetch_thumbnail_images, page_size=config.page_size),
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:85 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsights(page_size=config.page_size, **insights_args),
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:86 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsAgeAndGender(page_size=config.page_size, **insi...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:87 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsCountry(page_size=config.page_size, **insights_...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:88 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsRegion(page_size=config.page_size, **insights_a...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:89 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsDma(page_size=config.page_size, **insights_args...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:90 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: ... AdsInsightsPlatformAndDevice(page_size=config.page_size, **i...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:91 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: AdsInsightsActionType(page_size=config.page_size, **insigh...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:94 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:95 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:96 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:97 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:101 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:102 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:103 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:104 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:108 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:109 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:110 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:111 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:115 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: start_date=config.start_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:116 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: end_date=config.end_date,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:117 Check that attribute exists "Mapping[str, Any]" has no attribute "include_deleted" . Code line: include_deleted=config.include_deleted,
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:118 Check that attribute exists "Mapping[str, Any]" has no attribute "page_size" . Code line: page_size=config.page_size,
python:S3776 (CRITICAL) streams/async_job_manager.py:84 Cognitive Complexity of functions should not be too high Refactor this function to reduce its Cognitive Complexity from 22 to the 15 allowed.
python:mypy_import (MINOR) source_facebook_marketing/source.py:9 Require that imported module can be found or has stubs Library stubs not installed for "requests" (or incompatible with Python 3.9) . Code line: import requests
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:122 Check that attribute exists "Mapping[str, Any]" has no attribute "custom_insights" . Code line: ... return self._update_insights_streams(insights=config.custom_insight...
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:156 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidFields]]"; expected "Iterable[ValidFields]" . Code line: fields=list(set(insight.fields)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:156 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidFields]]"; expected "Iterable[Any]" . Code line: fields=list(set(insight.fields)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:157 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidBreakdowns]]"; expected "Iterable[ValidBreakdowns]" . Code line: breakdowns=list(set(insight.breakdowns)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:157 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidBreakdowns]]"; expected "Iterable[Any]" . Code line: breakdowns=list(set(insight.breakdowns)),
python:mypy_arg_type (MINOR) source_facebook_marketing/source.py:158 Check argument types in calls Argument 1 to "set" has incompatible type "Optional[List[ValidActionBreakdowns]]"; expected "Iterable[ValidActionBreakdowns]" . Code line: action_breakdowns=list(set(insight.action_breakdowns))...
python:mypy_attr_defined (MINOR) streams/base_streams.py:245 Check that attribute exists Module has no attribute "parse" . Code line: record_cursor_value = pendulum.parse(record[self.cursor_fi...
python:mypy_assignment (MINOR) streams/streams.py:101 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "activity"
python:mypy_assignment (MINOR) streams/streams.py:103 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "None", base class "FBMarketingStream" defined the type as "str") . Code line: primary_key = None
python:mypy_override (MINOR) streams/streams.py:105 Check that method override is compatible with base class Signature of "list_objects" incompatible with supertype "FBMarketingStream" . Code line: def list_objects(self, fields: List[str], params: Mapping[str, Any...
python:mypy_no_any_return (MINOR) streams/streams.py:106 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_activities(fields=fields, params=...
python:mypy_arg_type (MINOR) streams/streams.py:116 Check argument types in calls Argument "stream_state" to "request_params" of "FBMarketingIncrementalStream" has incompatible type "Optional[Mapping[str, Any]]"; expected "Mapping[str, Any]" . Code line: ...ds=self.fields, params=self.request_params(stream_state=stream_state))
python:mypy_attr_defined (MINOR) streams/streams.py:127 Check that attribute exists Module has no attribute "parse" . Code line: ...since = self.start_date if not state_value else pendulum.parse(state...
python:mypy_no_redef (MINOR) streams/base_streams.py:75 Check that each name is defined once Name "api_batch" already defined on line 68 . Code line: api_batch: FacebookAdsApiBatch = self._api.api.new_bat...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:45 Check that attribute exists "Mapping[str, Any]" has no attribute "end_date" . Code line: if pendulum.instance(config.end_date) < pendulum.instance(conf...
python:mypy_attr_defined (MINOR) source_facebook_marketing/source.py:45 Check that attribute exists "Mapping[str, Any]" has no attribute "start_date" . Code line: ...ulum.instance(config.end_date) < pendulum.instance(config.start_date):
python:mypy_no_redef (MINOR) source_facebook_marketing/source.py:60 Check that each name is defined once Name "config" already defined on line 54 . Code line: config: ConnectorConfig = ConnectorConfig.parse_obj(config)
python:mypy_misc (MINOR) source_facebook_marketing/spec.py:18 Miscellaneous other checks Enum() expects a string, tuple, list or dict literal as the second argument . Code line: ValidFields = Enum("ValidEnums", AdsInsights.Field.dict)
python:mypy_misc (MINOR) source_facebook_marketing/spec.py:19 Miscellaneous other checks Enum() expects a string, tuple, list or dict literal as the second argument . Code line: ValidBreakdowns = Enum("ValidBreakdowns", AdsInsights.Breakdowns.__dic...
python:mypy_name_defined (MINOR) source_facebook_marketing/spec.py:20 Check that name is defined Enum() expects a string, tuple, list or dict literal as the second argument [misc] ValidActionBreakdowns = Enum("ValidActionBreakdowns", AdsInsights.Acti...
python:mypy_attr_defined (MINOR) streams/init.py:5 Check that attribute exists Module "source_facebook_marketing.streams.streams" does not explicitly export attribute "AdsInsights"; implicit reexport disabled . Code line: from .streams import (
python:mypy_arg_type (MINOR) streams/async_job.py:149 Check argument types in calls Argument "jobs" to "update_in_batch" has incompatible type "List[InsightAsyncJob]"; expected "List[AsyncJob]" . Code line: update_in_batch(api=self._api, jobs=self._jobs)
python:mypy_return_value (MINOR) streams/async_job.py:242 Check that return value is compatible with signature Incompatible return value type (got "List[InsightAsyncJob]", expected "List[AsyncJob]") . Code line: return jobs
python:mypy_unreachable (MINOR) streams/async_job.py:272 Warn about unreachable statements or expressions Statement is unreachable . Code line: end_time = self._finish_time or pendulum.now()
python:mypy_index (MINOR) streams/async_job.py:321 Check indexing operations Value of type "Optional[Any]" is not indexable . Code line: job_status = self._job["async_status"]
python:mypy_index (MINOR) streams/async_job.py:322 Check indexing operations Value of type "Optional[Any]" is not indexable . Code line: percent = self._job["async_percent_completion"]
python:mypy_operator (MINOR) streams/async_job.py:325 Check that operator is valid for operands Unsupported operand types for < ("Duration" and "None") . Code line: if self.elapsed_time > self.job_timeout:
python:mypy_assignment (MINOR) streams/async_job.py:327 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now()
python:mypy_assignment (MINOR) streams/async_job.py:331 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now() # TODO: is not actual ...
python:mypy_assignment (MINOR) streams/async_job.py:334 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "DateTime", variable has type "None") . Code line: self._finish_time = pendulum.now()
python:mypy_attr_defined (MINOR) streams/async_job.py:336 Check that attribute exists "None" has no attribute "in_seconds" . Code line: ...er.info(f"{self}: has status {job_status} after {self.elapsed_time.in_...
python:mypy_var_annotated (MINOR) streams/async_job_manager.py:43 Require variable annotation if type can't be inferred Need type annotation for "_running_jobs" (hint: "_running_jobs: List[] = ...") . Code line: self._running_jobs = []
python:mypy_no_any_return (MINOR) streams/async_job_manager.py:142 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "float" . Code line: return min(throttle.per_account, throttle.per_application)
python:mypy_name_defined (MINOR) streams/base_insight_streams.py:58 Check that name is defined Need type annotation for "breakdowns" (hint: "breakdowns: List[] = ...") [var-annotated] breakdowns = []
python:mypy_var_annotated (MINOR) streams/base_insight_streams.py:81 Require variable annotation if type can't be inferred Need type annotation for "_completed_slices" (hint: "_completed_slices: Set[] = ...") . Code line: self._completed_slices = set()
python:mypy_no_any_return (MINOR) streams/base_insight_streams.py:87 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "str" . Code line: return casing.camel_to_snake(name)
python:mypy_override (MINOR) streams/base_insight_streams.py:90 Check that method override is compatible with base class Signature of "primary_key" incompatible with supertype "FBMarketingStream" . Code line: def primary_key(self) -> Optional[Union[str, List[str], List[List[...
python:mypy_index (MINOR) streams/base_insight_streams.py:105 Check indexing operations Value of type "Optional[Mapping[str, Any]]" is not indexable . Code line: job = stream_slice["insight_job"]
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:141 Check that attribute exists Module has no attribute "parse" . Code line: self._cursor_value = pendulum.parse(value[self.cursor_field])....
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:142 Check that attribute exists Module has no attribute "parse" . Code line: self._completed_slices = set(pendulum.parse(v).date() for v in...
python:mypy_attr_defined (MINOR) streams/base_insight_streams.py:180 Check that attribute exists Module has no attribute "Period"; maybe "period"? . Code line: interval = pendulum.Period(ts_start, ts_end)
python:mypy_name_defined (MINOR) streams/base_insight_streams.py:200 Check that name is defined Incompatible types in assignment (expression has type "Mapping[str, Any]", variable has type "MutableMapping[str, Any]") [assignment] self.state = stream_state
python:mypy_override (MINOR) streams/base_insight_streams.py:240 Check that method override is compatible with base class Signature of "request_params" incompatible with supertype "FBMarketingIncrementalStream" . Code line: def request_params(self, **kwargs) -> MutableMapping[str, Any]:
python:mypy_no_any_return (MINOR) streams/base_insight_streams.py:265 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Mapping[str, Any]" . Code line: return schema
python:mypy_assignment (MINOR) streams/base_streams.py:91 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "Iterable[MutableMapping[str, Any]]", variable has type "Generator[Any, None, None]") . Code line: loaded_records_iter = self.execute_in_batch(loaded_records...
python:mypy_attr_defined (MINOR) streams/base_streams.py:160 Check that attribute exists Module has no attribute "parse" . Code line: max_cursor = max(pendulum.parse(state_value), pendulum.parse(r...
python:mypy_override (MINOR) streams/base_streams.py:169 Check that method override is compatible with base class Signature of "request_params" incompatible with supertype "FBMarketingStream" . Code line: def request_params(self, stream_state: Mapping[str, Any], **kwargs...
python:mypy_attr_defined (MINOR) streams/base_streams.py:178 Check that attribute exists Module has no attribute "parse" . Code line: ...value = self.start_date if not state_value else pendulum.parse(state...
python:mypy_attr_defined (MINOR) streams/base_streams.py:224 Check that attribute exists Module has no attribute "parse" . Code line: self._cursor_value = pendulum.parse(value[self.cursor_field])
python:mypy_arg_type (MINOR) streams/base_streams.py:243 Check argument types in calls Argument "stream_state" to "request_params" of "FBMarketingIncrementalStream" has incompatible type "Optional[Mapping[str, Any]]"; expected "Mapping[str, Any]" . Code line: ...lf.list_objects(params=self.request_params(stream_state=stream_state))
python:mypy_import (MINOR) streams/streams.py:10 Require that imported module can be found or has stubs Library stubs not installed for "requests" (or incompatible with Python 3.9) . Code line: import requests
python:mypy_assignment (MINOR) streams/streams.py:42 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "adcreative"
python:mypy_index (MINOR) streams/streams.py:64 Check indexing operations Unsupported target for indexed assignment ("Mapping[str, Any]") . Code line: record["thumbnail_data_url"] = fetch_thumbnail_data_ur...
python:mypy_arg_type (MINOR) streams/streams.py:64 Check argument types in calls Argument 1 to "fetch_thumbnail_data_url" has incompatible type "Optional[Any]"; expected "str" . Code line: ..."thumbnail_data_url"] = fetch_thumbnail_data_url(record.get("thumbnail...
python:mypy_no_any_return (MINOR) streams/streams.py:68 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_creatives(params=params)
python:mypy_assignment (MINOR) streams/streams.py:74 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "ad"
python:mypy_no_any_return (MINOR) streams/streams.py:77 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ads(params=params)
python:mypy_assignment (MINOR) streams/streams.py:83 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "adset"
python:mypy_no_any_return (MINOR) streams/streams.py:86 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_sets(params=params)
python:mypy_assignment (MINOR) streams/streams.py:92 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "campaign"
python:mypy_no_any_return (MINOR) streams/streams.py:95 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_campaigns(params=params)
python:mypy_assignment (MINOR) streams/streams.py:140 Check that assigned value is compatible with target Incompatible types in assignment (expression has type "str", base class "FBMarketingStream" defined the type as "None") . Code line: entity_prefix = "video"
python:mypy_no_any_return (MINOR) streams/streams.py:143 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_videos(params=params)
python:mypy_no_any_return (MINOR) streams/streams.py:161 Reject returning value with "Any" type if return type is not "Any" Returning Any from function declared to return "Iterable[Any]" . Code line: return self._api.account.get_ad_images(params=params, fields=s...
python:mypy_var_annotated (MINOR) streams/streams.py:188 Require variable annotation if type can't be inferred Need type annotation for "breakdowns" (hint: "breakdowns: List[] = ...") . Code line: breakdowns = []

Coverage (90.8%)

File Coverage File Coverage
source_facebook_marketing/init.py 100.0 source_facebook_marketing/api.py 90.6
source_facebook_marketing/source.py 97.4 source_facebook_marketing/spec.py 100.0
source_facebook_marketing/streams/init.py 100.0 source_facebook_marketing/streams/async_job.py 100.0
source_facebook_marketing/streams/async_job_manager.py 96.2 source_facebook_marketing/streams/base_insight_streams.py 89.9
source_facebook_marketing/streams/base_streams.py 76.4 source_facebook_marketing/streams/common.py 97.6
source_facebook_marketing/streams/streams.py 77.3

@github-actions
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

SonarQube Report

SonarQube report for Airbyte Connectors Source Salesforce(#12685)

Measures

Name Value Name Value Name Value
Lines of Code 880 Vulnerabilities 0 Quality Gate Status OK
Lines to Cover 573 Security Rating A Reliability Rating A
Bugs 0 Duplicated Blocks 0 Code Smells 5
Duplicated Lines (%) 0.0 Coverage 88.3 Blocker Issues 0
Critical Issues 0 Major Issues 0 Minor Issues 5

Detected Issues

Rule File Description Message
python:mypy_arg_type (MINOR) source_salesforce/streams.py:311 Check argument types in calls Argument 1 to "open" has incompatible type "Optional[str]"; expected "Union[Union[str, bytes, PathLike[str], PathLike[bytes]], int]" . Code line: with open(path, "r", encoding=self.encoding) as data:
python:mypy_return_value (MINOR) source_salesforce/streams.py:300 Check that return value is compatible with signature Incompatible return value type (got "str", expected "PathLike[Any]") . Code line: return tmp_file
python:mypy_arg_type (MINOR) source_salesforce/streams.py:321 Check argument types in calls Argument 2 to "TmpFileIOError" has incompatible type "OSError"; expected "Optional[str]" . Code line: ...red while reading tmp data. Called: {path}. Stream: {self.name}", ioe)
python:mypy_arg_type (MINOR) source_salesforce/streams.py:324 Check argument types in calls Argument 1 to "remove" has incompatible type "Optional[str]"; expected "Union[str, bytes, PathLike[str], PathLike[bytes]]" . Code line: os.remove(path)
python:mypy_arg_type (MINOR) source_salesforce/streams.py:385 Check argument types in calls Argument 1 to "read_with_chunks" of "BulkSalesforceStream" has incompatible type "PathLike[Any]"; expected "Optional[str]" . Code line: ... for count, record in self.read_with_chunks(self.download_data(ur...

Coverage (88.3%)

File Coverage File Coverage
source_salesforce/init.py 100.0 source_salesforce/api.py 90.7
source_salesforce/exceptions.py 87.5 source_salesforce/rate_limiting.py 86.4
source_salesforce/source.py 92.2 source_salesforce/streams.py 85.9
source_salesforce/utils.py 100.0

Please sign in to comment.