Rotten Tomatoes#

Usage#

To access Rotten Tomatoes data points, first ensure you have loaded the Rotten Tomatoes source through:

await phylm.load_source("rt")

Alternatively you can instantiate the Rotten Tomatoes source class directly through:

from phylm.sources import Rt

rot_tom = Rt(raw_title="The Matrix", raw_year=1999)  # raw_year is optional
await rot_tom.load_source()

Reference#

class phylm.sources.rt.Rt(raw_title, raw_year=None)#

Class to abstract a Rotten Tomatoes result.

Parameters:
  • raw_title (str) –

  • raw_year (int | None) –

async load_source(session=None)#

Asynchronously load the data from the source.

Parameters:

session (ClientSession | None) – an optional instance of aiohttp.ClientSession in which to run the request

Return type:

None

property title: str | None#

Return the title.

Returns:

the title of the movie

property tomato_score: str | None#

Return the Tomatometer Score.

Returns:

the tomatometer score

property year: str | None#

Return the year.

Returns:

the year of the movie