-
Notifications
You must be signed in to change notification settings - Fork 0
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
Uprev to 3.10, namespace clarification #173
Conversation
# TODO: upgrade to 3.10+, use kw_only flag to subclass a dataclass for generating source/target | ||
code_sources = [ | ||
CCC(column_name="category", is_array=True, filter_priority=False), | ||
CCC(column_name="code", is_array=False, filter_priority=False), | ||
CCC(column_name="interpretation", is_array=True, filter_priority=False), | ||
CCC(column_name="valuecodeableconcept", is_array=False, filter_priority=False), | ||
] | ||
for source in code_sources: | ||
source.source_table = "observation" | ||
source.target_table = f"core__observation_dn_{source.column_name}" | ||
@dataclass(kw_only=True) | ||
class ObsConfig(sql_utils.CodeableConceptConfig): | ||
source_table: str = "observation" | ||
|
||
def __post_init__(self): | ||
self.target_table = f"core__observation_dn_{self.column_name}" |
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.
This (and the kw_only addition to the parent class) is the only true functional change in this PR.
I found this article helpful in understanding the why behind this
80d50b9
to
8a1447e
Compare
8a1447e
to
26b586b
Compare
fc7b43b
to
a3b90d2
Compare
python-version: 3.9 | ||
python-version: '3.10' |
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.
small point here: we're only testing on 3.10, but as a command line CLI that doesn't ship with its own python in a docker image (i.e. unlike the ETL) - we should probably test on all supported pythons
Doesn't need to happen on this PR - I filed #174 for it.
This PR makes the following changes:
Checklist
docs/
) needs to be updated