Skip to content

Commit

Permalink
Merge pull request #2371 from TEAMSchools/2335-add-miami-fte-data-to-…
Browse files Browse the repository at this point in the history
…base_powerschool__student_enrollments

2335 add miami fte data to base powerschool  student enrollments
  • Loading branch information
cbini authored Jan 13, 2025
2 parents bb22b58 + 302d640 commit 5d932c8
Show file tree
Hide file tree
Showing 10 changed files with 142 additions and 251 deletions.
3 changes: 2 additions & 1 deletion .devcontainer/scripts/postCreate.sh
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@ sudo apt-get -y --no-install-recommends update &&
sudo rm -rf /var/lib/apt/lists/*

# auth gcloud
gcloud auth login --enable-gdrive-access --update-adc
gcloud auth activate-service-account \
--key-file=/etc/secret-volume/gcloud_service_account_json

# create env folder
mkdir -p ./env
Expand Down
4 changes: 0 additions & 4 deletions .github/workflows/dagster-cloud-deploy.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,6 @@ on:
code-location:
required: true
type: string
python-version:
type: string
required: false
default: 3.12

concurrency:
# Cancel in-progress deploys to the same branch
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
with
fte as (
select student_id, academic_year, survey_number, fte_capped,
from {{ ref("stg_fldoe__fte") }}
)

select student_id, academic_year, survey_1, survey_2, survey_3,
from
fte pivot (
max(fte_capped)
for survey_number in (1 as `survey_1`, 2 as `survey_2`, 3 as `survey_3`)
)
5 changes: 4 additions & 1 deletion src/dbt/kippmiami/models/fldoe/sources.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,10 @@ version: 2

sources:
- name: fldoe
schema: kippmiami_fldoe
schema: |
{% if env_var('DBT_DEV', '') == 'true' -%}z_dev_kippmiami_fldoe
{%- else -%}kippmiami_fldoe
{%- endif %}
tables:
- name: src_fldoe__fast
meta:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ with
source as (
{{
dbt_utils.union_relations(
relations=[source("kippmiami_fldoe", model.name)]
relations=[source("kippmiami_fldoe", "int_fldoe__all_assessments")]
)
}}
),
Expand Down
Original file line number Diff line number Diff line change
@@ -1 +1,7 @@
{{ dbt_utils.union_relations(relations=[source("kippmiami_fldoe", model.name)]) }}
{{
dbt_utils.union_relations(
relations=[
source("kippmiami_fldoe", "int_fldoe__fast_standard_performance_unpivot")
]
)
}}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{{
dbt_utils.union_relations(
relations=[source("kippmiami_fldoe", "int_fldoe__fte_pivot")]
)
}}
12 changes: 12 additions & 0 deletions src/dbt/kipptaf/models/fldoe/sources-kippmiami.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ version: 2

sources:
- name: kippmiami_fldoe
schema: |
{% if env_var('DBT_DEV', '') == 'true' -%}z_dev_kippmiami_fldoe
{%- else -%}kippmiami_fldoe
{%- endif %}
tables:
- name: stg_fldoe__fast
meta:
Expand Down Expand Up @@ -51,3 +55,11 @@ sources:
- kippmiami
- fldoe
- int_fldoe__all_assessments
- name: int_fldoe__fte_pivot
meta:
dagster:
group: fldoe
asset_key:
- kippmiami
- fldoe
- int_fldoe__fte_pivot
Loading

0 comments on commit 5d932c8

Please sign in to comment.