How can I get a integer from indeed pages

I am trying to make web scrapper after having Python class. And I have a problem in understanding about structure of web-page. To make a list of page numberm, I need to extract interger form webpage. But, now the structure of webpage is changed. Every number is in <li>. but the each of them is marked as different way. For example, Interger 1 is in <b> tag and the others are in <a> tag In this case, which way is the best way to extract those intergers with one line code?

I tried with:

pagination = indeed_soup.find("ul", {"class": "pagination-list"})["aria-label"]
pagination = indeed_soup.find("ul", {"class": "pagination-list"}).get_text

But I can’t get a right result. Please, if is there any idea, help me. Thank you

enter image description here

Answer

To get numbers from page-navigation, you can use next example:

import requests
from bs4 import BeautifulSoup

url = "https://es.indeed.com/ofertas?as_and=python&as_phr=&as_any=&as_not=&as_ttl=&as_cmp=&jt=all&st=&salary=&radius=25&l=Espa%C3%B1a&fromage=any&limit=50&sort=&psf=advsrch&from=advancedsearch"
soup = BeautifulSoup(requests.get(url).content, "html.parser")

print(
    [
        int(t)
        for li in soup.select(".pagination-list li")
        if (t := li.get_text(strip=True))
    ]
)

Prints:

[1, 2, 3, 4, 5]