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

[CT-1711] [Bug] Materialization "materialization_table_trino" only supports languages ['sql']; got "python" in dbt-core 1.3.0 and 1.3.1 #6476

Closed
2 tasks done
curiosityCursed opened this issue Dec 22, 2022 · 2 comments
Labels
bug Something isn't working wontfix Not a bug or out of scope for dbt-core

Comments

@curiosityCursed
Copy link

Is this a new bug in dbt-core?

  • I believe this is a new bug in dbt-core
  • I have searched the existing issues, and I could not find an existing issue for this bug

Current Behavior

def model(dbt,session):
df = dbt.ref('')
return df

07:58:55 Completed with 1 error and 0 warnings:
07:58:55
07:58:55 Runtime Error in model (models/./././.py)
07:58:55 Materialization "materialization_table_trino" only supports languages ['sql']; got "python"

Expected Behavior

def model(dbt,session):
df = dbt.ref('<view_model>')
return df

Should be able to create python model referencing the view model.

Steps To Reproduce

  1. Create a new view model under models/. folder.
  2. Create a python model which references the above view.
  3. dbt run --select <view_model> <python_model>

Relevant log output

07:58:55  Finished running 2 view models, 1 table model in 0 hours 0 minutes and 2.80 seconds (2.80s).
07:58:55  
07:58:55  Completed with 1 error and 0 warnings:
07:58:55  
07:58:55  Runtime Error in model <model> (models/./././<model>.py)
07:58:55    Materialization "materialization_table_trino" only supports languages ['sql']; got "python"
07:58:55  
07:58:55  Done. PASS=2 WARN=0 ERROR=1 SKIP=0 TOTAL=3

Environment

- OS:macOS Monterey 12.6
- Python: 3.96
- dbt: 1.3.0

Which database adapter are you using with dbt?

other (mention it in "Additional Context")

Additional Context

Trino

@curiosityCursed curiosityCursed added bug Something isn't working triage labels Dec 22, 2022
@github-actions github-actions bot changed the title [Bug] Materialization "materialization_table_trino" only supports languages ['sql']; got "python" in dbt-core 1.3.0 and 1.3.1 [CT-1711] [Bug] Materialization "materialization_table_trino" only supports languages ['sql']; got "python" in dbt-core 1.3.0 and 1.3.1 Dec 22, 2022
@dbeatty10
Copy link
Contributor

Thank you for reaching out about this @curiosityCursed !

In their initial launch, Python models are supported on three of the most popular data platforms: Snowflake, Databricks, and BigQuery/GCP (via Dataproc) [1]

I think the reason you are getting this error is that dbt-trino doesn't currently support dbt Python models.

Although we can't help you directly, here's a couple options for you:

  1. Open a feature request at dbt-trino
  2. Take a look at https://fal.ai/

I'm closing this in favor of the options above, but please reach out again with any bug reports or feature requests!

@dbeatty10 dbeatty10 closed this as not planned Won't fix, can't repro, duplicate, stale Dec 22, 2022
@dbeatty10 dbeatty10 added wontfix Not a bug or out of scope for dbt-core and removed triage labels Dec 22, 2022
@curiosityCursed
Copy link
Author

@dbeatty10 Thanks for quick response.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working wontfix Not a bug or out of scope for dbt-core
Projects
None yet
Development

No branches or pull requests

2 participants