Commits

A S committed db4b116

Upate script clean up

  • Participants
  • Parent commits b0b103f

Comments (0)

Files changed (2)

File pypysite/data/downloads.json

             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-linux.tar.bz2", 
             "pypy-1.8-linux.tar.bz2", 
             "12.0 MB", 
-            "13 days ago", 
-            "437"
+            "16 days ago", 
+            "507"
         ], 
         "linux64": [
             "Linux", 
             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-linux64.tar.bz2", 
             "pypy-1.8-linux64.tar.bz2", 
             "13.5 MB", 
-            "13 days ago", 
-            "865"
+            "16 days ago", 
+            "980"
         ], 
         "osx64": [
             "Mac", 
             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-osx64.tar.bz2", 
             "pypy-1.8-osx64.tar.bz2", 
             "13.6 MB", 
-            "12 days ago", 
-            "984"
+            "15 days ago", 
+            "1083"
         ], 
         "win32": [
             "Windows", 
             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-win32.zip", 
             "pypy-1.8-win32.zip", 
             "16.8 MB", 
-            "13 days ago", 
-            "1795"
+            "16 days ago", 
+            "2152"
         ]
     }, 
     "sandbox": {
             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-sandbox-linux.tar.bz2", 
             "pypy-1.8-sandbox-linux.tar.bz2", 
             "3.7 MB", 
-            "7 days ago", 
-            "18"
+            "10 days ago", 
+            "23"
         ], 
         "sandbox-linux64": [
             "Linux", 
             "https://bitbucket.org/pypy/pypy/downloads/pypy-1.8-sandbox-linux64.tar.bz2", 
             "pypy-1.8-sandbox-linux64.tar.bz2", 
             "4.7 MB", 
-            "7 days ago", 
-            "39"
+            "10 days ago", 
+            "52"
         ]
     }, 
     "source": [

File pypysite/update.py

+# -*- coding: utf-8 -*-
+
+"""
+    pypy.update
+    ~~~~~~~~~~~
+
+    Data scraping from bitucket
+
+    - Downloads
+    - Compatibility
+"""
+
 import config
 import requests
-from bs4 import BeautifulSoup, SoupStrainer
 from flask import json
 
+
 # Downloads
 # ~~~~~~~~~
 
+from bs4 import BeautifulSoup, SoupStrainer
+
 # Naming
 systems = {
     'linux': {
 print('Downloads response code: ' + str(dr.status_code))
 
 # Soupify
-downloads_rows = BeautifulSoup(dr.content, parse_only=SoupStrainer(id='uploaded-files'))
+downloads_rows = BeautifulSoup(dr.content,
+    parse_only=SoupStrainer(id='uploaded-files'))
 
 
 # Helper functions
 j.close()
 
 
-# Compatibiliy
-# ~~~~~~~~~~~~
+# Compatibility
+# ~~~~~~~~~~~~~
 
 compatibility_url = 'https://api.bitbucket.org/1.0/repositories/pypy/compatibility/wiki/Home'