### What happened?

My "wait.until" function worked fine yesterday, but all a sudden now is not runnable.

Error message: reason: no instance(s) of type variable(s) V exist so that ExpectedCondition<WebElement> conforms to Function<? super WebDriver, V>

I have looked it up online, and people said it is related to the inconsistent versions of Guava and Selenium. However, I have already checked my project structure, and there are no other extra versions of Guava and Selenium.


### How can we reproduce the issue?


I am not sure how to reproduce since I don't know what's wrong. 
The only thing I can provide is what I am using. Sorry and thanks.

Please see my pom.xml below:

```shell     
   <dependency>
            <groupId>org.seleniumhq.selenium</groupId>
            <artifactId>selenium-java</artifactId>
            <version>4.1.3</version>
        </dependency>

  <dependency>
            <groupId>com.google.guava</groupId>
            <artifactId>guava</artifactId>
            <version>31.1-jre</version>
     </dependency>

```

The code I have run:
```shell
public void visibilityOfElementLocatedByXpath(String xpath){
        WebDriverWait wait = new WebDriverWait(driver, Duration.ofSeconds(10));
        wait.until(ExpectedConditions.visibilityOfElementLocated(By.xpath(xpath)));
    }
```


In addition, I am using JAVA 17, maven project with IntelliJ IDEA with MacBook Air (M1,2020).
```
java: method until in class org.openqa.selenium.support.ui.FluentWait<T> cannot be applied to given types;
  required: java.util.function.Function<? super org.openqa.selenium.WebDriver,V>
  found:    org.openqa.selenium.support.ui.ExpectedCondition<org.openqa.selenium.WebElement>
  reason: cannot infer type-variable(s) V
    (argument mismatch; org.openqa.selenium.support.ui.ExpectedCondition<org.openqa.selenium.WebElement> cannot be converted to java.util.function.Function<? super org.openqa.selenium.WebDriver,V>)
```


### Operating System

MacBook Air (M1,2020) - macOS Monterey 12.2.1

### Selenium version

4.1.3

### What are the browser(s) and version(s) where you see this issue?

Not-related

### What are the browser driver(s) and version(s) where you see this issue?

Not-related

### Are you using Selenium Grid?

No
package org.openqa.selenium.support.ui;
import com.google.common.base.Function;
import org.openqa.selenium.WebDriver;
/**
 * Models a condition that might reasonably be expected to eventually evaluate to something that is
 * neither null nor false. Examples would include determining if a web page has loaded or that an
 * element is visible.
 * <p>
 * Note that it is expected that ExpectedConditions are idempotent. They will be called in a loop by
 * the {@link WebDriverWait} and any modification of the state of the application under test may
 * have unexpected side-effects.
 *
 * @param <T> The return type
 */
public interface ExpectedCondition<T> extends Function<WebDriver, T> {}