Always None-check query response fields before interacting. A missing element comes back as None on the response object, not an exception - so response.search_box.click() on a page without that element throws an AttributeError on None, far from the real cause. Check for None right after the query and handle the not-found case explicitly, especially on pages where the element is conditional.

Context: AgentQL official docs (First steps): the response object mirrors your query structure, and a field is None when the described element was not found on the page - it does not raise.