Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

V0.19.0 rc1 #39

Closed
wants to merge 17 commits into from
Closed

V0.19.0 rc1 #39

wants to merge 17 commits into from

Conversation

dataders
Copy link
Contributor

@dataders dataders commented Jan 14, 2021

testing the inheritance. dependent on dbt-msft/dbt-sqlserver#81

@dataders
Copy link
Contributor Author

dataders commented Jan 14, 2021

UPDATE

this was fixed by correcting the imports (and using rc2)

so now i'm getting a solid clue of an error for test_dbt_snapshot_strategy_timestamp. There's no table/view name getting populated inside the parentheses is aliased to sbq, which returns the error below issue:

1 of 3 ERROR snapshotting dbt_test_210114095430086859553799.cc_all_snapshot [ERROR in 3.71s]
Parse error at line: 17, column: 5: Incorrect syntax near ')'.

simplified query

here's a gist of the full query

select *,
        
    CONVERT(VARCHAR(32), HashBytes('MD5', 
        coalesce(CONVERT(varchar, id, 121), '')  + '|' + 
    
        coalesce(CONVERT(varchar, CONVERT(DATETIME2, '2021-01-14 09:57:35.897000'), 121), '') 
    ), 2)
 as dbt_scd_id,
        CONVERT(DATETIME2, '2021-01-14 09:57:35.897000') as dbt_updated_at,
        CONVERT(DATETIME2, '2021-01-14 09:57:35.897000') as dbt_valid_from,
        nullif(CONVERT(DATETIME2, '2021-01-14 09:57:35.897000'), CONVERT(DATETIME2, '2021-01-14 09:57:35.897000')) as dbt_valid_to
    from (
        
    ) sbq

setup.py Outdated
Comment on lines 59 to 62
install_requires=[
"dbt-sqlserver==0.18.1",
"dbt-sqlserver @ git+https://github.com/dbt-msft/dbt-sqlserver.git@v0.19.0rc2#egg=dbt-sqlserver",
],
dependency_links=['git+https://github.com/dbt-msft/dbt-sqlserver.git@v0.19.0rc2'],
Copy link
Contributor Author

@dataders dataders Jan 15, 2021

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@mikaelene i'm having the exact same issue that you were having a few days ago. and this must be the reason. I'm confused as I thought that we're pinned to a specific tag that's available on GitHub... 🤷

Can you please push a release to PyPI from the current commit of your v.0.19.0 branch? Because the version of dbt-sqlserver in that branch is currently v0.19.0rc2, when you upload to PyPI it will detect automatically that it is a pre-release so users can't download it unless they add the --pre option to pip. Check out dbt-core on PyPI for an example.

This will simplify the dependency management and let us know immediately if dbt-synapse is indeed ready for v.0.19.0 or not. I have a hunch that there's still one weird thing going on...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@jtcohen6 tangent -- one day I'd like to see you y'all at Fishtown run your tests locally with reproducible envs without decimating your CircleCI credits... Do you use tox always to run tests locally? or pytest? how do you guarantee the exact same virtualenvs as in remote (i'm a conda person myself)? do y'all install with -e all dependencies or just one? do you have all your repos open in the same workspace or separately? It's hard for me to keep it all straight!

also not sure if it matters, but it looks like we're 100% overspent on our free quota and the month's only halfway over! lol let that be our impetus to learn to confidently test without relying on CircleCi so much...
image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I am running them locally with PyCharm. Let PyCharm create an env and then pip install -r requirements.txt. Then just hit pytest from the terminal :-)

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fair! Perhaps an office hours or "how-to" session on contributing to packages/core/plugins...

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

that'd be cool for sure. i've certainly learned a great deal about Python package delivery (pytest, tox, pip, package dependencies, PyPI, Abstract base classes, jinja namespaces, GitHub tags and releases, CircleCI, linux). Things will certainly will get easier once dbt-sqlserver and dbt-synapse can play nicely together in the same env. I just have a nagging feeling I'm missing some obvious ways to make things easier.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For example, why in the most recent CircleCI logs, is dbt-synapse still being install from github? I just removed that reference in the last commit (or so I thought?)

integration-synapse installed: [...] dbt-core==0.19.0rc2,dbt-sqlserver==0.19.0rc2,-e git+git@github.com:dbt-msft/dbt-synapse.git@663b09ede4a0a9c4ea6a91d0cc92b4fcb072d67d#egg=dbt_synapse
integration-synapse create: /root/project/.tox/integration-synapse
integration-synapse installdeps: -r/root/project/requirements.txt, -e.
integration-synapse installed: agate==1.6.1,appdirs==1.4.4,attrs==20.3.0,azure-core==1.10.0,azure-identity==1.5.0,Babel==2.9.0,black==20.8b1,certifi==2020.6.20,cffi==1.14.4,chardet==3.0.4,click==7.1.2,colorama==0.4.3,cryptography==3.3.1,dbt-core==0.19.0rc2,dbt-sqlserver==0.19.0rc2,-e git+git@github.com:dbt-msft/dbt-synapse.git@663b09ede4a0a9c4ea6a91d0cc92b4fcb072d67d#egg=dbt_synapse,decorator==4.4.2,distlib==0.3.1,filelock==3.0.12,flake8==3.8.4,hologram==0.0.12,idna==2.9,importlib-metadata==3.4.0,iniconfig==1.1.1,isodate==0.6.0,Jinja2==2.11.2,json-rpc==1.13.0,jsonschema==3.1.1,leather==0.3.3,Logbook==1.5.3,MarkupSafe==1.1.1,mccabe==0.6.1,minimal-snowplow-tracker==0.0.2,msal==1.8.0,msal-extensions==0.3.0,mypy-extensions==0.4.3,networkx==2.5,packaging==20.8,parsedatetime==2.6,pathspec==0.8.1,pluggy==0.13.1,portalocker==1.7.1,py==1.10.0,pycodestyle==2.6.0,pycparser==2.20,pyflakes==2.2.0,PyJWT==1.7.1,pyodbc==4.0.30,pyparsing==2.4.7,pyrsistent==0.17.3,pytest==6.2.1,pytest-dbt-adapter==0.4.0,python-dateutil==2.8.1,python-slugify==4.0.1,pytimeparse==1.1.8,pytz==2020.5,PyYAML==3.13,regex==2020.11.13,requests==2.23.0,six==1.15.0,sqlparse==0.3.1,text-unidecode==1.3,toml==0.10.2,tox==3.2.0,typed-ast==1.4.2,typing-extensions==3.7.4.3,urllib3==1.25.11,virtualenv==20.3.1,Werkzeug==0.16.1,zipp==3.4.0
integration-synapse runtests: PYTHONHASHSEED='1585998269'
integration-synapse runtests: commands[0] | /bin/bash -c '/root/project/.tox/integration-synapse/bin/python -m pytest -v test/integration

@dataders
Copy link
Contributor Author

focus on #40

@dataders dataders closed this Jan 18, 2021
@sdebruyn sdebruyn deleted the v0.19.0-rc1 branch June 4, 2022 08:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants