diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 4906f4c..0000000 --- a/.gitignore +++ /dev/null @@ -1,145 +0,0 @@ - -# Created by https://www.toptal.com/developers/gitignore/api/python -# Edit at https://www.toptal.com/developers/gitignore?templates=python - -### Python ### -# Byte-compiled / optimized / DLL files -__pycache__/ -*.py[cod] -*$py.class - -# C extensions -*.so - -# Distribution / packaging -.Python -build/ -develop-eggs/ -dist/ -downloads/ -eggs/ -.eggs/ -lib/ -lib64/ -parts/ -sdist/ -var/ -wheels/ -share/python-wheels/ -*.egg-info/ -.installed.cfg -*.egg -MANIFEST - -# PyInstaller -# Usually these files are written by a python script from a template -# before PyInstaller builds the exe, so as to inject date/other infos into it. -*.manifest -*.spec - -# Installer logs -pip-log.txt -pip-delete-this-directory.txt - -# Unit test / coverage reports -htmlcov/ -.tox/ -.nox/ -.coverage -.coverage.* -.cache -nosetests.xml -coverage.xml -*.cover -*.py,cover -.hypothesis/ -.pytest_cache/ -cover/ - -# Translations -*.mo -*.pot - -# Django stuff: -*.log -local_settings.py -db.sqlite3 -db.sqlite3-journal - -# Flask stuff: -instance/ -.webassets-cache - -# Scrapy stuff: -.scrapy - -# Sphinx documentation -docs/_build/ - -# PyBuilder -.pybuilder/ -target/ - -# Jupyter Notebook -.ipynb_checkpoints - -# IPython -profile_default/ -ipython_config.py - -# pyenv -# For a library or package, you might want to ignore these files since the code is -# intended to run in multiple environments; otherwise, check them in: -# .python-version - -# pipenv -# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control. -# However, in case of collaboration, if having platform-specific dependencies or dependencies -# having no cross-platform support, pipenv may install dependencies that don't work, or not -# install all needed dependencies. -#Pipfile.lock - -# PEP 582; used by e.g. github.com/David-OConnor/pyflow -__pypackages__/ - -# Celery stuff -celerybeat-schedule -celerybeat.pid - -# SageMath parsed files -*.sage.py - -# Environments -.env -.venv -env/ -venv/ -ENV/ -env.bak/ -venv.bak/ - -# Spyder project settings -.spyderproject -.spyproject - -# Rope project settings -.ropeproject - -# mkdocs documentation -/site - -# mypy -.mypy_cache/ -.dmypy.json -dmypy.json - -# Pyre type checker -.pyre/ - -# pytype static type analyzer -.pytype/ - -# Cython debug symbols -cython_debug/ - -# End of https://www.toptal.com/developers/gitignore/api/python diff --git a/ReadMe.MD b/ReadMe.MD new file mode 100644 index 0000000..e87cb9b --- /dev/null +++ b/ReadMe.MD @@ -0,0 +1 @@ +trying to get only content from web (news websites for now) diff --git a/app.py b/app.py deleted file mode 100644 index f356223..0000000 --- a/app.py +++ /dev/null @@ -1,54 +0,0 @@ -from flask import Flask,render_template,url_for,request,redirect -from flask_restful import Resource, Api,reqparse - -app = Flask(__name__) -api = Api(app) - - -parser = reqparse.RequestParser() -parser.add_argument('keywords') -parser.add_argument('websites') - - - - - -@app.route("/",methods=["GET","POST"]) -def index(): - if request.method == "POST": - keywords = request.form["keywords"] - websites = request.form["websites"] - return redirect(url_for("loading",keywords=keywords,websites=websites)) - return render_template("starter.html") - - -@app.route("/loading", methods=["GET","POST"]) -def loading(): - keywords = request.args["keywords"] - websites = request.args["websites"] - - return render_template("spinner.html",keywords = keywords,websites = websites) - - -class Sentences(Resource): - def get(self): - return {'hello': 'world'} - - - def post(self): - args = parser.parse_args() - - keywords = args["keywords"].split(',') - websites = args["websites"].split(',') - - return {"fuck" : "YOU"} - - - - - -api.add_resource(Sentences, '/hello_world') - - -if "__main__" == __name__: - app.run() diff --git a/pipelines.py b/pipelines.py deleted file mode 100644 index e69de29..0000000 diff --git a/requirements.txt b/requirements.txt deleted file mode 100644 index 76a47db..0000000 --- a/requirements.txt +++ /dev/null @@ -1,41 +0,0 @@ -aniso8601==9.0.1 -attrs==21.2.0 -Automat==20.2.0 -cffi==1.15.0 -click==8.0.3 -constantly==15.1.0 -cryptography==36.0.1 -cssselect==1.1.0 -Flask==2.0.2 -Flask-RESTful==0.3.9 -h2==3.2.0 -hpack==3.0.0 -hyperframe==5.2.0 -hyperlink==21.0.0 -idna==3.3 -incremental==21.3.0 -itemadapter==0.4.0 -itemloaders==1.0.4 -itsdangerous==2.0.1 -Jinja2==3.0.3 -jmespath==0.10.0 -lxml==4.7.1 -MarkupSafe==2.0.1 -parsel==1.6.0 -priority==1.3.0 -Protego==0.1.16 -pyasn1==0.4.8 -pyasn1-modules==0.2.8 -pycparser==2.21 -PyDispatcher==2.0.5 -pyOpenSSL==21.0.0 -pytz==2021.3 -queuelib==1.6.2 -Scrapy==2.5.1 -service-identity==21.1.0 -six==1.16.0 -Twisted==21.7.0 -typing-extensions==4.0.1 -w3lib==1.22.0 -Werkzeug==2.0.2 -zope.interface==5.4.0 diff --git a/spiders.py b/spiders.py deleted file mode 100644 index a347f0c..0000000 --- a/spiders.py +++ /dev/null @@ -1 +0,0 @@ -#spiders diff --git a/templates/base.html b/templates/base.html deleted file mode 100644 index 712b482..0000000 --- a/templates/base.html +++ /dev/null @@ -1,29 +0,0 @@ - - -
- - - - - - - -