initial commmit; boilerplate

This commit is contained in:
Daniil Fajnberg 2021-11-21 21:44:03 +01:00
commit a8745964a7
9 changed files with 108 additions and 0 deletions

10
.coveragerc Normal file
View File

@ -0,0 +1,10 @@
[run]
source = src/
branch = true
omit =
.venv/*
[report]
fail_under = 100
show_missing = True
skip_covered = True

10
.gitignore vendored Normal file
View File

@ -0,0 +1,10 @@
# Virtual environment
/.venv/
# PyCharm:
/.idea/
# Distribution / packaging:
*.egg-info/
# Python cache:
__pycache__/
# Tests:
.coverage

21
LICENSE Normal file
View File

@ -0,0 +1,21 @@
MIT License
Copyright (c) 2021 Daniil & Maximilian Fajnberg
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.

22
README.md Normal file
View File

@ -0,0 +1,22 @@
# MarketWatch financials scraper
Scrapes any company's financials from [MarketWatch.com](https://www.marketwatch.com/), which includes income statement, balance sheet, and cash flow statement.
Asynchronous HTTP requests are currently used by default.
### Dependencies
- [Python](https://www.python.org/) 3.8+
Should run on most Linux/Windows systems. Tested on Arch.
### Building
Clone this repo, install `build` via pip, then run `pip -m build`
from the repository's root directory. This should produce a `dist/`
subdirectory with a wheel (build) and archive (source) distribution.
The resulting `whl`-file can be installed via `pip install path/dist/***.whl`.
### Running
...

3
coverage.sh Executable file
View File

@ -0,0 +1,3 @@
#!/usr/bin/env sh
coverage erase && coverage run -m unittest discover && coverage report

6
pyproject.toml Normal file
View File

@ -0,0 +1,6 @@
[build-system]
requires = [
"setuptools>=42",
"wheel"
]
build-backend = "setuptools.build_meta"

2
requirements/common.txt Normal file
View File

@ -0,0 +1,2 @@
beautifulsoup4
aiohttp

2
requirements/dev.txt Normal file
View File

@ -0,0 +1,2 @@
-r common.txt
coverage

32
setup.cfg Normal file
View File

@ -0,0 +1,32 @@
[metadata]
name = mwfin
version = 0.0.1
author = Daniil & Maximilian F.
author_email = mail@placeholder123.to
description = Scraper for MarketWatch company financials
long_description = file: README.md
long_description_content_type = text/markdown
url = https://git.fajnberg.de/daniil/mwfin
project_urls =
Bug Tracker = https://github.com/daniil-berg/mwfin/issues
classifiers =
Programming Language :: Python :: 3
License :: OSI Approved :: MIT License
Operating System :: OS Independent
keywords = webscraping, html, markup, dom, scraper, attributes, tags, stocks, finance
[options]
package_dir =
= src
packages = find:
python_requires = >=3.8
install_requires =
beautifulsoup4
aiohttp
[options.extras_require]
tests =
coverage
[options.packages.find]
where = src