Subversion Repositories SmartDukaan

Rev

Rev 16172 | Rev 16177 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 16172 Rev 16176
Line 301... Line 301...
301
                sc = ShopCluesScraper.ShopCluesScraper()
301
                sc = ShopCluesScraper.ShopCluesScraper()
302
                url = transformUrl(url, 5)
302
                url = transformUrl(url, 5)
303
                productInfo = sc.read(url)
303
                productInfo = sc.read(url)
304
            except Exception as e:
304
            except Exception as e:
305
                print traceback.print_exc()
305
                print traceback.print_exc()
-
 
306
                productInfo = {}
306
                productInfo['price'] = 0.0
307
                productInfo['price'] = 0.0
307
                productInfo['inStock'] = 0
308
                productInfo['inStock'] = 0
308
                productInfo['isCod'] = 0
309
                productInfo['isCod'] = 0
309
                
310
                
310
            print "LowestPrice ",productInfo['price']
311
            print "LowestPrice ",productInfo['price']
Line 530... Line 531...
530
        info = returnLatestPrice(item, item['source_id'],False)
531
        info = returnLatestPrice(item, item['source_id'],False)
531
        print info
532
        print info
532
 
533
 
533
def main():
534
def main():
534
    print datetime.now()
535
    print datetime.now()
535
    print "retuned %s"%(str(getLatestPriceById(22804)))
536
    print "retuned %s"%(str(getLatestPriceById(24010)))
536
    print datetime.now()
537
    print datetime.now()
537
if __name__=='__main__':
538
if __name__=='__main__':
538
    main()
539
    main()
539
    
540