-
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
Hard deprecate connect_to_etn()
and reexport
#313
Hard deprecate connect_to_etn()
and reexport
#313
Conversation
I moved the character parsing from paste to an assertion, kept the case lowering.
…of github.com:inbo/etn into 303-deprecate-connect_to_etn-instead-of-not-exporting
…ECK error. This function call is no longer needed.
Refactor create connection
…_to_etn-instead-of-not-exporting
Ready for review |
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.
One comment. Would extend test with function call with parameters.
Made requested changes, ready for a second look if you have time. I'd appreciate your opinion on the changes to the vignette. If not, let me know and we can merge. |
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.
I updated the vignette (please verify it's correct) and simplified the test to just make use of lifecycle::expect_deprecated()
I'm not a 100% sure how often you'll be prompted for them, but at least every time you click "Quit Session" so I think that's close enough. Thanks for the review Peter! |
The 2 tests in
I'm looking into it, but would be grateful for any ideas! |
Co-authored-by: Maëlle Salmon <maelle.salmon@yahoo.se>
I documented the behaviour of the tests and added skips for them, I'm now merging so this doesn't block the beta release. I'm also planning on creating a minimal test package to see if I can replicate this behaviour, and if so, I'll go looking for help on https://forum.posit.co/ |
Thank you both for the constructive comments and contributions! |
Previously on this dev branch,
connect_to_etn()
was no longer exported, and used internally as a helper. In this PR, a new helper is created to take over this work, andconnect_to_etn()
is re-exported, but hard deprecated: it always returns a lifecycle warning message, and it only returns NULL. All SQL helpers were adapted to use this new helper. Tests were changed over so bothconnect_to_etn()
and the new helper are covered.We decided to do it this way so older scripts that have
con <- connect_to_etn()
at the top are met with a deprecation message rather than a missing function.connect_to_etn()
is no longer neccesairy. Functions that need credentials will prompt the user for them.I also added to NEWS and made a small change to a vignette.