Did I find the right examples for you? yes no

All Samples(21)  |  Call(14)  |  Derive(0)  |  Import(7)

        def urlLinks(url):
    r = requests.get(url)
    content = r.text
    if r.status_code != 200:
        return []

    soup = BeautifulSoup(content)
    # do not return a generator but an array, so we can store it for later use
    return [link for link in soup.findAll('a')]
        


src/m/o/mozregression-0.16/mozregression/runinbound.py   mozregression(Download)
from utils import urlLinks, strsplit, get_date
import re
import sys
from runnightly import FennecNightly, FirefoxNightly, NightlyRunner, parseBits
from inboundfinder import getBuildBaseURL
    def getBuildUrl(self, timestamp):
        url = "%s%s/" % (getBuildBaseURL(bits=self.bits), timestamp)
        for link in urlLinks(url):
            href = link.get("href")
            if re.match(self.buildRegex, href):
    def getBuildUrl(self, timestamp):
        url = "%s%s/" % (getBuildBaseURL(appName=self.appName), timestamp)
        for link in urlLinks(url):
            href = link.get("href")
            if re.match(self.buildRegex, href):

src/m/o/mozregression-HEAD/mozregression/runinbound.py   mozregression(Download)
from utils import urlLinks, strsplit, get_date
import re
import sys
from runnightly import FennecNightly, FirefoxNightly, NightlyRunner, parseBits
from inboundfinder import getBuildBaseURL
    def getBuildUrl(self, timestamp):
        url = "%s%s/" % (getBuildBaseURL(bits=self.bits), timestamp)
        matches = []
        for link in urlLinks(url):
            href = link.get("href")
    def getBuildUrl(self, timestamp):
        url = "%s%s/" % (getBuildBaseURL(appName=self.appName), timestamp)
        matches = []
        for link in urlLinks(url):
            href = link.get("href")

src/m/o/mozregression-0.16/mozregression/downloader.py   mozregression(Download)
import sys
import datetime
from utils import download_url, urlLinks
import re
 
            monthlinks = self._monthlinks[cachekey]
        else:
            monthlinks = urlLinks(url)
            self._monthlinks[cachekey] = monthlinks
 
            if re.match(linkRegex, dirhref):
                # now parse the page for the correct build url
                for link in urlLinks(url + dirhref):
                    href = link.get("href")
                    if re.match(self.buildRegex, href):

src/m/o/mozregression-0.16/mozregression/runnightly.py   mozregression(Download)
from mozrunner import Runner
from optparse import OptionParser
from utils import strsplit, get_date, download_url, urlLinks
from ConfigParser import ConfigParser
 
            monthlinks = self._monthlinks[cachekey]
        else:
            monthlinks = urlLinks(url)
            self._monthlinks[cachekey] = monthlinks
 
            if re.match(linkRegex, dirhref):
                # now parse the page for the correct build url
                for link in urlLinks(url + dirhref):
                    href = link.get("href")
                    if re.match(self.buildRegex, href):

src/m/o/mozregression-HEAD/mozregression/runnightly.py   mozregression(Download)
from mozrunner import Runner
from optparse import OptionParser
from utils import strsplit, get_date, download_url, urlLinks
from ConfigParser import ConfigParser
 
            monthlinks = self._monthlinks[cachekey]
        else:
            monthlinks = urlLinks(url)
            self._monthlinks[cachekey] = monthlinks
 
            if re.match(linkRegex, dirhref):
                # now parse the page for the correct build url
                for link in urlLinks(url + dirhref):
                    href = link.get("href")
                    if re.match(self.buildRegex, href):

src/m/o/mozregression-0.16/mozregression/inboundfinder.py   mozregression(Download)
import re
import json
from utils import urlLinks
import mozinfo
import sys
                     filter(lambda l: l.isdigit(), # sometimes we have links like "latest"
                            map(lambda l: l.get('href').strip('/'),
                                urlLinks(baseURL))))
    timestampsInRange = filter(lambda t: t > (starttime - range) and
                               t < (endtime + range), timestamps)
    revisions = [] # timestamp, order pairs
    for timestamp in timestampsInRange:
        for link in urlLinks("%s%s/" % (baseURL, timestamp)):

src/m/o/mozregression-HEAD/mozregression/inboundfinder.py   mozregression(Download)
import re
import json
from utils import urlLinks
import mozinfo
import sys
                     filter(lambda l: l.isdigit(), # sometimes we have links like "latest"
                            map(lambda l: l.get('href').strip('/'),
                                urlLinks(baseURL))))
    timestampsInRange = filter(lambda t: t > (starttime - range) and
                               t < (endtime + range), timestamps)
    revisions = [] # timestamp, order pairs
    for timestamp in timestampsInRange:
        for link in urlLinks("%s%s/" % (baseURL, timestamp)):