Welcome to HolyScrap’s documentation!

Contents:

hsdb module

hsdb.add_anime(name, id)[source]

This function adds an anime to the database and print weither it works or not

Parameters:
  • name – Name of the anime to be added
  • id – Episod number
hsdb.delete_anime(name)[source]

This function deletes an anime and print weither it works or not

Parameters:name – Name of the anime to be deleted
hsdb.get_animes()[source]

This function returns all the animes in the database

Returns:A tuple of animes
hsdb.get_animes_for_print()[source]

This function prints all the animes in the database

hsdb.get_sqlite_connexion()[source]

This function returns the sqlite connection

Returns:The connetion with the database
hsdb.init_sql()[source]

This function intializes the database

hsdb.update_anime(uName, uId)[source]

This function updates an anime print a message and send an SMS

Parameters:
  • uName – Name of the anime to be updated
  • uId – Episod number to be updated

hshelper module

hshelper.replace_special_chars(str_to_translate)[source]

This function replaces all special characters with underscore

Parameters:str_to_translate – String containing special characters
Returns:Well formatted string
hshelper.usage()[source]

This function prints the usage of HolyScrap

hsrun module

hsrun.run(thread)[source]

This function starts the processus of downloading animes in an other thread

hsrun.run_one_time()[source]

This function starts the processus of downloading animes

hsurl module

hsurl.download_torrent(torrent)[source]

This function downloads a torrent

Parameters:torrent – Name of the torrent to be downloaded
hsurl.get_html_from_anime(name)[source]

This function gets the content of an HTML page

Parameters:name – The anime name (e.g: One Piece 717)
Returns:The readed response or false
hsurl.search_result(html, query)[source]

This function searchs for torrent file in an HTML document

Parameters:
  • html – The HTML document
  • query – Tuple containing information about the anime (name, episod number)
Returns:

A tuple containing the HTML name, link of the torrent, name of the anime and the episod number

main module

Indices and tables