Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Data #16

Open
wants to merge 65 commits into
base: master
Choose a base branch
from
Open

Data #16

Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
de05a27
Create main.yml
19121A05E5 Nov 29, 2023
0eacde9
Update main.yml
19121A05E5 Nov 29, 2023
4577284
Update main.yml
19121A05E5 Nov 29, 2023
6c0a587
Update main.yml
19121A05E5 Nov 29, 2023
e4dfba4
Update main.yml
19121A05E5 Nov 29, 2023
19b3826
Update main.yml
19121A05E5 Nov 29, 2023
142fb63
Update main.yml
19121A05E5 Nov 29, 2023
e498791
Create python-app.yml
19121A05E5 Nov 29, 2023
84a924d
Update main.yml
19121A05E5 Nov 29, 2023
02be71e
Update main.yml
19121A05E5 Nov 29, 2023
70c5b0b
Update main.yml
19121A05E5 Nov 29, 2023
b7ed95e
Update python-app.yml
19121A05E5 Nov 29, 2023
0455f20
Update main.yml
19121A05E5 Nov 29, 2023
cf8e571
Update python-app.yml
19121A05E5 Nov 29, 2023
6c38054
Update main.yml
19121A05E5 Nov 29, 2023
46874a0
Update python-app.yml
19121A05E5 Nov 29, 2023
546002e
Update main.yml
19121A05E5 Nov 29, 2023
0eff210
Update python-app.yml
19121A05E5 Nov 29, 2023
b166559
Create requirement.txt
19121A05E5 Nov 29, 2023
59be47d
Update main.yml
19121A05E5 Nov 29, 2023
25fdc43
Update main.yml
19121A05E5 Nov 29, 2023
e39860e
Update python-app.yml
19121A05E5 Nov 29, 2023
cbeb04b
Update main.yml
19121A05E5 Nov 29, 2023
c9707da
Update main.yml
19121A05E5 Nov 29, 2023
5f3d4b6
Update python-app.yml
19121A05E5 Nov 29, 2023
71abaad
Update main.yml
19121A05E5 Nov 29, 2023
fe26283
Update main.yml
19121A05E5 Nov 29, 2023
cfefa56
Update main.yml
19121A05E5 Nov 29, 2023
22dc5bf
Update python-app.yml
19121A05E5 Nov 29, 2023
7cbf28e
Update main.yml
19121A05E5 Nov 29, 2023
aba7491
Update python-app.yml
19121A05E5 Nov 29, 2023
9fe1241
Update main.yml
19121A05E5 Nov 29, 2023
5ee79bd
Update python-app.yml
19121A05E5 Nov 29, 2023
1de3f79
Update main.yml
19121A05E5 Nov 29, 2023
d7b915f
Update python-app.yml
19121A05E5 Nov 29, 2023
397bac6
Update main.yml
19121A05E5 Nov 29, 2023
d8e912d
Update python-app.yml
19121A05E5 Nov 29, 2023
36f5a11
Update __init__.py
19121A05E5 Nov 29, 2023
1724cb7
Update main.yml
19121A05E5 Nov 29, 2023
78debb6
Update python-app.yml
19121A05E5 Nov 29, 2023
1e51827
Update __init__.py
19121A05E5 Nov 29, 2023
06c79a2
Update python-app.yml
19121A05E5 Nov 29, 2023
4a7a5d3
Update main.yml
19121A05E5 Nov 29, 2023
5c58415
Update main.yml
19121A05E5 Nov 29, 2023
4400f37
Update __init__.py
19121A05E5 Nov 29, 2023
993acb7
Update main.yml
19121A05E5 Nov 29, 2023
6971bc4
Update main.yml
19121A05E5 Nov 30, 2023
47ddddf
Update python-app.yml
19121A05E5 Nov 30, 2023
10fa58d
Update main.yml
19121A05E5 Nov 30, 2023
ed57097
Update python-app.yml
19121A05E5 Nov 30, 2023
d3203cd
Update main.yml
19121A05E5 Nov 30, 2023
a03cf53
Update main.yml
19121A05E5 Nov 30, 2023
a7e43de
Update python-app.yml
19121A05E5 Nov 30, 2023
a1a8436
Update __init__.py
19121A05E5 Nov 30, 2023
7436386
Update __init__.py
19121A05E5 Nov 30, 2023
c29cf56
Update __init__.py
19121A05E5 Nov 30, 2023
896e71f
Update __init__.py
19121A05E5 Nov 30, 2023
a51f48e
Update main.yml
19121A05E5 Nov 30, 2023
5050b7c
Update python-app.yml
19121A05E5 Nov 30, 2023
8ee1928
Update __init__.py
19121A05E5 Nov 30, 2023
5c0e207
Update __init__.py
19121A05E5 Nov 30, 2023
2c6ea3e
Update main.yml
19121A05E5 Nov 30, 2023
c7ffe75
Update __init__.py
19121A05E5 Nov 30, 2023
01d1ac4
Update main.yml
19121A05E5 Nov 30, 2023
e69b5dc
Update __init__.py
19121A05E5 Nov 30, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Run main.py every 2 minutes

on:
schedule:
- cron: '*/4 * * * *' # At every 2nd minute of every hour

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repo content
uses: actions/checkout@v2

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11.0'

- name: Install Python packages
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade rbiparser


- name: Execute Python script
run: |
echo "Checking current directory contents:"
ls -al
pwd

echo "Running rbiparser download -d "./xls":"
rbiparser download -d "./xls"


32 changes: 32 additions & 0 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
name: Run main.py every 2 minutes

on:
schedule:
- cron: '*/4 * * * *' # At every 2nd minute of every hour

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout repo content
uses: actions/checkout@v2

- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: '3.11.0'

- name: Install Python packages
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade rbiparser


- name: Execute Python script
run: |
echo "Checking current directory contents:"
ls -al

echo "Running rbiparser download -d "./xls":"
rbiparser download -d "./xls"

4 changes: 2 additions & 2 deletions rbiparser/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
import glob
import string


try:
from urlparse import urlparse
except ImportError:
Expand Down Expand Up @@ -68,7 +69,6 @@

exclude_words = ["to", "the", "at", "of", "by", "as", "for", "via"]


def get_sheet_urls(url):
"""Scrapes the RBI page and gets the list of .xlsx sheets."""
r = requests.get(url)
Expand All @@ -77,7 +77,7 @@ def get_sheet_urls(url):

# Extract the urls.
s = soup(r.content, "lxml")
links = s.findAll("a", href=re.compile("\.xlsx$"))
links = s.find_all("a", href=re.compile(".\.xls."))

if len(links) < 1:
raise Exception("Couldn't find any .xlsx urls")
Expand Down
6 changes: 6 additions & 0 deletions requirement.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
rbiparser
requests
xlrd
beautifulsoup4
click
lxml