Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Skipping microbatch model fails with typeError: object of type 'Field' has no len() #11021

Closed
Tracked by #10624
MichelleArk opened this issue Nov 21, 2024 · 0 comments · Fixed by #11020
Closed
Tracked by #10624
Assignees
Labels
bug Something isn't working microbatch Issues related to the microbatch incremental strategy

Comments

@MichelleArk
Copy link
Contributor

MichelleArk commented Nov 21, 2024

An upstream failing leads to a microbatch model skipping (but still executing?) with the failure 'Field' has no len():

15:47:30  Found 23 models, 6 seeds, 21 data tests, 6 sources, 2 exposures, 13 metrics, 769 macros, 6 semantic models, 5 unit tests
15:47:30  
15:47:30  Concurrency: 4 threads (target='default')
15:47:30  
15:47:32  1 of 2 START sql view model dbt_marky.microbatch_input ......................... [RUN]
15:47:33  1 of 2 ERROR creating sql view model dbt_marky.microbatch_input ................ [ERROR in 0.69s]
15:47:33  2 of 2 SKIP relation dbt_marky.microbatch ...................................... [SKIP]
> /Users/michelleark/src/dbt-core/core/dbt/task/run.py(715)handle_microbatch_model()
-> while batch_idx < len(runner.batches):
(Pdb) runner.batches
Field(name=None,type=None,default=<dataclasses._MISSING_TYPE object at 0x100efa230>,default_factory=<class 'dict'>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=<dataclasses._MISSING_TYPE object at 0x100efa230>,_field_type=None)
(Pdb) field(default_factory=dict)
Field(name=None,type=None,default=<dataclasses._MISSING_TYPE object at 0x100efa230>,default_factory=<class 'dict'>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=<dataclasses._MISSING_TYPE object at 0x100efa230>,_field_type=None)
(Pdb) field(default_factory=dict)
Field(name=None,type=None,default=<dataclasses._MISSING_TYPE object at 0x100efa230>,default_factory=<class 'dict'>,init=True,repr=True,hash=None,compare=True,metadata=mappingproxy({}),kw_only=<dataclasses._MISSING_TYPE object at 0x100efa230>,_field_type=None)
(Pdb) len(field(default_factory=dict))
@MichelleArk MichelleArk added bug Something isn't working microbatch Issues related to the microbatch incremental strategy labels Nov 21, 2024
@MichelleArk MichelleArk self-assigned this Nov 21, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working microbatch Issues related to the microbatch incremental strategy
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant