Thanks to visit codestin.com
Credit goes to github.com

Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# dbt_github v0.5.0
# dbt_github v0.5.1
## Fixes
- The `url_link` logic within `int_github__issue_joined` was focused on only providing the correct url for pull requests. This update includes a `case when` statement to provide the accurate url logic for both Issues and Pull Requests. ([#31](https://github.com/fivetran/dbt_github/pull/31))

## Contributors
- [@jackiexsun](https://github.com/jackiexsun) ([#31](https://github.com/fivetran/dbt_github/pull/31))
# dbt_github v0.5.0
## 🚨 Breaking Changes 🚨
- The addition of the `label` source model results in the reference within `int_github__issue_label` to break. As a result, with the addition of upstream changes within `dbt_github_source` and the new `int_github__issue_label_join` model this issue has been resolved. ([#26](https://github.com/fivetran/dbt_github/pull/26))
- Please note: It is important you kick off a historical resync of your connector to account for the [connector changes](https://fivetran.com/docs/applications/github/changelog#april2021) from April 2021.
Expand Down
2 changes: 1 addition & 1 deletion dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
config-version: 2
name: 'github'
version: '0.5.0'
version: '0.5.1'
require-dbt-version: [">=1.0.0", "<2.0.0"]
models:
github:
Expand Down
2 changes: 1 addition & 1 deletion integration_tests/dbt_project.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'github_integration_tests'
version: '0.5.0'
version: '0.5.1'
config-version: 2

profile: 'integration_tests'
Expand Down
7 changes: 5 additions & 2 deletions models/intermediate/int_github__issue_joined.sql
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,10 @@ pull_request as (

select
issue.*,
{{ dbt_utils.concat(["'https://github.com/'",'repository_teams.repository',"'/pull/'", 'issue.issue_number']) }} as url_link,
case
when issue.is_pull_request then {{ dbt_utils.concat(["'https://github.com/'",'repository_teams.repository',"'/pull/'", 'issue.issue_number']) }}
else {{ dbt_utils.concat(["'https://github.com/'",'repository_teams.repository',"'/issues/'", 'issue.issue_number']) }}
end as url_link,
issue_open_length.days_issue_open,
issue_open_length.number_of_times_reopened,
labels.labels,
Expand Down Expand Up @@ -96,4 +99,4 @@ left join pull_request
left join pull_request_times
on issue.issue_id = pull_request_times.issue_id
left join pull_request_reviewers
on pull_request.pull_request_id = pull_request_reviewers.pull_request_id
on pull_request.pull_request_id = pull_request_reviewers.pull_request_id