-
-
Notifications
You must be signed in to change notification settings - Fork 25.9k
The copy button on install copies an extensive comman including env activation #26948
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
Comments
cc @ArturoAmorQ |
@adrinjalali can you tell me where can i find the code for this issue I want to create PR |
Yep apparently the directive is copying all the instructions from the different OS. |
@glemaitre I want to know in which file the code is written for the above issue code? |
@MuhammadNizamani you can try to look for the test around it in the project and find the file. |
Maybe @tuscland may have an idea on how to solve this issue. |
Hi all, |
The snippet is from this page: https://scikit-learn.org/stable/install.html Which comes from this rst file: https://raw.githubusercontent.com/scikit-learn/scikit-learn/main/doc/install.rst |
I think what happens is that the copy button selects all the text inside a <div class="highlight"><pre><code
><span class="sk-expandable" data-packager="pip" data-os="linux" data-venv="">python3 -m venv sklearn-venv</span
><span class="sk-expandable" data-packager="pip" data-os="windows" data-venv="">python -m venv sklearn-venv</span
><span class="sk-expandable" data-packager="pip" data-os="mac" data-venv="">python -m venv sklearn-venv</span
><span class="sk-expandable" data-packager="pip" data-os="linux" data-venv="">source sklearn-venv/bin/activate</span
><span class="sk-expandable" data-packager="pip" data-os="mac" data-venv="">source sklearn-venv/bin/activate</span
><span class="sk-expandable" data-packager="pip" data-os="windows" data-venv="">sklearn-venv\Scripts\activate</span
><span class="sk-expandable" data-packager="pip" data-venv="">pip install -U scikit-learn</span
><span class="sk-expandable" data-packager="pip" data-os="mac" data-venv="no">pip install -U scikit-learn</span
><span class="sk-expandable" data-packager="pip" data-os="windows" data-venv="no">pip install -U scikit-learn</span
><span class="sk-expandable" data-packager="pip" data-os="linux" data-venv="no">pip3 install -U scikit-learn</span
><span class="sk-expandable" data-packager="conda">conda create -n sklearn-env -c conda-forge scikit-learn</span
><span class="sk-expandable" data-packager="conda">conda activate sklearn-env</span
></code></pre></div> to: <div class="highlight">
<pre class="sk-expandable" data-packager="pip" data-os="linux" data-venv=""><code>
<span>python3 -m venv sklearn-venv</span>
</pre></code>
<pre class="sk-expandable" data-packager="pip" data-os="windows" data-venv=""><code>
<span >python -m venv sklearn-venv</span>
</pre></code>
... etc ...
</div> so that we have one A related thought: how should one write these kinds of "changing text" so that screenreaders understand what is happening? Maybe by fixing that we also fix the copy button? |
Hello Tim, I take a look at this. |
Describe the issue linked to the documentation
https://scikit-learn.org/stable/install.html
Above link will lead you to the sklearn downlanding for link .
when you link copy link button it will copy
python3 -m venv sklearn-venvpython -m venv sklearn-venvpython -m venv sklearn-venvsource sklearn-venv/bin/activatesource sklearn-venv/bin/activatesklearn-venv\Scripts\activatepip install -U scikit-learnpip install -U scikit-learnpip install -U scikit-learnpip3 install -U scikit-learnconda create -n sklearn-env -c conda-forge scikit-learnconda activate sklearn-env
instead of
pip3 install -U scikit-learn
if this is the issue so please issue i want to create a pull request for it and tell in which file this issue reside
Thanks
Suggest a potential alternative/fix
By resoving above issue
The text was updated successfully, but these errors were encountered: