App/Model.py
def scrapidx(self, gurl, stime, div, attrs):
        """
        Scrap the gallery index and recover all the elements in it

        Args:
            gurl (str): gallery URL to scrap data
            div (str): HTML <div> keyword to search and scrap
            attrs (dict): decorative attributes in the <div> keyword to refine
            the search and scrap
            stime (float): waiting time between requests

        Raises:
            exp: raise a generic exception if something goes wrong

        Returns:
            ans (bs-obj): div and attrs filtered beatifulsoup object
        """
        try:
            # reset working web page
            self.wpage = Page()
            ans = None

            # getting the basic element list from gallery online index
            self.wpage.get_collection(gurl, stime)
            ans = self.wpage.findin(div, attributes=attrs)

            # returning answer
            return ans

        # exception handling
        except Exception as exp:
            Err.reraise(exp, "Gallery: scrapidx")

        Scrap the gallery index and recover all the elements in it

        Args:
            gurl (str): gallery URL to scrap data
            div (str): HTML <div> keyword to search and scrap
            attrs (dict): decorative attributes in the <div> keyword to refine
            the search and scrap
            stime (float): waiting time between requests

        Raises:
            exp: raise a generic exception if something goes wrong

        Returns:
            ans (bs-obj): div and attrs filtered beatifulsoup object
        


raise a generic exception if something goes wrong

ans (bs-obj): div and attrs filtered beatifulsoup object
raise a generic exception if something goes wrong ans ( bs - obj ) : div and attrs filtered beatifulsoup object
def scrapidx(self, gurl, stime, div, attrs):
        try:
            self.wpage = Page()
            ans = None
            self.wpage.get_collection(gurl, stime)
            ans = self.wpage.findin(div, attributes=attrs)
            return ans
        except Exception as exp:
            Err.reraise(exp, "Gallery: scrapidx")
def scrapidx ( self , gurl , stime , div , attrs ) : try : self . wpage = Page ( ) ans = None self . wpage . get_collection ( gurl , stime ) ans = self . wpage . findin ( div , attributes = attrs ) return ans except Exception as exp : Err . reraise ( exp , "Gallery: scrapidx" )
Scrap the gallery index and recover all the elements in it
Args:
gurl (str): gallery URL to scrap data
div (str): HTML <div> keyword to search and scrap
attrs (dict): decorative attributes in the <div> keyword to refine
the search and scrap
stime (float): waiting time between requests
Scrap the gallery index and recover all the elements in it Args : gurl ( str ) : gallery URL to scrap data div ( str ) : HTML <div > keyword to search and scrap attrs ( dict ) : decorative attributes in the <div > keyword to refine the search and scrap stime ( float ) : waiting time between requests
"""
        Scrap the gallery index and recover all the elements in it

        Args:
            gurl (str): gallery URL to scrap data
            div (str): HTML <div> keyword to search and scrap
            attrs (dict): decorative attributes in the <div> keyword to refine
            the search and scrap
            stime (float): waiting time between requests

        Raises:
            exp: raise a generic exception if something goes wrong

        Returns:
            ans (bs-obj): div and attrs filtered beatifulsoup object
        """ # reset working web page # getting the basic element list from gallery online index # returning answer # exception handling
self
gurl
stime
div
attrs