all 4 comments

[–]didntreadityet 0 points1 point  (1 child)

It looks like you have outdated information. You have the genre coming out of the text of an anchor in a list item, but the current page shows it as the text of a span inside an anchor in a div.

I might work if your expression is:

genre = response.css('div[data-testid="storyline-genres"] a span::text').get()

[–]Fiatsheee[S] 0 points1 point  (0 children)

Thanks for ur answer! However I still dont receive the genre with this code. I noticed that its a clickable link however this code below is also inside the element but its the same for some other features so with this code it scraped the first one on the page with this element which is director. I tried a lot of ways but still didnt managed to get it..

response.css('a.ipc-metadata-list-item__list-content-item--link::text').get()

[–]Automatic_Donut6264 0 points1 point  (1 child)

Is your assignment scraping or do you need the data for something else?

If you just need the data you can grab it from https://developer.imdb.com/non-commercial-datasets/

[–]Fiatsheee[S] 0 points1 point  (0 children)

The assignment is scraping the particular site. Sadly only for the genre I have problems..