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

Added command to run python script to follow first script example #1710

Open
wants to merge 7 commits into
base: trunk
Choose a base branch
from

Conversation

sadik312
Copy link

@sadik312 sadik312 commented May 7, 2024

User description

Thanks for contributing to the Selenium site and documentation!
A PR well described will help maintainers to review and merge it quickly

Before submitting your PR, please check our contributing guidelines.
Avoid large PRs, and help reviewers by making them as simple and short as possible.

Description

I have added the command to run the selenium file using Python.

Motivation and Context

This was missing from the documentation.

Types of changes

  • Change to the site (I have double-checked the Netlify deployment, and my changes look good)
  • Code example added (and I also added the example to all translated languages)
  • [ x] Improved translation
  • Added new translation (and I also added a notice to each document missing translation)

Checklist

  • [ x] I have read the contributing document.
  • I have used hugo to render the site/docs locally and I am sure it works.

PR Type

documentation, enhancement


Description

  • Added a section in examples/python/README.md to provide users with the command to run a Python script, enhancing the usability of the examples.
  • Updated website_and_docs/content/documentation/webdriver/getting_started/first_script.en.md to link directly to the newly added instructions in the examples README, improving the documentation's interactivity and user guidance.

Changes walkthrough 📝

Relevant files
Documentation
README.md
Add Python Script Execution Instructions                                 

examples/python/README.md

  • Added instructions on how to execute a Python script using the command
    line.
  • +8/-0     
    first_script.en.md
    Link Python Script Execution in Documentation                       

    website_and_docs/content/documentation/webdriver/getting_started/first_script.en.md

  • Updated the Python tab to link to the new code block in the examples
    README.
  • +1/-1     

    💡 PR-Agent usage:
    Comment /help on the PR to get a list of all available PR-Agent tools and their descriptions

    Copy link

    netlify bot commented May 7, 2024

    👷 Deploy request for selenium-dev pending review.

    Visit the deploys page to approve it

    Name Link
    🔨 Latest commit ac1cf3d

    @CLAassistant
    Copy link

    CLAassistant commented May 7, 2024

    CLA assistant check
    All committers have signed the CLA.

    @codiumai-pr-agent-pro codiumai-pr-agent-pro bot added documentation Improvements or additions to documentation enhancement New feature or request labels May 7, 2024
    Copy link
    Contributor

    PR Description updated to latest commit (2c7aeb6)

    Copy link
    Contributor

    PR Review 🔍

    ⏱️ Estimated effort to review [1-5]

    2, because the changes are straightforward and limited to documentation updates. The PR involves adding a new section in a README file and updating a reference in another documentation file.

    🧪 Relevant tests

    No

    ⚡ Possible issues

    No newline at end of file: The modified README.md file does not end with a newline. This is not typically a major issue but can lead to problems with version control systems or when concatenating files.

    🔒 Security concerns

    No

    Copy link
    Contributor

    PR Code Suggestions ✨

    CategorySuggestions                                                                                                                                                       
    Enhancement
    Add a comment explaining the purpose of the script.

    It's recommended to provide a brief explanation or comment about what example_script.py
    does or what it's used for, especially for new users or readers who might not be familiar
    with the script. This can be added just before the command to run the script.

    examples/python/README.md [37]

    +# This script demonstrates basic Python operations.
    python example_script.py

    
    
    Maintainability
    Verify and maintain the accuracy of the linked path in the documentation.

    Ensure that the path specified in the gh-codeblock shortcode correctly points to the
    relevant section of the README. If the line number changes in the README, this reference
    will need to be updated to maintain accuracy.

    website_and_docs/content/documentation/webdriver/getting_started/first_script.en.md [236]

    -{{< gh-codeblock path="examples/python/README.md#L37" >}}
    +{{< gh-codeblock path="examples/python/README.md#L37" >}}  # Ensure this line number is kept updated with any changes in the README.
     

    Copy link
    Member

    @harsha509 harsha509 left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    HI @sadik312 ,

    Thank you the PR. Could you please make similar changes to other translated files too.

    Thanks,
    Sri

    @sadik312
    Copy link
    Author

    sadik312 commented May 7, 2024

    HI @sadik312 ,

    Thank you the PR. Could you please make similar changes to other translated files too.

    Thanks, Sri

    Hi @harsha509 ,
    Yes, I will make the changes to the other files too.
    Thanks

    @sadik312 sadik312 requested a review from harsha509 May 9, 2024 15:09
    Copy link
    Author

    @sadik312 sadik312 left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    I have added README.md files for the examples for:

    • dotnet
    • java
    • kotlin

    I have added the file execution command for:

    • python

    I have also reflected all of the changes in the first_script.en.md file

    Copy link
    Member

    @harsha509 harsha509 left a comment

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Hi @sadik312 ,

    Thank you for the changes. However, there seem to be some conflicts within the PR. Please could you resolve these when you get a chance?

    Thanks,
    Sri

    @sadik312
    Copy link
    Author

    sadik312 commented Jul 9, 2024

    Hi @harsha509,
    I have fixed the conflict. I added the guide for Gradle and someone else added the guide for Maven and I have merged the 2 together. Please let me know if there are any other issues.
    Thank you,
    Sadik

    @sadik312 sadik312 requested a review from harsha509 July 9, 2024 10:36
    3. Install dependecies using dotnet

    ```
    dotnet restore
    Copy link
    Member

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    So, this doc doesn't say/explain on installing and using the dotnet command. Adding prerequisites on dotnet installation steps could be beneficial. Any thoughts ?

    This comment applies for all other lang readme.md!

    Copy link
    Author

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    That does seem like a good idea, however, would the prerequisite also need to include steps for installing on different OS's? For instance, one set of steps for MacOS, one set of steps for Windows.

    Copy link
    Member

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    HI @sadik312 ,

    Pointing to this link on Microsoft Learn should be sufficient, as it covers all cross-platform installation steps for .NET

    Copy link
    Author

    Choose a reason for hiding this comment

    The reason will be displayed to describe this comment to others. Learn more.

    Hi @harsha509,
    I have added the Microsoft Learn link and solved the conflict.
    Thanks

    @harsha509
    Copy link
    Member

    Hi @sadik312 ,

    Also could you please resolve conflicts!

    Thanks,
    Sri

    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    documentation Improvements or additions to documentation enhancement New feature or request Review effort [1-5]: 2
    Projects
    None yet
    Development

    Successfully merging this pull request may close these issues.

    3 participants