-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1465 from fishtown-analytics/dev/merge-in-0.13.1
merge 0.13.1
- Loading branch information
Showing
32 changed files
with
440 additions
and
44 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,10 +12,29 @@ Before you can develop dbt effectively, you should set up the following: | |
|
||
We strongly recommend setting up [pyenv](https://github.com/pyenv/pyenv) and its [pyenv-virtualenv](https://github.com/pyenv/pyenv-virtualenv) plugin. This setup will make it much easier for you to manage multiple Python projects in the medium to long term. | ||
|
||
There is more documentation in each of those links on how to get set up, but the commands you'll need to run will be: | ||
``` | ||
brew install pyenv | ||
echo -e 'if command -v pyenv 1>/dev/null 2>&1; then\n eval "$(pyenv init -)"\nfi' >> ~/.bash_profile | ||
exec "$SHELL" | ||
brew install pyenv-virtualenv | ||
eval "$(pyenv init -)" | ||
eval "$(pyenv virtualenv-init -)" | ||
``` | ||
|
||
### python | ||
|
||
By default, `pyenv` has only one python version installed and it's the `system` python - the one that comes with your OS. You don't want that. Instead, use `pyenv install 3.6.5` to install a more recent version. dbt supports up to Python 3.6 at the time of writing (and will soon support Python 3.7) | ||
|
||
If you get the following error: | ||
``` | ||
import pip | ||
zipimport.ZipImportError: can't decompress data; zlib not available | ||
make: *** [install] Error 1 | ||
``` | ||
|
||
You can solve it by running `brew install zlib`, then try `pyenv install 3.6.5` again. | ||
|
||
To get a full (very long!) list of versions available, you can do `pyenv install -l` and look for the versions defined by numbers alone - the others are variants of Python and outside the scope of this document. | ||
|
||
### docker and docker-compose | ||
|
@@ -42,6 +61,15 @@ git clone [email protected]:fishtown-analytics/dbt.git | |
|
||
But it really does not matter where you put it as long as you remember it. | ||
|
||
|
||
### Installing postgres locally | ||
|
||
For testing, and later in the examples in this document, you may want to have `psql` available so you can poke around in the database and see what happened. We recommend that you use [homebrew](https://brew.sh/) for that on macOS, and your package manager on Linux. You can install any version of the postgres client that you'd like. So on macOS, with homebrew setup: | ||
|
||
``` | ||
brew install postgresql | ||
``` | ||
|
||
### Setting up your virtualenv | ||
|
||
Set up a fresh virtualenv with pyenv-virtualenv for dbt: | ||
|
@@ -55,15 +83,6 @@ pyenv activate | |
|
||
This makes a new virtualenv based on python 3.6.5 named `dbt36`, and tells pyenv that when you're in the `dbt` directory it should automatically use that virtualenv. | ||
|
||
|
||
### Installing postgres locally | ||
|
||
For testing, and later in the examples in this document, you may want to have `psql` available so you can poke around in the database and see what happened. We recommend that you use [homebrew](https://brew.sh/) for that on macOS, and your package manager on Linux. You can install any version of the postgres client that you'd like. So on macOS, with homebrew setup: | ||
|
||
``` | ||
brew install postgresql | ||
``` | ||
|
||
## Testing | ||
|
||
Getting the dbt integration tests set up in your local environment will be very helpful as you start to make changes to your local version of dbt. The section that follows outlines some helpful tips for setting up the test environment. | ||
|
@@ -130,7 +149,7 @@ If you open a PR as a non-contributor, these tests won't run automatically. Some | |
|
||
Sometimes, you're going to have to pretend to be an end user to reproduce bugs and stuff. So that means manually setting up some stuff that the test harness takes care of for you. | ||
|
||
### installation | ||
### Installation | ||
|
||
First make sure that you setup your `virtualenv` as described in section _Setting up your environment_. | ||
|
||
|
@@ -161,7 +180,7 @@ talk: | |
target: default | ||
``` | ||
|
||
There's a sample you can look at in the `dbt` folder (`sample.profiles.yml`) but it's got a lot of extra and as a developer, you really probably only want to test against your local postgres container. The basic idea is that there are multiple 'profiles' (`talk`, in this case) and within those each profile has one or more 'targets' (`default`, in this case), and each profile has a default target. You can specify what profile you want to use with the `--profile` flag, and which target with the `--target` flag. If you want to be really snazzy, dbt project files actually specify their target, and if you match up your dbt project `profile` key with your `profiles.yml` profile names you don't have to use `--profile` (and if you like your profile's default target, no need for `--target` either). | ||
There's a sample you can look at in the `dbt` [docs](https://docs.getdbt.com/reference#profile) but it's got a lot of extra and as a developer, you really probably only want to test against your local postgres container. The basic idea is that there are multiple 'profiles' (`talk`, in this case) and within those each profile has one or more 'targets' (`default`, in this case), and each profile has a default target. You can specify what profile you want to use with the `--profile` flag, and which target with the `--target` flag. If you want to be really snazzy, dbt project files actually specify their target, and if you match up your dbt project `profile` key with your `profiles.yml` profile names you don't have to use `--profile` (and if you like your profile's default target, no need for `--target` either). | ||
|
||
## Example | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<p align="center"> | ||
<img src="https://github.com/fishtown-analytics/dbt/blob/master/etc/dbt-horizontal.png?raw=true" alt="dbt logo"/> | ||
</p> | ||
|
||
**[dbt](https://www.getdbt.com/)** (data build tool) enables data analysts and engineers to transform their data using the same practices that software engineers use to build applications. | ||
|
||
dbt is the T in ELT. Organize, cleanse, denormalize, filter, rename, and pre-aggregate the raw data in your warehouse so that it's ready for analysis. | ||
|
||
## dbt-bigquery | ||
|
||
The `dbt-bigquery` package contains all of the code required to make dbt operate on a BigQuery database. For | ||
more information on using dbt with BigQuery, consult [the docs](https://docs.getdbt.com/docs/profile-bigquery). | ||
|
||
|
||
## Find out more | ||
|
||
- Check out the [Introduction to dbt](https://dbt.readme.io/docs/introduction). | ||
- Read the [dbt Viewpoint](https://dbt.readme.io/docs/viewpoint). | ||
|
||
## Join thousands of analysts in the dbt community | ||
|
||
- Join the [chat](http://slack.getdbt.com/) on Slack. | ||
- Find community posts on [dbt Discourse](https://discourse.getdbt.com). | ||
|
||
## Reporting bugs and contributing code | ||
|
||
- Want to report a bug or request a feature? Let us know on [Slack](http://slack.getdbt.com/), or open [an issue](https://github.com/fishtown-analytics/dbt/issues/new). | ||
- Want to help us build dbt? Check out the [Contributing Getting Started Guide](/CONTRIBUTING.md) | ||
|
||
## Code of Conduct | ||
|
||
Everyone interacting in the dbt project's codebases, issue trackers, chat rooms, and mailing lists is expected to follow the [PyPA Code of Conduct](https://www.pypa.io/en/latest/code-of-conduct/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,22 @@ | ||
#!/usr/bin/env python | ||
from setuptools import find_packages | ||
from distutils.core import setup | ||
import os | ||
|
||
package_name = "dbt-bigquery" | ||
package_version = "0.14.0a1" | ||
description = """The bigquery adapter plugin for dbt (data build tool)""" | ||
|
||
this_directory = os.path.abspath(os.path.dirname(__file__)) | ||
with open(os.path.join(this_directory, 'README.md')) as f: | ||
long_description = f.read() | ||
|
||
setup( | ||
name=package_name, | ||
version=package_version, | ||
description=description, | ||
long_description=description, | ||
long_description=long_description, | ||
long_description_content_type='text/markdown', | ||
author="Fishtown Analytics", | ||
author_email="[email protected]", | ||
url="https://github.com/fishtown-analytics/dbt", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,32 @@ | ||
<p align="center"> | ||
<img src="https://github.com/fishtown-analytics/dbt/blob/master/etc/dbt-horizontal.png?raw=true" alt="dbt logo"/> | ||
</p> | ||
|
||
**[dbt](https://www.getdbt.com/)** (data build tool) enables data analysts and engineers to transform their data using the same practices that software engineers use to build applications. | ||
|
||
dbt is the T in ELT. Organize, cleanse, denormalize, filter, rename, and pre-aggregate the raw data in your warehouse so that it's ready for analysis. | ||
|
||
## dbt-postgres | ||
|
||
The `dbt-postgres` package contains all of the code required to make dbt operate on a Postgres database. For | ||
more information on using dbt with Postgres, consult [the docs](https://docs.getdbt.com/docs/profile-postgres). | ||
|
||
|
||
## Find out more | ||
|
||
- Check out the [Introduction to dbt](https://dbt.readme.io/docs/introduction). | ||
- Read the [dbt Viewpoint](https://dbt.readme.io/docs/viewpoint). | ||
|
||
## Join thousands of analysts in the dbt community | ||
|
||
- Join the [chat](http://slack.getdbt.com/) on Slack. | ||
- Find community posts on [dbt Discourse](https://discourse.getdbt.com). | ||
|
||
## Reporting bugs and contributing code | ||
|
||
- Want to report a bug or request a feature? Let us know on [Slack](http://slack.getdbt.com/), or open [an issue](https://github.com/fishtown-analytics/dbt/issues/new). | ||
- Want to help us build dbt? Check out the [Contributing Getting Started Guide](/CONTRIBUTING.md) | ||
|
||
## Code of Conduct | ||
|
||
Everyone interacting in the dbt project's codebases, issue trackers, chat rooms, and mailing lists is expected to follow the [PyPA Code of Conduct](https://www.pypa.io/en/latest/code-of-conduct/). |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,16 +1,22 @@ | ||
#!/usr/bin/env python | ||
from setuptools import find_packages | ||
from distutils.core import setup | ||
import os | ||
|
||
package_name = "dbt-postgres" | ||
package_version = "0.14.0a1" | ||
description = """The postgres adpter plugin for dbt (data build tool)""" | ||
|
||
this_directory = os.path.abspath(os.path.dirname(__file__)) | ||
with open(os.path.join(this_directory, 'README.md')) as f: | ||
long_description = f.read() | ||
|
||
setup( | ||
name=package_name, | ||
version=package_version, | ||
description=description, | ||
long_description=description, | ||
long_description_content_type='text/markdown', | ||
author="Fishtown Analytics", | ||
author_email="[email protected]", | ||
url="https://github.com/fishtown-analytics/dbt", | ||
|
Oops, something went wrong.