Skip to content

fix: require error definitions, use next in HTMLElements#result, and fix Driver#log_event= error raising - #1140

Merged
KazuCocoa merged 2 commits into
appium:masterfrom
hoanle0126:fix/html-elements-reduce-and-driver-errors
Oct 28, 2026
Merged

KazuCocoa merged 2 commits into
appium:masterfrom
hoanle0126:fix/html-elements-reduce-and-driver-errors

Conversation

@hoanle0126

Copy link
Copy Markdown
Contributor

Proposed changes

  • Require error in lib/appium_lib/appium.rb so Appium::NoDriverInstanceError and Appium::ArgumentError are loaded when appium_lib is required instead of raising NameError: uninitialized constant Appium::Driver::NoDriverInstanceError.
  • Use next r instead of return r inside the @elements_in_order.reduce block in Appium::Common::HTMLElements#result so an element without attributes (such as <html>) skips only that element instead of returning early from #result.
  • Raise NoDriverInstanceError and ::Appium::Core::Error::ArgumentError, '...' (with a comma) in Appium::Driver#log_event= instead of calling ::Appium::Core::Error::ArgumentError(...) as a method.

Types of changes

  • Bugfix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)

@hoanle0126
hoanle0126 requested a review from KazuCocoa as a code owner October 26, 2026 08:35
Comment thread lib/appium_lib/appium.rb Resolved
@KazuCocoa
KazuCocoa merged commit 1b28f90 into appium:master Oct 28, 2026
7 of 8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants