Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Selenium 4.5.0 | NotImplementedError when attempting actions on disabled elements

Đang mở
#1,790 4 bình luận 2 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
35/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
python
Lĩnh vực
testing-qa

Hướng nghiên cứu

Bắt đầu bằng cách chạy bản tái hiện được cung cấp của Robot Framework với Selenium 4.4.3 và 4.5.0, sau đó xem lại issue Selenium và commit được liên kết về hành vi của phần tử bị vô hiệu hóa. Theo dõi keyword của SeleniumLibrary được Get Selected List Label sử dụng và xác minh rằng tùy chọn được chọn có thể được đọc từ một danh sách bị vô hiệu hóa mà không làm hỏng các thao tác khác.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

For issues

Steps to reproduce the issue

Using selenium 4.5.0+

*** Settings ***
Library   SeleniumLibrary

*** Test Cases ***
Test Disabled Elements
    Open Browser   https://demos.jquerymobile.com/1.4.5/forms-disabled    browser=chrome
    Maximize Browser Window
    ${list_selection}=        Get Selected List Label   //select[@id='select-native-5']
    List Selection Should Be  //select[@id='select-native-5']      ${list_selection}

Error messages and additional information

NotImplementedError: Select element is disabled and may not be used.

This seems to be caused by a change in https://github.com/SeleniumHQ/selenium/issues/10812 (specifically https://github.com/SeleniumHQ/selenium/commit/e2bbb54153370ee56b43e7260aef5923ec826be4#diff-48418bfd0178cef4e4f71bf60506204d33e152281f0bb5a670b9295689b6e01e) and from the looks of the discussion it may not be changed unless there is good cause so I wanted to bring it up here in case there were opinions on the matter. This more than likely extends to quite a few keywords and I am not quite sure what the solution would be on the SeleniumLibrary side.

Expected behavior and actual behavior

We should be able to get the selected option regardless of whether the list is disabled or not. Using the previous selenium release (4.4.3) works just fine.

Environment

Browser: Chrome latest
Browser driver: chrome latest
Operating System: Windows 10
Libraries

  • Robot Framework: 5.0.1
  • Selenium: 4.5.0
  • SeleniumLibrary: 6.0.0
  • Interpreter: Python 3.9
Ngôn ngữ chính
Python
Star
1.5k
Fork
787
Chỉ số merge pull request
Không có pull request nào được merge trong 30 ngày

Chuẩn bị môi trường

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của robotframework/SeleniumLibrary

Tất cả issue của robotframework/SeleniumLibrary

Issue tương tự

Thêm issue về Python

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.