mirror of
https://github.com/dbt-labs/dbt-core
synced 2025-12-18 20:01:28 +00:00
Compare commits
104 Commits
v1.6.0b3
...
jerco/upda
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
2c8856da3b | ||
|
|
029045e556 | ||
|
|
433e5c670e | ||
|
|
cbfc6a8baf | ||
|
|
9765596247 | ||
|
|
1b1a291fae | ||
|
|
867534c1f4 | ||
|
|
6d8b6459eb | ||
|
|
203bd8defd | ||
|
|
949680a5ce | ||
|
|
015c490b63 | ||
|
|
95a916936e | ||
|
|
961d69d8c2 | ||
|
|
be4d0a5b88 | ||
|
|
5310d3715c | ||
|
|
6bdf983e0b | ||
|
|
6604b9ca31 | ||
|
|
305241fe86 | ||
|
|
2d686b73fd | ||
|
|
30def98ed9 | ||
|
|
b78d23f68d | ||
|
|
4ffd633e40 | ||
|
|
07c3dcd21c | ||
|
|
fd233eac62 | ||
|
|
d8f38ca48b | ||
|
|
7740bd6b45 | ||
|
|
a57fdf008e | ||
|
|
a8e3afe8af | ||
|
|
44572e72f0 | ||
|
|
54b1e5699c | ||
|
|
ee7bc24903 | ||
|
|
15ef88d2ed | ||
|
|
7c56d72b46 | ||
|
|
5d28e4744e | ||
|
|
746ca7d149 | ||
|
|
a58b5ee8fb | ||
|
|
7fbfd53c3e | ||
|
|
4c44c29ee4 | ||
|
|
8ee0fe0a64 | ||
|
|
307a618ea8 | ||
|
|
ce07ce58e1 | ||
|
|
7ea51df6ae | ||
|
|
fe463c79fe | ||
|
|
d7d6843c5f | ||
|
|
adcf8bcbb3 | ||
|
|
5d937802f1 | ||
|
|
8c201e88a7 | ||
|
|
b8bc264731 | ||
|
|
9c6fbff0c3 | ||
|
|
5c7aa7f9ce | ||
|
|
1af94dedad | ||
|
|
2e7c968419 | ||
|
|
05b0820a9e | ||
|
|
d4e620eb50 | ||
|
|
0f52505dbe | ||
|
|
cb754fd97b | ||
|
|
e01d4c0a6e | ||
|
|
7a6bedaae3 | ||
|
|
22145e7e5f | ||
|
|
b3ac41ff9a | ||
|
|
036b95e5b2 | ||
|
|
2ce0c5ccf5 | ||
|
|
7156cc5c1d | ||
|
|
fcd30b1de2 | ||
|
|
a84fa50166 | ||
|
|
6a1e3a6db8 | ||
|
|
b37e5b5198 | ||
|
|
f9d4e9e03d | ||
|
|
9c97d30702 | ||
|
|
9836f7bdef | ||
|
|
b07ff7aebd | ||
|
|
aecbb4564c | ||
|
|
779663b39c | ||
|
|
7934af2974 | ||
|
|
533988233e | ||
|
|
8bc0e77a1d | ||
|
|
1c93c9bb58 | ||
|
|
6d7b32977c | ||
|
|
bf15466bec | ||
|
|
fb1ebe48f0 | ||
|
|
de65697ff9 | ||
|
|
ecf90d689e | ||
|
|
4cdeff11cd | ||
|
|
9ff2f6e430 | ||
|
|
73a0dc6d14 | ||
|
|
0a1c73e0fd | ||
|
|
8653ffc5a4 | ||
|
|
86583a350f | ||
|
|
fafab5d557 | ||
|
|
39e0c22353 | ||
|
|
f767943fb2 | ||
|
|
ae97831ebf | ||
|
|
f16bae0ab9 | ||
|
|
b947b2bc7e | ||
|
|
7068688181 | ||
|
|
38c0600982 | ||
|
|
83d163add5 | ||
|
|
d46e8855ef | ||
|
|
60524c0f8e | ||
|
|
ca73a2aa15 | ||
|
|
4a833a4272 | ||
|
|
f9abeca231 | ||
|
|
5f9e527768 | ||
|
|
6f51de4cb5 |
@@ -1,5 +1,5 @@
|
||||
[bumpversion]
|
||||
current_version = 1.6.0b3
|
||||
current_version = 1.7.0a1
|
||||
parse = (?P<major>[\d]+) # major version number
|
||||
\.(?P<minor>[\d]+) # minor version number
|
||||
\.(?P<patch>[\d]+) # patch version number
|
||||
|
||||
@@ -3,6 +3,7 @@
|
||||
For information on prior major and minor releases, see their changelogs:
|
||||
|
||||
|
||||
* [1.6](https://github.com/dbt-labs/dbt-core/blob/1.6.latest/CHANGELOG.md)
|
||||
* [1.5](https://github.com/dbt-labs/dbt-core/blob/1.5.latest/CHANGELOG.md)
|
||||
* [1.4](https://github.com/dbt-labs/dbt-core/blob/1.4.latest/CHANGELOG.md)
|
||||
* [1.3](https://github.com/dbt-labs/dbt-core/blob/1.3.latest/CHANGELOG.md)
|
||||
|
||||
@@ -1 +0,0 @@
|
||||
## dbt-core 1.6.0-a1 - April 17, 2023
|
||||
@@ -1,50 +0,0 @@
|
||||
## dbt-core 1.6.0-b1 - May 12, 2023
|
||||
|
||||
### Features
|
||||
|
||||
- Skip catalog generation ([#6980](https://github.com/dbt-labs/dbt-core/issues/6980))
|
||||
- Publication artifacts and cross-project ref ([#7227](https://github.com/dbt-labs/dbt-core/issues/7227))
|
||||
- Add graph structure summaries to target path output ([#7357](https://github.com/dbt-labs/dbt-core/issues/7357))
|
||||
- Allow duplicate manifest node (models, seeds, analyses, snapshots) names across packages ([#7446](https://github.com/dbt-labs/dbt-core/issues/7446))
|
||||
- Detect breaking changes to enforced constraints ([#7065](https://github.com/dbt-labs/dbt-core/issues/7065))
|
||||
- Check for project dependency cycles ([#7468](https://github.com/dbt-labs/dbt-core/issues/7468))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Persist timing info in run results for failed nodes ([#5476](https://github.com/dbt-labs/dbt-core/issues/5476))
|
||||
- fix typo in unpacking statically parsed ref ([#7364](https://github.com/dbt-labs/dbt-core/issues/7364))
|
||||
- safe version attribute access in _check_resource_uniqueness ([#7375](https://github.com/dbt-labs/dbt-core/issues/7375))
|
||||
- Fix dbt command missing target-path param ([# 7411](https://github.com/dbt-labs/dbt-core/issues/ 7411))
|
||||
- Fix v0 ref resolution ([#7408](https://github.com/dbt-labs/dbt-core/issues/7408))
|
||||
- Add --target-path to dbt snapshot command. ([#7418](https://github.com/dbt-labs/dbt-core/issues/7418))
|
||||
- dbt build selection of tests' descendants ([#7289](https://github.com/dbt-labs/dbt-core/issues/7289))
|
||||
- fix groupable node partial parsing, raise DbtReferenceError at runtime for safety ([#7437](https://github.com/dbt-labs/dbt-core/issues/7437))
|
||||
- Fix partial parsing of latest_version changes for downstream references ([#7369](https://github.com/dbt-labs/dbt-core/issues/7369))
|
||||
- Use "add_node" to update depends_on.nodes ([#7453](https://github.com/dbt-labs/dbt-core/issues/7453))
|
||||
- Fix var precedence in configs: root vars override package vars ([#6705](https://github.com/dbt-labs/dbt-core/issues/6705))
|
||||
- Fix inverted `--print/--no-print` flag ([#7517](https://github.com/dbt-labs/dbt-core/issues/7517))
|
||||
- Back-compat for previous return type of 'collect_freshness' macro ([#7489](https://github.com/dbt-labs/dbt-core/issues/7489))
|
||||
- print model version in dbt show if specified ([#7407](https://github.com/dbt-labs/dbt-core/issues/7407))
|
||||
- enable dbt show for seeds ([#7273](https://github.com/dbt-labs/dbt-core/issues/7273))
|
||||
- push down limit filtering to adapter ([#7390](https://github.com/dbt-labs/dbt-core/issues/7390))
|
||||
- Allow missing `profiles.yml` for `dbt deps` and `dbt init` ([#7511](https://github.com/dbt-labs/dbt-core/issues/7511))
|
||||
- `run_results.json` is now written after every node completes. ([#7302](https://github.com/dbt-labs/dbt-core/issues/7302))
|
||||
- Do not rewrite manifest.json during 'docs serve' command ([#7553](https://github.com/dbt-labs/dbt-core/issues/7553))
|
||||
- Pin protobuf to greater than 4.0.0 ([#7565](https://github.com/dbt-labs/dbt-core/issues/7565))
|
||||
- inject sql header in query for show ([#7413](https://github.com/dbt-labs/dbt-core/issues/7413))
|
||||
- Pin urllib3 to ~=1.0 ([#7573](https://github.com/dbt-labs/dbt-core/issues/7573))
|
||||
- Throw error for duplicated versioned and unversioned models ([#7487](https://github.com/dbt-labs/dbt-core/issues/7487))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Update docs link in ContractBreakingChangeError message ([#7366](https://github.com/dbt-labs/dbt-core/issues/7366))
|
||||
- Reduce memory footprint of cached statement results. ([#7281](https://github.com/dbt-labs/dbt-core/issues/7281))
|
||||
- Remove noisy parsing events: GenericTestFileParse, MacroFileParse, Note events for static model parsing ([#6671](https://github.com/dbt-labs/dbt-core/issues/6671))
|
||||
- Update --help text for cache-related parameters ([#7381](https://github.com/dbt-labs/dbt-core/issues/7381))
|
||||
- Small UX improvements to model versions: Support defining latest_version in unsuffixed file by default. Notify on unpinned ref when a prerelease version is available. ([#7443](https://github.com/dbt-labs/dbt-core/issues/7443))
|
||||
|
||||
### Contributors
|
||||
- [@AndyBys](https://github.com/AndyBys) ([#6980](https://github.com/dbt-labs/dbt-core/issues/6980))
|
||||
- [@b-luu](https://github.com/b-luu) ([#7289](https://github.com/dbt-labs/dbt-core/issues/7289))
|
||||
- [@dwreeves](https://github.com/dwreeves) ([#7418](https://github.com/dbt-labs/dbt-core/issues/7418))
|
||||
- [@thomasgjerdekog](https://github.com/thomasgjerdekog) ([#7517](https://github.com/dbt-labs/dbt-core/issues/7517))
|
||||
@@ -1,38 +0,0 @@
|
||||
## dbt-core 1.6.0-b2 - May 25, 2023
|
||||
|
||||
### Features
|
||||
|
||||
- Added warnings for model and ref deprecations ([#7433](https://github.com/dbt-labs/dbt-core/issues/7433))
|
||||
- Update drop_relation macro to allow for configuration of drop statement separately from object name ([#7625](https://github.com/dbt-labs/dbt-core/issues/7625))
|
||||
- accept publications in dbt.invoke ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Honor `--skip-profile-setup` parameter when inside an existing project ([#7594](https://github.com/dbt-labs/dbt-core/issues/7594))
|
||||
- Fix: Relative project paths weren't working with deps ([#7491](https://github.com/dbt-labs/dbt-core/issues/7491))
|
||||
- Exclude password fields from Jinja rendering. ([#7629](https://github.com/dbt-labs/dbt-core/issues/7629))
|
||||
- Add --target-path to more CLI subcommands ([#7646](https://github.com/dbt-labs/dbt-core/issues/7646))
|
||||
- Stringify flag paths for Jinja context ([#7495](https://github.com/dbt-labs/dbt-core/issues/7495))
|
||||
- write run_results.json for run operation ([#7502](https://github.com/dbt-labs/dbt-core/issues/7502))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Add ability to instantiate Flags class from dict ([#7607](https://github.com/dbt-labs/dbt-core/issues/7607))
|
||||
- Add other relation to reffable nodes ([#7550](https://github.com/dbt-labs/dbt-core/issues/7550))
|
||||
- Move node patch method to schema parser patch_node_properties and refactor schema parsing ([#7430](https://github.com/dbt-labs/dbt-core/issues/7430))
|
||||
- Remove legacy file logger code ([#NA](https://github.com/dbt-labs/dbt-core/issues/NA))
|
||||
- Break up integration tests as a short term fix for Windows CI runs ([#7668](https://github.com/dbt-labs/dbt-core/issues/7668))
|
||||
- Include null checks in utils test base ([#7670](https://github.com/dbt-labs/dbt-core/issues/7670))
|
||||
- Write pub artifact to log ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
|
||||
### Dependencies
|
||||
|
||||
- Bump ubuntu from 23.04 to 23.10 ([#7675](https://github.com/dbt-labs/dbt-core/pull/7675))
|
||||
- ([#7681](https://github.com/dbt-labs/dbt-core/pull/7681))
|
||||
|
||||
### Contributors
|
||||
- [@dradnan89@hotmail.com](https://github.com/dradnan89@hotmail.com) ([#7681](https://github.com/dbt-labs/dbt-core/pull/7681))
|
||||
- [@dwreeves](https://github.com/dwreeves) ([#7646](https://github.com/dbt-labs/dbt-core/issues/7646))
|
||||
- [@iknox-fa](https://github.com/iknox-fa) ([#7491](https://github.com/dbt-labs/dbt-core/issues/7491), [#NA](https://github.com/dbt-labs/dbt-core/issues/NA))
|
||||
- [@sdebruyn](https://github.com/sdebruyn) ([#7670](https://github.com/dbt-labs/dbt-core/issues/7670))
|
||||
- [@stu-k](https://github.com/stu-k) ([#7607](https://github.com/dbt-labs/dbt-core/issues/7607), [#7550](https://github.com/dbt-labs/dbt-core/issues/7550))
|
||||
@@ -1,46 +0,0 @@
|
||||
## dbt-core 1.6.0-b3 - June 08, 2023
|
||||
|
||||
### Breaking Changes
|
||||
|
||||
- Dropped support for Python 3.7 ([#7082](https://github.com/dbt-labs/dbt-core/issues/7082))
|
||||
- Switch from dbt-metrics to dbt-semantic-interfaces for MetricNode definitions ([#7500](https://github.com/dbt-labs/dbt-core/issues/7500), [#7404](https://github.com/dbt-labs/dbt-core/issues/7404))
|
||||
|
||||
### Features
|
||||
|
||||
- Add support for materialized views ([#6911](https://github.com/dbt-labs/dbt-core/issues/6911))
|
||||
- Optimize template rendering for common parse scenarios ([#7449](https://github.com/dbt-labs/dbt-core/issues/7449))
|
||||
- nodes in packages respect custom generate_alias_name, generate_schema_name, generate_database_name macro overrides defined in packages ([#7444](https://github.com/dbt-labs/dbt-core/issues/7444))
|
||||
- Enable state for deferral to be separate from state for selectors ([#7300](https://github.com/dbt-labs/dbt-core/issues/7300))
|
||||
- add access selection syntax ([#7738](https://github.com/dbt-labs/dbt-core/issues/7738))
|
||||
- add project_name to manifest metadata ([#7752](https://github.com/dbt-labs/dbt-core/issues/7752))
|
||||
- dbt retry ([#7299](https://github.com/dbt-labs/dbt-core/issues/7299))
|
||||
- Revamp debug, add --connection flag. Prepare for future refactors/interface changes. ([#7104](https://github.com/dbt-labs/dbt-core/issues/7104))
|
||||
- Validate public models are not materialized as ephemeral ([#7226](https://github.com/dbt-labs/dbt-core/issues/7226))
|
||||
- Added support for parsing and serializaing semantic models ([#7499](https://github.com/dbt-labs/dbt-core/issues/7499), [#7503](https://github.com/dbt-labs/dbt-core/issues/7503))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Constraint rendering fixes: wrap check expression in parentheses, foreign key 'references', support expression in all constraint types ([#7417](https://github.com/dbt-labs/dbt-core/issues/7417), [#7480](https://github.com/dbt-labs/dbt-core/issues/7480), [#7416](https://github.com/dbt-labs/dbt-core/issues/7416))
|
||||
- Fix warning messages for deprecated dbt_project.yml configs ([#7424](https://github.com/dbt-labs/dbt-core/issues/7424))
|
||||
- Add `%` to adapter suite test cases for `persist_docs` ([#7698](https://github.com/dbt-labs/dbt-core/issues/7698))
|
||||
- Improve warnings for constraints and materialization types ([#7335](https://github.com/dbt-labs/dbt-core/issues/7335))
|
||||
- Incorrect paths used for "target" and "state" directories ([#7465](https://github.com/dbt-labs/dbt-core/issues/7465))
|
||||
- fix StopIteration error when publication for project not found ([#7711](https://github.com/dbt-labs/dbt-core/issues/7711))
|
||||
- Using version 0 works when resolving single model ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
- Fix empty --warn-error-options error message ([#7730](https://github.com/dbt-labs/dbt-core/issues/7730))
|
||||
- send sql header on contract enforcement ([#7714](https://github.com/dbt-labs/dbt-core/issues/7714))
|
||||
- Fixed doc link in selector.py ([#7533](https://github.com/dbt-labs/dbt-core/issues/7533))
|
||||
- Fix null-safe equals comparison via `equals` ([#7778](https://github.com/dbt-labs/dbt-core/issues/7778))
|
||||
- Log PublicationArtifactAvailable even when partially parsing unchanged public models ([#7782](https://github.com/dbt-labs/dbt-core/issues/7782))
|
||||
- fix RuntimeError when removing project dependency from dependencies.yml ([#7743](https://github.com/dbt-labs/dbt-core/issues/7743))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Fix flaky test for --fail-fast ([#7744](https://github.com/dbt-labs/dbt-core/issues/7744))
|
||||
- Create `add_from_artifact` to populate `state_relation` field of nodes ([#7551](https://github.com/dbt-labs/dbt-core/issues/7551))
|
||||
|
||||
### Contributors
|
||||
- [@dave-connors-3](https://github.com/dave-connors-3) ([#7738](https://github.com/dbt-labs/dbt-core/issues/7738))
|
||||
- [@quazi-irfan](https://github.com/quazi-irfan) ([#7533](https://github.com/dbt-labs/dbt-core/issues/7533))
|
||||
- [@sdebruyn](https://github.com/sdebruyn) ([#7082](https://github.com/dbt-labs/dbt-core/issues/7082))
|
||||
- [@stu-k](https://github.com/stu-k) ([#7299](https://github.com/dbt-labs/dbt-core/issues/7299), [#7551](https://github.com/dbt-labs/dbt-core/issues/7551))
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Breaking Changes
|
||||
body: Dropped support for Python 3.7
|
||||
time: 2023-05-15T05:31:48.375649+02:00
|
||||
custom:
|
||||
Author: sdebruyn
|
||||
Issue: "7082"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Breaking Changes
|
||||
body: Switch from dbt-metrics to dbt-semantic-interfaces for MetricNode definitions
|
||||
time: 2023-06-07T19:03:09.680189-07:00
|
||||
custom:
|
||||
Author: QMalcolm
|
||||
Issue: 7500 7404
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: "Dependencies"
|
||||
body: "Bump ubuntu from 23.04 to 23.10"
|
||||
time: 2023-05-22T00:59:48.00000Z
|
||||
custom:
|
||||
Author: dependabot[bot]
|
||||
PR: 7675
|
||||
@@ -1,5 +0,0 @@
|
||||
kind: Dependencies
|
||||
time: 2023-05-22T21:22:01.336704+02:00
|
||||
custom:
|
||||
Author: dradnan89@hotmail.com
|
||||
PR: "7681"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Skip catalog generation
|
||||
time: 2023-03-21T21:33:38.513443Z
|
||||
custom:
|
||||
Author: AndyBys
|
||||
Issue: "6980"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Add support for materialized views
|
||||
time: 2023-03-29T12:03:13.862041-04:00
|
||||
custom:
|
||||
Author: mikealfare McKnight-42
|
||||
Issue: "6911"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Publication artifacts and cross-project ref
|
||||
time: 2023-04-20T12:47:56.92683-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7227"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Optimize template rendering for common parse scenarios
|
||||
time: 2023-04-24T16:36:11.24088-04:00
|
||||
custom:
|
||||
Author: peterallenwebb
|
||||
Issue: "7449"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Add graph structure summaries to target path output
|
||||
time: 2023-04-25T14:25:22.269051-04:00
|
||||
custom:
|
||||
Author: peterallenwebb
|
||||
Issue: "7357"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Features
|
||||
body: Allow duplicate manifest node (models, seeds, analyses, snapshots) names across
|
||||
packages
|
||||
time: 2023-04-29T15:50:57.757832-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7446"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Detect breaking changes to enforced constraints
|
||||
time: 2023-05-03T10:11:00.617936-05:00
|
||||
custom:
|
||||
Author: emmyoop
|
||||
Issue: "7065"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Check for project dependency cycles
|
||||
time: 2023-05-09T09:41:47.2-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7468"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Features
|
||||
body: nodes in packages respect custom generate_alias_name, generate_schema_name,
|
||||
generate_database_name macro overrides defined in packages
|
||||
time: 2023-05-09T21:29:35.557761-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7444"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Added warnings for model and ref deprecations
|
||||
time: 2023-05-09T23:33:29.679333-04:00
|
||||
custom:
|
||||
Author: peterallenwebb
|
||||
Issue: "7433"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Features
|
||||
body: Update drop_relation macro to allow for configuration of drop statement separately
|
||||
from object name
|
||||
time: 2023-05-15T12:23:04.177141-04:00
|
||||
custom:
|
||||
Author: mikealfare
|
||||
Issue: "7625"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: accept publications in dbt.invoke
|
||||
time: 2023-05-17T18:56:27.585784-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7372"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Enable state for deferral to be separate from state for selectors
|
||||
time: 2023-05-23T22:59:55.920975-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7300"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: add access selection syntax
|
||||
time: 2023-05-30T16:48:47.740037-05:00
|
||||
custom:
|
||||
Author: dave-connors-3
|
||||
Issue: "7738"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: add project_name to manifest metadata
|
||||
time: 2023-06-01T13:22:23.259448-04:00
|
||||
custom:
|
||||
Author: michelleark jtcohen6
|
||||
Issue: "7752"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: dbt retry
|
||||
time: 2023-06-02T08:33:02.410456-07:00
|
||||
custom:
|
||||
Author: stu-k aranke
|
||||
Issue: "7299"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Revamp debug, add --connection flag. Prepare for future refactors/interface changes.
|
||||
time: 2023-06-04T02:59:56.28283-07:00
|
||||
custom:
|
||||
Author: versusfacit
|
||||
Issue: 7104
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix null-safe equals comparison via `equals`
|
||||
time: 2023-06-04T08:00:52.537967-06:00
|
||||
custom:
|
||||
Author: dbeatty10
|
||||
Issue: "7778"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: ' Validate public models are not materialized as ephemeral'
|
||||
time: 2023-06-05T22:20:39.382019-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7226"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Features
|
||||
body: Added support for parsing and serializaing semantic models
|
||||
time: 2023-06-06T16:53:51.117429-04:00
|
||||
custom:
|
||||
Author: peterallenwebb
|
||||
Issue: 7499 7503
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Persist timing info in run results for failed nodes
|
||||
time: 2023-04-13T13:31:57.938847-05:00
|
||||
custom:
|
||||
Author: stu-k
|
||||
Issue: "5476"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: fix typo in unpacking statically parsed ref
|
||||
time: 2023-04-14T16:36:42.279838-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7364"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: safe version attribute access in _check_resource_uniqueness
|
||||
time: 2023-04-18T13:52:57.367108-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7375"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix dbt command missing target-path param
|
||||
time: 2023-04-19T14:21:50.959786-07:00
|
||||
custom:
|
||||
Author: ChenyuLInx
|
||||
Issue: "\t7411"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix v0 ref resolution
|
||||
time: 2023-04-19T22:09:10.155137-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7408"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Add --target-path to dbt snapshot command.
|
||||
time: 2023-04-20T10:42:54.17972-04:00
|
||||
custom:
|
||||
Author: dwreeves
|
||||
Issue: "7418"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: dbt build selection of tests' descendants
|
||||
time: 2023-04-21T17:24:28.335866975+02:00
|
||||
custom:
|
||||
Author: b-luu
|
||||
Issue: "7289"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: fix groupable node partial parsing, raise DbtReferenceError at runtime for safety
|
||||
time: 2023-04-24T16:18:43.130637-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7437"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix partial parsing of latest_version changes for downstream references
|
||||
time: 2023-04-24T16:46:49.721231-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "7369"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Use "add_node" to update depends_on.nodes
|
||||
time: 2023-04-24T17:34:04.37479-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7453"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: 'Fix var precedence in configs: root vars override package vars'
|
||||
time: 2023-04-27T23:07:14.992529-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: "6705"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Fixes
|
||||
body: 'Constraint rendering fixes: wrap check expression in parentheses, foreign key
|
||||
''references'', support expression in all constraint types'
|
||||
time: 2023-05-04T14:06:42.545193-04:00
|
||||
custom:
|
||||
Author: MichelleArk
|
||||
Issue: 7417 7480 7416
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix inverted `--print/--no-print` flag
|
||||
time: 2023-05-05T13:25:45.949997-06:00
|
||||
custom:
|
||||
Author: dbeatty10 thomasgjerdekog
|
||||
Issue: "7517"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Back-compat for previous return type of 'collect_freshness' macro
|
||||
time: 2023-05-06T17:33:15.104953+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7489"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix warning messages for deprecated dbt_project.yml configs
|
||||
time: 2023-05-06T18:09:00.361961+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7424"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: print model version in dbt show if specified
|
||||
time: 2023-05-08T04:27:07.9965-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7407"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: enable dbt show for seeds
|
||||
time: 2023-05-08T04:49:22.82093-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7273"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: push down limit filtering to adapter
|
||||
time: 2023-05-08T06:09:26.455524-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7390"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Allow missing `profiles.yml` for `dbt deps` and `dbt init`
|
||||
time: 2023-05-08T07:29:29.873793-06:00
|
||||
custom:
|
||||
Author: dbeatty10
|
||||
Issue: "7511"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: '`run_results.json` is now written after every node completes.'
|
||||
time: 2023-05-08T09:37:32.809356-05:00
|
||||
custom:
|
||||
Author: iknox-fa
|
||||
Issue: "7302"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Do not rewrite manifest.json during 'docs serve' command
|
||||
time: 2023-05-08T14:25:18.376379-04:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7553"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: inject sql header in query for show
|
||||
time: 2023-05-09T10:29:32.12947-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7413"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Pin protobuf to greater than 4.0.0
|
||||
time: 2023-05-09T12:31:59.019718-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7565"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Pin urllib3 to ~=1.0
|
||||
time: 2023-05-09T15:35:30.504674-04:00
|
||||
custom:
|
||||
Author: mikealfare
|
||||
Issue: "7573"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Throw error for duplicated versioned and unversioned models
|
||||
time: 2023-05-09T16:50:07.530882-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7487"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Honor `--skip-profile-setup` parameter when inside an existing project
|
||||
time: 2023-05-11T14:04:41.382181-06:00
|
||||
custom:
|
||||
Author: dbeatty10
|
||||
Issue: "7594"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: 'Fix: Relative project paths weren''t working with deps'
|
||||
time: 2023-05-15T12:36:54.807413-05:00
|
||||
custom:
|
||||
Author: iknox-fa
|
||||
Issue: "7491"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Exclude password fields from Jinja rendering.
|
||||
time: 2023-05-15T14:28:51.400321-04:00
|
||||
custom:
|
||||
Author: peterallenwebb
|
||||
Issue: "7629"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Add --target-path to more CLI subcommands
|
||||
time: 2023-05-16T15:26:44.557072-04:00
|
||||
custom:
|
||||
Author: dwreeves
|
||||
Issue: "7646"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: write run_results.json for run operation
|
||||
time: 2023-05-22T13:29:24.182612-07:00
|
||||
custom:
|
||||
Author: aranke
|
||||
Issue: "7502"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Stringify flag paths for Jinja context
|
||||
time: 2023-05-22T13:50:07.897354-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7495"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Add `%` to adapter suite test cases for `persist_docs`
|
||||
time: 2023-05-24T16:06:48.477708-06:00
|
||||
custom:
|
||||
Author: dbeatty10
|
||||
Issue: "7698"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Improve warnings for constraints and materialization types
|
||||
time: 2023-05-25T07:36:51.855641-05:00
|
||||
custom:
|
||||
Author: emmyoop
|
||||
Issue: "7335"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Incorrect paths used for "target" and "state" directories
|
||||
time: 2023-05-25T16:50:53.718564-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7465"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: fix StopIteration error when publication for project not found
|
||||
time: 2023-05-26T15:37:38.952939-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7711"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Using version 0 works when resolving single model
|
||||
time: 2023-05-26T16:47:27.6065-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7372"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fix empty --warn-error-options error message
|
||||
time: 2023-05-30T10:42:28.382804-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7730"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: send sql header on contract enforcement
|
||||
time: 2023-05-31T13:19:19.801391-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7714"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Fixed doc link in selector.py
|
||||
time: 2023-06-01T13:05:49.952-05:00
|
||||
custom:
|
||||
Author: quazi-irfan
|
||||
Issue: "7533"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Fixes
|
||||
body: Log PublicationArtifactAvailable even when partially parsing unchanged public
|
||||
models
|
||||
time: 2023-06-05T12:11:27.739183-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7782"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Fixes
|
||||
body: fix RuntimeError when removing project dependency from dependencies.yml
|
||||
time: 2023-06-05T12:44:25.978022-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7743"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Update docs link in ContractBreakingChangeError message
|
||||
time: 2023-04-17T11:45:01.005104+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7366"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Reduce memory footprint of cached statement results.
|
||||
time: 2023-04-17T12:27:21.972268-05:00
|
||||
custom:
|
||||
Author: iknox-fa
|
||||
Issue: "7281"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: 'Remove noisy parsing events: GenericTestFileParse, MacroFileParse, Note events
|
||||
for static model parsing'
|
||||
time: 2023-04-18T12:12:36.928665+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "6671"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Update --help text for cache-related parameters
|
||||
time: 2023-04-18T12:23:23.276693+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7381"
|
||||
@@ -1,8 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: 'Small UX improvements to model versions: Support defining latest_version in
|
||||
unsuffixed file by default. Notify on unpinned ref when a prerelease version is
|
||||
available. '
|
||||
time: 2023-04-24T13:53:00.484916+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
Issue: "7443"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Add ability to instantiate Flags class from dict
|
||||
time: 2023-05-15T09:51:16.291352-05:00
|
||||
custom:
|
||||
Author: stu-k
|
||||
Issue: "7607"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Add other relation to reffable nodes
|
||||
time: 2023-05-15T15:21:07.808892-05:00
|
||||
custom:
|
||||
Author: stu-k
|
||||
Issue: "7550"
|
||||
@@ -1,7 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Move node patch method to schema parser patch_node_properties and refactor schema
|
||||
parsing
|
||||
time: 2023-05-16T09:42:41.793503-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7430"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Remove legacy file logger code
|
||||
time: 2023-05-18T11:42:51.825799-05:00
|
||||
custom:
|
||||
Author: iknox-fa
|
||||
Issue: NA
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Break up integration tests as a short term fix for Windows CI runs
|
||||
time: 2023-05-19T15:30:59.138043-04:00
|
||||
custom:
|
||||
Author: mikealfare
|
||||
Issue: "7668"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Include null checks in utils test base
|
||||
time: 2023-05-21T12:57:20.659726+02:00
|
||||
custom:
|
||||
Author: sdebruyn
|
||||
Issue: "7670"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Write pub artifact to log
|
||||
time: 2023-05-23T12:21:37.235938-04:00
|
||||
custom:
|
||||
Author: gshank
|
||||
Issue: "7372"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Fix flaky test for --fail-fast
|
||||
time: 2023-06-02T14:57:43.266412-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "7744"
|
||||
@@ -1,6 +0,0 @@
|
||||
kind: Under the Hood
|
||||
body: Create `add_from_artifact` to populate `state_relation` field of nodes
|
||||
time: 2023-06-05T23:47:06.581326-07:00
|
||||
custom:
|
||||
Author: stu-k aranke
|
||||
Issue: "7551"
|
||||
6
.changes/unreleased/Dependencies-20230719-123743.yaml
Normal file
6
.changes/unreleased/Dependencies-20230719-123743.yaml
Normal file
@@ -0,0 +1,6 @@
|
||||
kind: Dependencies
|
||||
body: Pin click<9 + sqlparse<0.5
|
||||
time: 2023-07-19T12:37:43.716495+02:00
|
||||
custom:
|
||||
Author: jtcohen6
|
||||
PR: "8146"
|
||||
6
.changes/unreleased/Docs-20230531-115419.yaml
Normal file
6
.changes/unreleased/Docs-20230531-115419.yaml
Normal file
@@ -0,0 +1,6 @@
|
||||
kind: Docs
|
||||
body: Fix for column tests not rendering on quoted columns
|
||||
time: 2023-05-31T11:54:19.687363-04:00
|
||||
custom:
|
||||
Author: drewbanin
|
||||
Issue: "201"
|
||||
6
.changes/unreleased/Docs-20230718-192422.yaml
Normal file
6
.changes/unreleased/Docs-20230718-192422.yaml
Normal file
@@ -0,0 +1,6 @@
|
||||
kind: Docs
|
||||
body: Remove static SQL codeblock for metrics
|
||||
time: 2023-07-18T19:24:22.155323+02:00
|
||||
custom:
|
||||
Author: marcodamore
|
||||
Issue: "436"
|
||||
6
.changes/unreleased/Fixes-20230718-125518.yaml
Normal file
6
.changes/unreleased/Fixes-20230718-125518.yaml
Normal file
@@ -0,0 +1,6 @@
|
||||
kind: Fixes
|
||||
body: Enable converting deprecation warnings to errors
|
||||
time: 2023-07-18T12:55:18.03914-04:00
|
||||
custom:
|
||||
Author: michelleark
|
||||
Issue: "8130"
|
||||
30
.github/pull_request_template.md
vendored
30
.github/pull_request_template.md
vendored
@@ -1,23 +1,35 @@
|
||||
resolves #
|
||||
resolves #
|
||||
[docs](https://github.com/dbt-labs/docs.getdbt.com/issues/new/choose) dbt-labs/docs.getdbt.com/#
|
||||
|
||||
<!---
|
||||
Include the number of the issue addressed by this PR above if applicable.
|
||||
PRs for code changes without an associated issue *will not be merged*.
|
||||
See CONTRIBUTING.md for more information.
|
||||
|
||||
Include the number of the docs issue that was opened for this PR. If
|
||||
this change has no user-facing implications, "N/A" suffices instead. New
|
||||
docs tickets can be created by clicking the link above or by going to
|
||||
https://github.com/dbt-labs/docs.getdbt.com/issues/new/choose.
|
||||
-->
|
||||
|
||||
### Description
|
||||
### Problem
|
||||
|
||||
<!---
|
||||
Describe the Pull Request here. Add any references and info to help reviewers
|
||||
understand your changes. Include any tradeoffs you considered.
|
||||
Describe the problem this PR is solving. What is the application state
|
||||
before this PR is merged?
|
||||
-->
|
||||
|
||||
### Solution
|
||||
|
||||
<!---
|
||||
Describe the way this PR solves the above problem. Add as much detail as you
|
||||
can to help reviewers understand your changes. Include any alternatives and
|
||||
tradeoffs you considered.
|
||||
-->
|
||||
|
||||
### Checklist
|
||||
|
||||
- [ ] I have read [the contributing guide](https://github.com/dbt-labs/dbt-core/blob/main/CONTRIBUTING.md) and understand what's expected of me
|
||||
- [ ] I have signed the [CLA](https://docs.getdbt.com/docs/contributor-license-agreements)
|
||||
- [ ] I have run this code in development and it appears to resolve the stated issue
|
||||
- [ ] I have read [the contributing guide](https://github.com/dbt-labs/dbt-core/blob/main/CONTRIBUTING.md) and understand what's expected of me
|
||||
- [ ] I have run this code in development and it appears to resolve the stated issue
|
||||
- [ ] This PR includes tests, or tests are not required/relevant for this PR
|
||||
- [ ] I have [opened an issue to add/update docs](https://github.com/dbt-labs/docs.getdbt.com/issues/new/choose), or docs changes are not required/relevant for this PR
|
||||
- [ ] I have run `changie new` to [create a changelog entry](https://github.com/dbt-labs/dbt-core/blob/main/CONTRIBUTING.md#adding-a-changelog-entry)
|
||||
- [ ] This PR has no interface changes (e.g. macros, cli, logs, json artifacts, config files, adapter interface, etc) or this PR has already received feedback and approval from Product or DX
|
||||
|
||||
31
.github/workflows/main.yml
vendored
31
.github/workflows/main.yml
vendored
@@ -73,7 +73,6 @@ jobs:
|
||||
|
||||
env:
|
||||
TOXENV: "unit"
|
||||
PYTEST_ADDOPTS: "-v --color=yes --csv unit_results.csv"
|
||||
|
||||
steps:
|
||||
- name: Check out the repository
|
||||
@@ -101,17 +100,17 @@ jobs:
|
||||
CURRENT_DATE=$(date +'%Y-%m-%dT%H_%M_%S') # no colons allowed for artifacts
|
||||
echo "date=$CURRENT_DATE" >> $GITHUB_OUTPUT
|
||||
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: always()
|
||||
with:
|
||||
name: unit_results_${{ matrix.python-version }}-${{ steps.date.outputs.date }}.csv
|
||||
path: unit_results.csv
|
||||
- name: Upload Unit Test Coverage to Codecov
|
||||
if: ${{ matrix.python-version == '3.11' }}
|
||||
uses: codecov/codecov-action@v3
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
|
||||
integration:
|
||||
name: integration test / python ${{ matrix.python-version }} / ${{ matrix.os }}
|
||||
|
||||
runs-on: ${{ matrix.os }}
|
||||
timeout-minutes: 45
|
||||
timeout-minutes: 60
|
||||
|
||||
strategy:
|
||||
fail-fast: false
|
||||
@@ -126,11 +125,15 @@ jobs:
|
||||
|
||||
env:
|
||||
TOXENV: integration
|
||||
PYTEST_ADDOPTS: "-v --color=yes -n4 --csv integration_results.csv"
|
||||
DBT_INVOCATION_ENV: github-actions
|
||||
DBT_TEST_USER_1: dbt_test_user_1
|
||||
DBT_TEST_USER_2: dbt_test_user_2
|
||||
DBT_TEST_USER_3: dbt_test_user_3
|
||||
DD_CIVISIBILITY_AGENTLESS_ENABLED: true
|
||||
DD_API_KEY: ${{ secrets.DATADOG_API_KEY }}
|
||||
DD_SITE: datadoghq.com
|
||||
DD_ENV: ci
|
||||
DD_SERVICE: ${{ github.event.repository.name }}
|
||||
|
||||
steps:
|
||||
- name: Check out the repository
|
||||
@@ -161,7 +164,7 @@ jobs:
|
||||
tox --version
|
||||
|
||||
- name: Run tests
|
||||
run: tox
|
||||
run: tox -- --ddtrace
|
||||
|
||||
- name: Get current date
|
||||
if: always()
|
||||
@@ -176,11 +179,11 @@ jobs:
|
||||
name: logs_${{ matrix.python-version }}_${{ matrix.os }}_${{ steps.date.outputs.date }}
|
||||
path: ./logs
|
||||
|
||||
- uses: actions/upload-artifact@v3
|
||||
if: always()
|
||||
with:
|
||||
name: integration_results_${{ matrix.python-version }}_${{ matrix.os }}_${{ steps.date.outputs.date }}.csv
|
||||
path: integration_results.csv
|
||||
- name: Upload Integration Test Coverage to Codecov
|
||||
if: ${{ matrix.python-version == '3.11' }}
|
||||
uses: codecov/codecov-action@v3
|
||||
env:
|
||||
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
|
||||
|
||||
build:
|
||||
name: build packages
|
||||
|
||||
155
.github/workflows/test-repeater.yml
vendored
Normal file
155
.github/workflows/test-repeater.yml
vendored
Normal file
@@ -0,0 +1,155 @@
|
||||
# **what?**
|
||||
# This workflow will test all test(s) at the input path given number of times to determine if it's flaky or not. You can test with any supported OS/Python combination.
|
||||
# This is batched in 10 to allow more test iterations faster.
|
||||
|
||||
# **why?**
|
||||
# Testing if a test is flaky and if a previously flaky test has been fixed. This allows easy testing on supported python versions and OS combinations.
|
||||
|
||||
# **when?**
|
||||
# This is triggered manually from dbt-core.
|
||||
|
||||
name: Flaky Tester
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
inputs:
|
||||
branch:
|
||||
description: 'Branch to check out'
|
||||
type: string
|
||||
required: true
|
||||
default: 'main'
|
||||
test_path:
|
||||
description: 'Path to single test to run (ex: tests/functional/retry/test_retry.py::TestRetry::test_fail_fast)'
|
||||
type: string
|
||||
required: true
|
||||
default: 'tests/functional/...'
|
||||
python_version:
|
||||
description: 'Version of Python to Test Against'
|
||||
type: choice
|
||||
options:
|
||||
- '3.8'
|
||||
- '3.9'
|
||||
- '3.10'
|
||||
- '3.11'
|
||||
os:
|
||||
description: 'OS to run test in'
|
||||
type: choice
|
||||
options:
|
||||
- 'ubuntu-latest'
|
||||
- 'macos-latest'
|
||||
- 'windows-latest'
|
||||
num_runs_per_batch:
|
||||
description: 'Max number of times to run the test per batch. We always run 10 batches.'
|
||||
type: number
|
||||
required: true
|
||||
default: '50'
|
||||
|
||||
permissions: read-all
|
||||
|
||||
defaults:
|
||||
run:
|
||||
shell: bash
|
||||
|
||||
jobs:
|
||||
debug:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: "[DEBUG] Output Inputs"
|
||||
run: |
|
||||
echo "Branch: ${{ inputs.branch }}"
|
||||
echo "test_path: ${{ inputs.test_path }}"
|
||||
echo "python_version: ${{ inputs.python_version }}"
|
||||
echo "os: ${{ inputs.os }}"
|
||||
echo "num_runs_per_batch: ${{ inputs.num_runs_per_batch }}"
|
||||
|
||||
pytest:
|
||||
runs-on: ${{ inputs.os }}
|
||||
strategy:
|
||||
# run all batches, even if one fails. This informs how flaky the test may be.
|
||||
fail-fast: false
|
||||
# using a matrix to speed up the jobs since the matrix will run in parallel when runners are available
|
||||
matrix:
|
||||
batch: ["1", "2", "3", "4", "5", "6", "7", "8", "9", "10"]
|
||||
env:
|
||||
PYTEST_ADDOPTS: "-v --color=yes -n4 --csv integration_results.csv"
|
||||
DBT_TEST_USER_1: dbt_test_user_1
|
||||
DBT_TEST_USER_2: dbt_test_user_2
|
||||
DBT_TEST_USER_3: dbt_test_user_3
|
||||
DD_CIVISIBILITY_AGENTLESS_ENABLED: true
|
||||
DD_API_KEY: ${{ secrets.DATADOG_API_KEY }}
|
||||
DD_SITE: datadoghq.com
|
||||
DD_ENV: ci
|
||||
DD_SERVICE: ${{ github.event.repository.name }}
|
||||
|
||||
steps:
|
||||
- name: "Checkout code"
|
||||
uses: actions/checkout@v3
|
||||
with:
|
||||
ref: ${{ inputs.branch }}
|
||||
|
||||
- name: "Setup Python"
|
||||
uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "${{ inputs.python_version }}"
|
||||
|
||||
- name: "Setup Dev Environment"
|
||||
run: make dev
|
||||
|
||||
- name: "Set up postgres (linux)"
|
||||
if: inputs.os == 'ubuntu-latest'
|
||||
run: make setup-db
|
||||
|
||||
# mac and windows don't use make due to limitations with docker with those runners in GitHub
|
||||
- name: "Set up postgres (macos)"
|
||||
if: inputs.os == 'macos-latest'
|
||||
uses: ./.github/actions/setup-postgres-macos
|
||||
|
||||
- name: "Set up postgres (windows)"
|
||||
if: inputs.os == 'windows-latest'
|
||||
uses: ./.github/actions/setup-postgres-windows
|
||||
|
||||
- name: "Test Command"
|
||||
id: command
|
||||
run: |
|
||||
test_command="python -m pytest ${{ inputs.test_path }}"
|
||||
echo "test_command=$test_command" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: "Run test ${{ inputs.num_runs_per_batch }} times"
|
||||
id: pytest
|
||||
run: |
|
||||
set +e
|
||||
for ((i=1; i<=${{ inputs.num_runs_per_batch }}; i++))
|
||||
do
|
||||
echo "Running pytest iteration $i..."
|
||||
python -m pytest --ddtrace ${{ inputs.test_path }}
|
||||
exit_code=$?
|
||||
|
||||
if [[ $exit_code -eq 0 ]]; then
|
||||
success=$((success + 1))
|
||||
echo "Iteration $i: Success"
|
||||
else
|
||||
failure=$((failure + 1))
|
||||
echo "Iteration $i: Failure"
|
||||
fi
|
||||
|
||||
echo
|
||||
echo "==========================="
|
||||
echo "Successful runs: $success"
|
||||
echo "Failed runs: $failure"
|
||||
echo "==========================="
|
||||
echo
|
||||
done
|
||||
|
||||
echo "failure=$failure" >> $GITHUB_OUTPUT
|
||||
|
||||
- name: "Success and Failure Summary: ${{ inputs.os }}/Python ${{ inputs.python_version }}"
|
||||
run: |
|
||||
echo "Batch: ${{ matrix.batch }}"
|
||||
echo "Successful runs: ${{ steps.pytest.outputs.success }}"
|
||||
echo "Failed runs: ${{ steps.pytest.outputs.failure }}"
|
||||
|
||||
- name: "Error for Failures"
|
||||
if: ${{ steps.pytest.outputs.failure }}
|
||||
run: |
|
||||
echo "Batch ${{ matrix.batch }} failed ${{ steps.pytest.outputs.failure }} of ${{ inputs.num_runs_per_batch }} tests"
|
||||
exit 1
|
||||
2
.gitignore
vendored
2
.gitignore
vendored
@@ -29,6 +29,8 @@ var/
|
||||
.mypy_cache/
|
||||
.dmypy.json
|
||||
logs/
|
||||
.user.yml
|
||||
profiles.yml
|
||||
|
||||
# PyInstaller
|
||||
# Usually these files are written by a python script from a template
|
||||
|
||||
@@ -37,7 +37,7 @@ repos:
|
||||
alias: flake8-check
|
||||
stages: [manual]
|
||||
- repo: https://github.com/pre-commit/mirrors-mypy
|
||||
rev: v0.981
|
||||
rev: v1.3.0
|
||||
hooks:
|
||||
- id: mypy
|
||||
# N.B.: Mypy is... a bit fragile.
|
||||
|
||||
141
CHANGELOG.md
141
CHANGELOG.md
@@ -5,151 +5,12 @@
|
||||
- "Breaking changes" listed under a version may require action from end users or external maintainers when upgrading to that version.
|
||||
- Do not edit this file directly. This file is auto-generated using [changie](https://github.com/miniscruff/changie). For details on how to document a change, see [the contributing guide](https://github.com/dbt-labs/dbt-core/blob/main/CONTRIBUTING.md#adding-changelog-entry)
|
||||
|
||||
## dbt-core 1.6.0-b3 - June 08, 2023
|
||||
|
||||
### Breaking Changes
|
||||
|
||||
- Dropped support for Python 3.7 ([#7082](https://github.com/dbt-labs/dbt-core/issues/7082))
|
||||
- Switch from dbt-metrics to dbt-semantic-interfaces for MetricNode definitions ([#7500](https://github.com/dbt-labs/dbt-core/issues/7500), [#7404](https://github.com/dbt-labs/dbt-core/issues/7404))
|
||||
|
||||
### Features
|
||||
|
||||
- Add support for materialized views ([#6911](https://github.com/dbt-labs/dbt-core/issues/6911))
|
||||
- Optimize template rendering for common parse scenarios ([#7449](https://github.com/dbt-labs/dbt-core/issues/7449))
|
||||
- nodes in packages respect custom generate_alias_name, generate_schema_name, generate_database_name macro overrides defined in packages ([#7444](https://github.com/dbt-labs/dbt-core/issues/7444))
|
||||
- Enable state for deferral to be separate from state for selectors ([#7300](https://github.com/dbt-labs/dbt-core/issues/7300))
|
||||
- add access selection syntax ([#7738](https://github.com/dbt-labs/dbt-core/issues/7738))
|
||||
- add project_name to manifest metadata ([#7752](https://github.com/dbt-labs/dbt-core/issues/7752))
|
||||
- dbt retry ([#7299](https://github.com/dbt-labs/dbt-core/issues/7299))
|
||||
- Revamp debug, add --connection flag. Prepare for future refactors/interface changes. ([#7104](https://github.com/dbt-labs/dbt-core/issues/7104))
|
||||
- Validate public models are not materialized as ephemeral ([#7226](https://github.com/dbt-labs/dbt-core/issues/7226))
|
||||
- Added support for parsing and serializaing semantic models ([#7499](https://github.com/dbt-labs/dbt-core/issues/7499), [#7503](https://github.com/dbt-labs/dbt-core/issues/7503))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Constraint rendering fixes: wrap check expression in parentheses, foreign key 'references', support expression in all constraint types ([#7417](https://github.com/dbt-labs/dbt-core/issues/7417), [#7480](https://github.com/dbt-labs/dbt-core/issues/7480), [#7416](https://github.com/dbt-labs/dbt-core/issues/7416))
|
||||
- Fix warning messages for deprecated dbt_project.yml configs ([#7424](https://github.com/dbt-labs/dbt-core/issues/7424))
|
||||
- Add `%` to adapter suite test cases for `persist_docs` ([#7698](https://github.com/dbt-labs/dbt-core/issues/7698))
|
||||
- Improve warnings for constraints and materialization types ([#7335](https://github.com/dbt-labs/dbt-core/issues/7335))
|
||||
- Incorrect paths used for "target" and "state" directories ([#7465](https://github.com/dbt-labs/dbt-core/issues/7465))
|
||||
- fix StopIteration error when publication for project not found ([#7711](https://github.com/dbt-labs/dbt-core/issues/7711))
|
||||
- Using version 0 works when resolving single model ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
- Fix empty --warn-error-options error message ([#7730](https://github.com/dbt-labs/dbt-core/issues/7730))
|
||||
- send sql header on contract enforcement ([#7714](https://github.com/dbt-labs/dbt-core/issues/7714))
|
||||
- Fixed doc link in selector.py ([#7533](https://github.com/dbt-labs/dbt-core/issues/7533))
|
||||
- Fix null-safe equals comparison via `equals` ([#7778](https://github.com/dbt-labs/dbt-core/issues/7778))
|
||||
- Log PublicationArtifactAvailable even when partially parsing unchanged public models ([#7782](https://github.com/dbt-labs/dbt-core/issues/7782))
|
||||
- fix RuntimeError when removing project dependency from dependencies.yml ([#7743](https://github.com/dbt-labs/dbt-core/issues/7743))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Fix flaky test for --fail-fast ([#7744](https://github.com/dbt-labs/dbt-core/issues/7744))
|
||||
- Create `add_from_artifact` to populate `state_relation` field of nodes ([#7551](https://github.com/dbt-labs/dbt-core/issues/7551))
|
||||
|
||||
### Contributors
|
||||
- [@dave-connors-3](https://github.com/dave-connors-3) ([#7738](https://github.com/dbt-labs/dbt-core/issues/7738))
|
||||
- [@quazi-irfan](https://github.com/quazi-irfan) ([#7533](https://github.com/dbt-labs/dbt-core/issues/7533))
|
||||
- [@sdebruyn](https://github.com/sdebruyn) ([#7082](https://github.com/dbt-labs/dbt-core/issues/7082))
|
||||
- [@stu-k](https://github.com/stu-k) ([#7299](https://github.com/dbt-labs/dbt-core/issues/7299), [#7551](https://github.com/dbt-labs/dbt-core/issues/7551))
|
||||
|
||||
|
||||
## dbt-core 1.6.0-b2 - May 25, 2023
|
||||
|
||||
### Features
|
||||
|
||||
- Added warnings for model and ref deprecations ([#7433](https://github.com/dbt-labs/dbt-core/issues/7433))
|
||||
- Update drop_relation macro to allow for configuration of drop statement separately from object name ([#7625](https://github.com/dbt-labs/dbt-core/issues/7625))
|
||||
- accept publications in dbt.invoke ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Honor `--skip-profile-setup` parameter when inside an existing project ([#7594](https://github.com/dbt-labs/dbt-core/issues/7594))
|
||||
- Fix: Relative project paths weren't working with deps ([#7491](https://github.com/dbt-labs/dbt-core/issues/7491))
|
||||
- Exclude password fields from Jinja rendering. ([#7629](https://github.com/dbt-labs/dbt-core/issues/7629))
|
||||
- Add --target-path to more CLI subcommands ([#7646](https://github.com/dbt-labs/dbt-core/issues/7646))
|
||||
- Stringify flag paths for Jinja context ([#7495](https://github.com/dbt-labs/dbt-core/issues/7495))
|
||||
- write run_results.json for run operation ([#7502](https://github.com/dbt-labs/dbt-core/issues/7502))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Add ability to instantiate Flags class from dict ([#7607](https://github.com/dbt-labs/dbt-core/issues/7607))
|
||||
- Add other relation to reffable nodes ([#7550](https://github.com/dbt-labs/dbt-core/issues/7550))
|
||||
- Move node patch method to schema parser patch_node_properties and refactor schema parsing ([#7430](https://github.com/dbt-labs/dbt-core/issues/7430))
|
||||
- Remove legacy file logger code ([#NA](https://github.com/dbt-labs/dbt-core/issues/NA))
|
||||
- Break up integration tests as a short term fix for Windows CI runs ([#7668](https://github.com/dbt-labs/dbt-core/issues/7668))
|
||||
- Include null checks in utils test base ([#7670](https://github.com/dbt-labs/dbt-core/issues/7670))
|
||||
- Write pub artifact to log ([#7372](https://github.com/dbt-labs/dbt-core/issues/7372))
|
||||
|
||||
### Dependencies
|
||||
|
||||
- Bump ubuntu from 23.04 to 23.10 ([#7675](https://github.com/dbt-labs/dbt-core/pull/7675))
|
||||
- ([#7681](https://github.com/dbt-labs/dbt-core/pull/7681))
|
||||
|
||||
### Contributors
|
||||
- [@dradnan89@hotmail.com](https://github.com/dradnan89@hotmail.com) ([#7681](https://github.com/dbt-labs/dbt-core/pull/7681))
|
||||
- [@dwreeves](https://github.com/dwreeves) ([#7646](https://github.com/dbt-labs/dbt-core/issues/7646))
|
||||
- [@iknox-fa](https://github.com/iknox-fa) ([#7491](https://github.com/dbt-labs/dbt-core/issues/7491), [#NA](https://github.com/dbt-labs/dbt-core/issues/NA))
|
||||
- [@sdebruyn](https://github.com/sdebruyn) ([#7670](https://github.com/dbt-labs/dbt-core/issues/7670))
|
||||
- [@stu-k](https://github.com/stu-k) ([#7607](https://github.com/dbt-labs/dbt-core/issues/7607), [#7550](https://github.com/dbt-labs/dbt-core/issues/7550))
|
||||
|
||||
## dbt-core 1.6.0-b1 - May 12, 2023
|
||||
|
||||
### Features
|
||||
|
||||
- Skip catalog generation ([#6980](https://github.com/dbt-labs/dbt-core/issues/6980))
|
||||
- Publication artifacts and cross-project ref ([#7227](https://github.com/dbt-labs/dbt-core/issues/7227))
|
||||
- Add graph structure summaries to target path output ([#7357](https://github.com/dbt-labs/dbt-core/issues/7357))
|
||||
- Allow duplicate manifest node (models, seeds, analyses, snapshots) names across packages ([#7446](https://github.com/dbt-labs/dbt-core/issues/7446))
|
||||
- Detect breaking changes to enforced constraints ([#7065](https://github.com/dbt-labs/dbt-core/issues/7065))
|
||||
- Check for project dependency cycles ([#7468](https://github.com/dbt-labs/dbt-core/issues/7468))
|
||||
|
||||
### Fixes
|
||||
|
||||
- Persist timing info in run results for failed nodes ([#5476](https://github.com/dbt-labs/dbt-core/issues/5476))
|
||||
- fix typo in unpacking statically parsed ref ([#7364](https://github.com/dbt-labs/dbt-core/issues/7364))
|
||||
- safe version attribute access in _check_resource_uniqueness ([#7375](https://github.com/dbt-labs/dbt-core/issues/7375))
|
||||
- Fix dbt command missing target-path param ([# 7411](https://github.com/dbt-labs/dbt-core/issues/ 7411))
|
||||
- Fix v0 ref resolution ([#7408](https://github.com/dbt-labs/dbt-core/issues/7408))
|
||||
- Add --target-path to dbt snapshot command. ([#7418](https://github.com/dbt-labs/dbt-core/issues/7418))
|
||||
- dbt build selection of tests' descendants ([#7289](https://github.com/dbt-labs/dbt-core/issues/7289))
|
||||
- fix groupable node partial parsing, raise DbtReferenceError at runtime for safety ([#7437](https://github.com/dbt-labs/dbt-core/issues/7437))
|
||||
- Fix partial parsing of latest_version changes for downstream references ([#7369](https://github.com/dbt-labs/dbt-core/issues/7369))
|
||||
- Use "add_node" to update depends_on.nodes ([#7453](https://github.com/dbt-labs/dbt-core/issues/7453))
|
||||
- Fix var precedence in configs: root vars override package vars ([#6705](https://github.com/dbt-labs/dbt-core/issues/6705))
|
||||
- Fix inverted `--print/--no-print` flag ([#7517](https://github.com/dbt-labs/dbt-core/issues/7517))
|
||||
- Back-compat for previous return type of 'collect_freshness' macro ([#7489](https://github.com/dbt-labs/dbt-core/issues/7489))
|
||||
- print model version in dbt show if specified ([#7407](https://github.com/dbt-labs/dbt-core/issues/7407))
|
||||
- enable dbt show for seeds ([#7273](https://github.com/dbt-labs/dbt-core/issues/7273))
|
||||
- push down limit filtering to adapter ([#7390](https://github.com/dbt-labs/dbt-core/issues/7390))
|
||||
- Allow missing `profiles.yml` for `dbt deps` and `dbt init` ([#7511](https://github.com/dbt-labs/dbt-core/issues/7511))
|
||||
- `run_results.json` is now written after every node completes. ([#7302](https://github.com/dbt-labs/dbt-core/issues/7302))
|
||||
- Do not rewrite manifest.json during 'docs serve' command ([#7553](https://github.com/dbt-labs/dbt-core/issues/7553))
|
||||
- Pin protobuf to greater than 4.0.0 ([#7565](https://github.com/dbt-labs/dbt-core/issues/7565))
|
||||
- inject sql header in query for show ([#7413](https://github.com/dbt-labs/dbt-core/issues/7413))
|
||||
- Pin urllib3 to ~=1.0 ([#7573](https://github.com/dbt-labs/dbt-core/issues/7573))
|
||||
- Throw error for duplicated versioned and unversioned models ([#7487](https://github.com/dbt-labs/dbt-core/issues/7487))
|
||||
|
||||
### Under the Hood
|
||||
|
||||
- Update docs link in ContractBreakingChangeError message ([#7366](https://github.com/dbt-labs/dbt-core/issues/7366))
|
||||
- Reduce memory footprint of cached statement results. ([#7281](https://github.com/dbt-labs/dbt-core/issues/7281))
|
||||
- Remove noisy parsing events: GenericTestFileParse, MacroFileParse, Note events for static model parsing ([#6671](https://github.com/dbt-labs/dbt-core/issues/6671))
|
||||
- Update --help text for cache-related parameters ([#7381](https://github.com/dbt-labs/dbt-core/issues/7381))
|
||||
- Small UX improvements to model versions: Support defining latest_version in unsuffixed file by default. Notify on unpinned ref when a prerelease version is available. ([#7443](https://github.com/dbt-labs/dbt-core/issues/7443))
|
||||
|
||||
### Contributors
|
||||
- [@AndyBys](https://github.com/AndyBys) ([#6980](https://github.com/dbt-labs/dbt-core/issues/6980))
|
||||
- [@b-luu](https://github.com/b-luu) ([#7289](https://github.com/dbt-labs/dbt-core/issues/7289))
|
||||
- [@dwreeves](https://github.com/dwreeves) ([#7418](https://github.com/dbt-labs/dbt-core/issues/7418))
|
||||
- [@thomasgjerdekog](https://github.com/thomasgjerdekog) ([#7517](https://github.com/dbt-labs/dbt-core/issues/7517))
|
||||
|
||||
## dbt-core 1.6.0-a1 - April 17, 2023
|
||||
|
||||
## Previous Releases
|
||||
|
||||
For information on prior major and minor releases, see their changelogs:
|
||||
|
||||
|
||||
* [1.6](https://github.com/dbt-labs/dbt-core/blob/1.6.latest/CHANGELOG.md)
|
||||
* [1.5](https://github.com/dbt-labs/dbt-core/blob/1.5.latest/CHANGELOG.md)
|
||||
* [1.4](https://github.com/dbt-labs/dbt-core/blob/1.4.latest/CHANGELOG.md)
|
||||
* [1.3](https://github.com/dbt-labs/dbt-core/blob/1.3.latest/CHANGELOG.md)
|
||||
|
||||
@@ -5,10 +5,10 @@
|
||||
1. [About this document](#about-this-document)
|
||||
2. [Getting the code](#getting-the-code)
|
||||
3. [Setting up an environment](#setting-up-an-environment)
|
||||
4. [Running `dbt` in development](#running-dbt-core-in-development)
|
||||
4. [Running dbt-core in development](#running-dbt-core-in-development)
|
||||
5. [Testing dbt-core](#testing)
|
||||
6. [Debugging](#debugging)
|
||||
7. [Adding a changelog entry](#adding-a-changelog-entry)
|
||||
7. [Adding or modifying a changelog entry](#adding-or-modifying-a-changelog-entry)
|
||||
8. [Submitting a Pull Request](#submitting-a-pull-request)
|
||||
|
||||
## About this document
|
||||
@@ -113,7 +113,7 @@ When installed in this way, any changes you make to your local copy of the sourc
|
||||
|
||||
With your virtualenv activated, the `dbt` script should point back to the source code you've cloned on your machine. You can verify this by running `which dbt`. This command should show you a path to an executable in your virtualenv.
|
||||
|
||||
Configure your [profile](https://docs.getdbt.com/docs/configure-your-profile) as necessary to connect to your target databases. It may be a good idea to add a new profile pointing to a local Postgres instance, or a specific test sandbox within your data warehouse if appropriate.
|
||||
Configure your [profile](https://docs.getdbt.com/docs/configure-your-profile) as necessary to connect to your target databases. It may be a good idea to add a new profile pointing to a local Postgres instance, or a specific test sandbox within your data warehouse if appropriate. Make sure to create a profile before running integration tests.
|
||||
|
||||
## Testing
|
||||
|
||||
@@ -171,12 +171,10 @@ Finally, you can also run a specific test or group of tests using [`pytest`](htt
|
||||
|
||||
```sh
|
||||
# run all unit tests in a file
|
||||
python3 -m pytest test/unit/test_graph.py
|
||||
python3 -m pytest tests/unit/test_graph.py
|
||||
# run a specific unit test
|
||||
python3 -m pytest test/unit/test_graph.py::GraphTest::test__dependency_list
|
||||
# run specific Postgres integration tests (old way)
|
||||
python3 -m pytest -m profile_postgres test/integration/074_postgres_unlogged_table_tests
|
||||
# run specific Postgres integration tests (new way)
|
||||
python3 -m pytest tests/unit/test_graph.py::GraphTest::test__dependency_list
|
||||
# run specific Postgres functional tests
|
||||
python3 -m pytest tests/functional/sources
|
||||
```
|
||||
|
||||
@@ -185,9 +183,8 @@ python3 -m pytest tests/functional/sources
|
||||
### Unit, Integration, Functional?
|
||||
|
||||
Here are some general rules for adding tests:
|
||||
* unit tests (`test/unit` & `tests/unit`) don’t need to access a database; "pure Python" tests should be written as unit tests
|
||||
* functional tests (`test/integration` & `tests/functional`) cover anything that interacts with a database, namely adapter
|
||||
* *everything in* `test/*` *is being steadily migrated to* `tests/*`
|
||||
* unit tests (`tests/unit`) don’t need to access a database; "pure Python" tests should be written as unit tests
|
||||
* functional tests (`tests/functional`) cover anything that interacts with a database, namely adapter
|
||||
|
||||
## Debugging
|
||||
|
||||
|
||||
@@ -3,13 +3,13 @@
|
||||
# See `/docker` for a generic and production-ready docker file
|
||||
##
|
||||
|
||||
FROM ubuntu:23.10
|
||||
FROM ubuntu:22.04
|
||||
|
||||
ENV DEBIAN_FRONTEND noninteractive
|
||||
|
||||
RUN apt-get update \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
software-properties-common \
|
||||
software-properties-common gpg-agent \
|
||||
&& add-apt-repository ppa:git-core/ppa -y \
|
||||
&& apt-get dist-upgrade -y \
|
||||
&& apt-get install -y --no-install-recommends \
|
||||
@@ -30,8 +30,8 @@ RUN apt-get update \
|
||||
unixodbc-dev \
|
||||
&& add-apt-repository ppa:deadsnakes/ppa \
|
||||
&& apt-get install -y \
|
||||
python \
|
||||
python-dev \
|
||||
python-is-python3 \
|
||||
python-dev-is-python3 \
|
||||
python3-pip \
|
||||
python3.8 \
|
||||
python3.8-dev \
|
||||
|
||||
@@ -289,6 +289,17 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
"""
|
||||
return self.connections.execute(sql=sql, auto_begin=auto_begin, fetch=fetch, limit=limit)
|
||||
|
||||
def validate_sql(self, sql: str) -> AdapterResponse:
|
||||
"""Submit the given SQL to the engine for validation, but not execution.
|
||||
|
||||
This should throw an appropriate exception if the input SQL is invalid, although
|
||||
in practice that will generally be handled by delegating to an existing method
|
||||
for execution and allowing the error handler to take care of the rest.
|
||||
|
||||
:param str sql: The sql to validate
|
||||
"""
|
||||
raise NotImplementedError("`validate_sql` is not implemented for this adapter!")
|
||||
|
||||
@available.parse(lambda *a, **k: [])
|
||||
def get_column_schema_from_query(self, sql: str) -> List[BaseColumn]:
|
||||
"""Get a list of the Columns with names and data types from the given sql."""
|
||||
@@ -384,7 +395,7 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
return {
|
||||
self.Relation.create_from(self.config, node).without_identifier()
|
||||
for node in manifest.nodes.values()
|
||||
if (node.is_relational and not node.is_ephemeral_model)
|
||||
if (node.is_relational and not node.is_ephemeral_model and not node.is_external_node)
|
||||
}
|
||||
|
||||
def _get_catalog_schemas(self, manifest: Manifest) -> SchemaSearchMap:
|
||||
@@ -415,7 +426,7 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
return info_schema_name_map
|
||||
|
||||
def _relations_cache_for_schemas(
|
||||
self, manifest: Manifest, cache_schemas: Set[BaseRelation] = None
|
||||
self, manifest: Manifest, cache_schemas: Optional[Set[BaseRelation]] = None
|
||||
) -> None:
|
||||
"""Populate the relations cache for the given schemas. Returns an
|
||||
iterable of the schemas populated, as strings.
|
||||
@@ -451,7 +462,7 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
self,
|
||||
manifest: Manifest,
|
||||
clear: bool = False,
|
||||
required_schemas: Set[BaseRelation] = None,
|
||||
required_schemas: Optional[Set[BaseRelation]] = None,
|
||||
) -> None:
|
||||
"""Run a query that gets a populated cache of the relations in the
|
||||
database and set the cache on this adapter.
|
||||
@@ -785,7 +796,6 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
schema: str,
|
||||
identifier: str,
|
||||
) -> List[BaseRelation]:
|
||||
|
||||
matches = []
|
||||
|
||||
search = self._make_match_kwargs(database, schema, identifier)
|
||||
@@ -986,7 +996,7 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
manifest: Optional[Manifest] = None,
|
||||
project: Optional[str] = None,
|
||||
context_override: Optional[Dict[str, Any]] = None,
|
||||
kwargs: Dict[str, Any] = None,
|
||||
kwargs: Optional[Dict[str, Any]] = None,
|
||||
text_only_columns: Optional[Iterable[str]] = None,
|
||||
) -> AttrDict:
|
||||
"""Look macro_name up in the manifest and execute its results.
|
||||
@@ -1063,7 +1073,6 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
schemas: Set[str],
|
||||
manifest: Manifest,
|
||||
) -> agate.Table:
|
||||
|
||||
kwargs = {"information_schema": information_schema, "schemas": schemas}
|
||||
table = self.execute_macro(
|
||||
GET_CATALOG_MACRO_NAME,
|
||||
@@ -1346,7 +1355,8 @@ class BaseAdapter(metaclass=AdapterMeta):
|
||||
rendered_column_constraints = []
|
||||
|
||||
for v in raw_columns.values():
|
||||
rendered_column_constraint = [f"{v['name']} {v['data_type']}"]
|
||||
col_name = cls.quote(v["name"]) if v.get("quote") else v["name"]
|
||||
rendered_column_constraint = [f"{col_name} {v['data_type']}"]
|
||||
for con in v.get("constraints", None):
|
||||
constraint = cls._parse_column_constraint(con)
|
||||
c = cls.process_parsed_constraint(constraint, cls.render_column_constraint)
|
||||
@@ -1452,7 +1462,6 @@ join diff_count using (id)
|
||||
def catch_as_completed(
|
||||
futures, # typing: List[Future[agate.Table]]
|
||||
) -> Tuple[agate.Table, List[Exception]]:
|
||||
|
||||
# catalogs: agate.Table = agate.Table(rows=[])
|
||||
tables: List[agate.Table] = []
|
||||
exceptions: List[Exception] = []
|
||||
|
||||
@@ -9,10 +9,11 @@ from dbt.adapters.base.plugin import AdapterPlugin
|
||||
from dbt.adapters.protocol import AdapterConfig, AdapterProtocol, RelationProtocol
|
||||
from dbt.contracts.connection import AdapterRequiredConfig, Credentials
|
||||
from dbt.events.functions import fire_event
|
||||
from dbt.events.types import AdapterImportError, PluginLoadError
|
||||
from dbt.events.types import AdapterImportError, PluginLoadError, AdapterRegistered
|
||||
from dbt.exceptions import DbtInternalError, DbtRuntimeError
|
||||
from dbt.include.global_project import PACKAGE_PATH as GLOBAL_PROJECT_PATH
|
||||
from dbt.include.global_project import PROJECT_NAME as GLOBAL_PROJECT_NAME
|
||||
from dbt.semver import VersionSpecifier
|
||||
|
||||
Adapter = AdapterProtocol
|
||||
|
||||
@@ -89,7 +90,13 @@ class AdapterContainer:
|
||||
def register_adapter(self, config: AdapterRequiredConfig) -> None:
|
||||
adapter_name = config.credentials.type
|
||||
adapter_type = self.get_adapter_class_by_name(adapter_name)
|
||||
|
||||
adapter_version = import_module(f".{adapter_name}.__version__", "dbt.adapters").version
|
||||
adapter_version_specifier = VersionSpecifier.from_version_string(
|
||||
adapter_version
|
||||
).to_version_string()
|
||||
fire_event(
|
||||
AdapterRegistered(adapter_name=adapter_name, adapter_version=adapter_version_specifier)
|
||||
)
|
||||
with self.lock:
|
||||
if adapter_name in self.adapters:
|
||||
# this shouldn't really happen...
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user