Repository: dbt-labs/dbt-core

Issue:
Could the `dataclasses` requirement be relaxed?
### Describe the feature
Not really a feature... not really a bug

the hard requirement on dataclasses (https://github.com/fishtown-analytics/dbt/blob/develop/core/setup.py#L72) makes dbt not really friendly if it has to cohabit with https://github.com/willmcgugan/rich which requires dataclasses `>=0.7`.

I don't think it's a problem for a lot of people but it has come up when I wanted to make `dbt` a requirement of a CLI dbt helper I'm building https://github.com/bitpicky/dbt-sugar

It should be fine for most people as they will most likely have installed dbt prior to installing dbt-sugar so the dependency resolver shouldn't go haywire and we instruct people to install dbt sugar using pipx which installs the tool in its own venv but makes it available globally but it could be funky for some users... Who knows. 

Anyway, I thought I'd raise this and if dbt doesn't need this very specific version the requirement could be relaxed to something like `>=0.6,<0.9` or so.



Discussion:
Hey @bastienboutonnet, this is totally reasonable! The slightly tricky piece here is that the pinned `dataclasses` dependency is coming from a different library, `hologram`; the nice thing is that we also maintain it.

If you wanted to bump the `dataclasses` dependency in dbt, you could:
1. Fork `hologram`, bump [its `dataclasses` dependency](https://github.com/fishtown-analytics/hologram/blob/2adee957e4cd2cddbb845492d40b78ebc5d9b29d/setup.py#L6), open a PR against it
2. Open a PR against fishtown-analytics/dbt that replaces [the versioned `hologram` dependency](https://github.com/fishtown-analytics/dbt/blob/b70fb543f5825744b7705009aef815b8071ab516/core/setup.py#L73) with a `git+` pointer to your fork branch
3. Assuming all CI checks pass in the dbt PR, we can merge the hologram PR, cut a new version, and update the dbt PR to point to that new version.

By the by, both of the `dataclasses` dependencies (in `hologram` and in `dbt-core`) are written as:
```python
'dataclasses==0.6;python_version<"3.7"'
```
The dataclass functionality is native to python 3.7 and above; the `dataclasses` library is just a backport for python 3.6. So users should only be experiencing version conflict if they're using python 3.6. Also, [python 3.6 end of life](https://www.python.org/dev/peps/pep-0494/#lifespan) is December 2021 (9 months from now).

I'm going to close this issue only because it's a duplicate of https://github.com/fishtown-analytics/hologram/issues/39, which I transferred from here to there in January. I'll also add a comment there with the same information I've mentioned above.
@jtcohen6 cool makes sense. I'll do all that at some point this week. And yeah I was aware of the shenanigans for only p36 but I guess until support for 36 is dropped in dbt it probably makes sense to still PR this change for the time being. 

Thanks for the clear instructions!

Resolving patch:
diff --git a/core/setup.py b/core/setup.py
--- a/core/setup.py
+++ b/core/setup.py
@@ -69,8 +69,8 @@ def read(fname):
         'isodate>=0.6,<0.7',
         'json-rpc>=1.12,<2',
         'werkzeug>=0.15,<2.0',
-        'dataclasses==0.6;python_version<"3.7"',
-        'hologram==0.0.13',
+        'dataclasses>=0.6,<0.9;python_version<"3.7"',
+        'hologram==0.0.14',
         'logbook>=1.5,<1.6',
         'mashumaro==2.0',
         'typing-extensions>=3.7.4,<3.8',


Test patch: