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

Fix environment variable leak for unused formatters #338

Merged
merged 2 commits into from
Jul 19, 2024

Conversation

krassowski
Copy link
Contributor

Fixes #337

Previously the environment was polluted by rpy2 variables even when no R formatter (styler nor formatR) was installed. This was first happening on import of formatters.py and then when checking if these formatters are importable because each of these steps contained an rpy2 import.

With this change rpy2 is only imported when needed.

@krassowski
Copy link
Contributor Author

All green!

@andrewfulton9
Copy link

Code looks good, and tests passed for me!

@krassowski krassowski merged commit 7cead40 into jupyterlab-contrib:master Jul 19, 2024
5 checks passed
@krassowski krassowski added the bug Something isn't working label Jul 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

importing rpy2.robjects leaks LD_LIBRARY_PATH to kernels
2 participants