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

Run crawl (of WARC) tests on travis #3

Merged
merged 18 commits into from Apr 15, 2019

Conversation

Projects
None yet
2 participants
@ikreymer
Copy link
Member

commented Apr 9, 2019

No description provided.

ikreymer added some commits Apr 9, 2019

fix automated crawl tests, enable travis testing with existing WARC
enable headless mode for testing
setup: switch to setuptools from poetry
live tests: additional cleanup / separation of test data:
- remove loglevel debug from default image
- rename bootstrap-compose to start-compose and add stop-compose
- rename webarchive to test-webarchive, don't redownload .tar.gz if already have it
- remove ujson dep from tests, simplify test util functions
- switch to chrome:73, add logging while waiting

@ikreymer ikreymer requested a review from N0taN3rd Apr 9, 2019

ikreymer added some commits Apr 10, 2019

better_exceptions
cchardet

This comment has been minimized.

Copy link
@N0taN3rd

N0taN3rd Apr 11, 2019

Member

cchardet (for aiohttp), pandantic, and starlette (we directly import these) should stay.

This comment has been minimized.

Copy link
@ikreymer

ikreymer Apr 13, 2019

Author Member

Adding pydantic and starlette actually breaks the install, because the latest versions aren't compatible with latest fastapi. We don't want the latest version of these or even to worry about which version to use, but rather use whichever version is installed when fastapi is installed.

mypy.ini Outdated
@@ -1,32 +0,0 @@
[mypy]

This comment has been minimized.

Copy link
@N0taN3rd

N0taN3rd Apr 11, 2019

Member

we use mypy via flake8-mypy :)

@@ -11,6 +11,9 @@
from starlette.exceptions import HTTPException
from ujson import dumps as ujson_dumps

import logging

This comment has been minimized.

Copy link
@N0taN3rd

N0taN3rd Apr 11, 2019

Member

is there any reason why we are jacking uvicorns logger rather than using our own?

Also we should keep all imports sorted like below and move the logger variable below all

Suggested change
import logging
from __future__ import annotations
import logging
import uuid
from asyncio import AbstractEventLoop, gather as aio_gather, get_event_loop
from functools import partial
from typing import Dict, List, Optional, Union
from urllib.parse import urlsplit
from aiohttp import AsyncResolver, ClientSession, TCPConnector
from aioredis import Redis
from starlette.exceptions import HTTPException
from ujson import dumps as ujson_dumps
from .schema import CrawlInfo, CreateCrawlRequest, StartCrawlRequest
from .utils import env, init_redis
__all__ = ['Crawl', 'CrawlManager']
logger = logging.getLogger('uvicorn')
README.md Outdated
@@ -10,8 +10,7 @@ crawlmanager

To use crawlmanager, run:
```bash
poetry install
# or "pip install -r reqs/requirements.txt -r reqs/dev-requirements.txt"
python setup.py install

This comment has been minimized.

Copy link
@N0taN3rd

N0taN3rd Apr 11, 2019

Member

setup.py is not required unless distributing or installing this project globally
rather should be pip install -r requirements since these directions are for running within the repo

Suggested change
python setup.py install
pip install -r requirements.txt -r dev-requirements.txt
@@ -229,7 +229,7 @@ venv.bak/
localCompose
pip-wheel-metadata
scripts
tests
#tests

This comment has been minimized.

Copy link
@N0taN3rd

N0taN3rd Apr 11, 2019

Member

I think it would be best to not include the tests in the docker container.
If we do need them it should be a separate dev container

ikreymer added some commits Apr 13, 2019

@ikreymer ikreymer merged commit 0f6e3bb into master Apr 15, 2019

0 of 2 checks passed

continuous-integration/travis-ci/pr The Travis CI build is in progress
Details
continuous-integration/travis-ci/push The Travis CI build is in progress
Details

@ikreymer ikreymer deleted the travis-tests branch Apr 15, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.