-
Notifications
You must be signed in to change notification settings - Fork 5
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
feat(#72): Replace hardcoded values with env variables #73
Conversation
@lorerod @njuguna-n I tried to do similar changes as you did for BRAC Models. I didn't manage to get the unit tests pass, though. Do they pass for BRAC Models? There is still a |
@andrablaj, the unit tests are passing on CI. Do you mean locally? |
@lorerod, sorry for not being clear! Yes, I meant that the tests fail when I run them locally. Here's the error:
I get the same error for the @witash confirmed that he is not encountering the error when running the unit tests locally for |
@andra, hi!
How are you running the tests locally?
This env var is setup in this line of Let me know if it works for you. |
@lorerod I tried the steps in the |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Left a few minor comments
@@ -12,4 +10,4 @@ | |||
SELECT | |||
doc->>'type' AS type, | |||
* | |||
FROM {{ import_couchdb_data }} | |||
FROM v1.{{ env_var('POSTGRES_TABLE') }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we use the schema defined in env variables here as well?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As mentioned here, I didn't manage to get that working. I will try again tomorrow.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For some reason, replacing v1
with {{ env_var('POSTGRES_SCHEMA') }}
throws a dbt.medic table does not exist
error. I will leave this hardcoded for now to have the pipeline running correctly, and will open a separate issue to remove the hardcoded v1.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hello @andrablaj! Thank you for making the improvements. I have a few minor suggestions to make.
Before we merge this to the main branch, I think we need to ensure that the cht-sync
tests pass with this version of cht-pipeline
, right @njuguna-n?
I can check when you have a final version of this, and if the tests are not passing, I will create an issue on that repository and make sure this is mentioned as a dependency.
What do you think?
@lorerod yes, I agree that we need to have tests passing. |
Thanks both for your comments! @lorerod I ran the |
Lorena OOO until mid March. Her suggestions were all addressed.
# 1.0.0 (2024-08-27) ### Bug Fixes * **#145:** docker compose instead of docker-compose ([b4ecea6](b4ecea6)), closes [#145](#145) ### Features * **#148:** add automatic releases and versioning ([#152](#152)) ([52cf12a](52cf12a)), closes [#148](#148) * **#72:** Replace hardcoded values with env variables ([#73](#73)) ([3dfa8e7](3dfa8e7)), closes [#72](#72)
🎉 This issue has been resolved in version 1.0.0 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Closes #72