kaa.python
Wallaby -- can't find an element by id
On an html page there’s an input with a certain id.
use Wallaby.DSL
{:ok, session} = Wallaby.start_session()
visit(session, "some_url")
|> fill_in("#some_id", with: "Test1") # 1
# |> fill_in(Query.css("#some_id"), with: "Test1") # 2
This throws an exception:
** (FunctionClauseError) no function clause matching in Wallaby.Browser.find/3
(wallaby) lib/wallaby/browser.ex:444: Wallaby.Browser.find(%Wallaby.Session{driver: Wallaby.Phantom, ....
And the # 2 gives this exception:
** (Wallaby.QueryError) Expected to find 1, visible element that matched the css '#some_id' but 0, visible elements were found.
The element-input with id “some_id” exists on a page and is visible.
What can be the matter and how to fix that?
Most Liked
NobbZ
We can’t tell without knowing anything! Similar cases work for me.
Either you show us a minimal project which reproduces the problem or we won’t be able to help you with your problem.
2
Popular in Questions
Hello, I get Persian date from my client and convert it to normal calendar like this:
def jalali_string_to_miladi_english_number(persi...
New
I believe there are people here who are dealing with CSV files import on the daily basis, and since Excel is a really popular tool there ...
New
As the title describes, I’m trying to run Enum.map() over a list of key/value pairs, where the value is a map. My data looks like this:
...
New
This should be a simple problem but I just can’t seem to figure it out. I have a standalone Elixir app that won’t find the database.
Dep...
New
What’s the safe way to decode a JSON string into a struct? I want to avoid calling String.to_atom. Jason.decode can give me a map with st...
New
Hey,
I have a NanoPi-M3 and try to install Elixir on their Ubuntu image. I followed the Raspberry Pi installation instructions from the ...
New
I am using Ecto timestamps with postgres, I can see the timestamps() use the :naive_dateime but for my use case I wanted to store the ti...
New
Sometimes I want to check if the input into a function is not a blank string.
My first approach:
defmodule Example do
def do_stuff(s...
New
I’m not a pro in using Regex and can’t figure out why the following behaviour happens, especially if we take into account the difference ...
New
Hi everyone!
I need implement if…else if…else condition from my elixir code, and anymore of this control flow structures not work proper...
New
Other popular topics
Here are few pieces of (common) Linux knowledge that we use for reasonably small one server apps. We use Ubuntu but this should work for ...
New
Hello, I get Persian date from my client and convert it to normal calendar like this:
def jalali_string_to_miladi_english_number(persi...
New
Hi all,
Trying to get some more clarity over utc_datetime and naive_datetime for Ecto:
https://hexdocs.pm/ecto/Ecto.Schema.html#module-...
New
i’m a new one to elixir
which editor can i use
vs code? or atom?
Thanks! :smiley:
New
This release brings a number of exciting features, including integration with the new Phoenix LiveDashboard and Phoenix LiveView. There h...
New
None of the current solutions worked well for me, so I went ahead and built a user management system from scratch.
This project took far...
New
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible.
total = 10
while total != 0
...
New
Is there a way to get the call stack or stack trace at any point in the code? Not from exceptions, but an expression that returns how the...
New
Original source of discussion: This topic on the Pragmatic Programmers' Functional Web Development with Elixir, OTP, and Phoenix forum.
...
New
We’ve put together this wiki for Phoenix LiveView - please feel free to add any info you feel is worth including.
What is Phoenix LiveV...
New







