Firefox works but PhantomJS throws Unable to find element with css selector
<p>I recently changed from <code>webdriver.Firefox()</code> to <code>webdriver.PhantomJS()</code> to get a speed improvement and i started getting some errors when i try to find an element on my datepicker in order to click it after</p>

<pre><code>    self.driver = webdriver.PhantomJS()
    self.driver.set_window_size(1280, 1024)
    self.driver.find_element_by_css_selector(
                "#ui-datepicker-div td.full-selected.full-changeover &gt; a"
            ).click()

Message: {"errorMessage":"Unable to find element with css selector '#ui-datepicker-div td.full-selected.full-changeover &gt; a'","request":{"headers":{"Accept":"application/json","Accept-Encoding":"identity","Connection":"close","Content-Length":"146","Content-Type":"application/json;charset=UTF-8","Host":"127.0.0.1:54784","User-Agent":"Python-urllib/3.5"},"httpVersion":"1.1","method":"POST","post":"{\"value\": \"#ui-datepicker-div td.full-selected.full-changeover &gt; a\", \"sessionId\": \"8b584560-6eb6-11e6-bb4a-77906b62d5cb\", \"using\": \"css selector\"}","url":"/element","urlParsed":{"anchor":"","query":"","file":"element","directory":"/","path":"/element","relative":"/element","port":"","host":"","password":"","user":"","userInfo":"","authority":"","protocol":"","source":"/element","queryKey":{},"chunks":["element"]},"urlOriginal":"/session/8b584560-6eb6-11e6-bb4a-77906b62d5cb/element"}}
Screenshot: available via screen
</code></pre>

<p>I am using <code>selenium==2.53.6</code> and <code>phantomjs==2.1.12</code></p>

<p>UPDATE (here is the code):</p>

<pre><code>def get_price(self, url):
    url = "https://www.homeaway.pt/arrendamento-ferias/p1823902"
    # Lets reset it
    self.driver.get(url)

    wait = WebDriverWait(self.driver, 5)

    prices = defaultdict(list)

    count = 0
    for month in range(self.month_count):
        next_month_iteration = False
        checkin_date = wait.until(
            EC.visibility_of_element_located(
                (
                    By.CSS_SELECTOR,
                    ".quotebar-container input[id=startDateInput]"
                )
            )
        )
        checkin_date.click()

        for counting in range(count):
            try:
                self.driver.execute_script(
                    '$( "a.ui-datepicker-next" ).click()'
                )
            except WebDriverException:
                log.error(
                    'WebDriverException: Message: '
                    'getAvailabilityIndexForDate requires a Date object'
                )
                next_month_iteration = True
                break

        if next_month_iteration:
            # Skip the next iteration cause there was an error
            continue

        year = self.driver.find_element_by_css_selector(
            ".ui-datepicker-year").text

        current_month = self.driver.find_element_by_css_selector(
            ".ui-datepicker-month").text

        log.info(
            'Current Month is "%s"',
            current_month.encode('ascii', 'ignore').decode('utf-8')
        )

        try:
            first_available_checkin_date = wait.until(
                EC.element_to_be_clickable(
                    (
                        By.CSS_SELECTOR,
                        "#ui-datepicker-div td.full-changeover &gt; a"
                    )
                )
            )
        except TimeoutException:
            log.warning('Is there any date available here "%s" ?', url)
            continue
        else:
            log.info(
                'First_available_checkin_date is "%s"',
                first_available_checkin_date.text
            )
            ActionChains(self.driver).move_to_element(
                first_available_checkin_date).perform()

            # self.driver.find_element_by_css_selector(
            #     "#ui-datepicker-div td.full-selected.full-changeover &gt; a"
            # ).click()

            choose_date = wait.until(
                EC.visibility_of_element_located(
                    (
                        By.CSS_SELECTOR,
                        "#ui-datepicker-div td.full-selected.full-changeover &gt; a"
                    )
                )
            )
            choose_date.click()
</code></pre>

<p>Any ideas how i can fix this??</p>

<p>I've reproduced your issue and was able to fix it by <em>maximizing the browser window</em>:</p>

<pre><code>self.driver = webdriver.PhantomJS()
self.driver.maximize_window()
</code></pre>

python python-3.x selenium datepicker phantomjs