Beispiel #1
0
class ContentPage(ot.DataPage):
    data = ot.Raw()
    add_one = ot.Lambda(lambda t: t + 1)

    @ot.extractor
    def slow(self):
        time.sleep(1)
        return 123
class ContentPage(ot.DataPage):
    key = ot.Attribute()
    data = ot.Raw()
    add_one = ot.Lambda(lambda t: t + 1)

    def __init__(self, i):
        super().__init__(i)
        self['key'] = i
Beispiel #3
0
class ContentPage(ot.DataPage):
    data = ot.Raw()
    add_one = ot.Lambda(lambda t: t + 1)
class MyPage(ot.DataPage):
    _loader__rate_limit = '2/2'

    my_number = ot.Raw()