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

even more rotation automation #7053

Merged
merged 1 commit into from Feb 13, 2020
Merged

even more rotation automation #7053

merged 1 commit into from Feb 13, 2020

Conversation

@silasary
Copy link
Member

silasary commented Feb 13, 2020

No description provided.

@TravisBuddy

This comment has been minimized.

Copy link

TravisBuddy commented Feb 13, 2020

Travis tests have failed

Hey @silasary,
Please read the following log in order to understand the failure reason.
It'll be awesome if you fix what's wrong and commit the changes.

1st Build

View build log

echo $CMD
python dev.py tests
$CMD
$ $CMD
CONFIG: web_cache=.web_cache
CONFIG: redis_enabled=True
CONFIG: redis_host=localhost
CONFIG: redis_port=6379
CONFIG: redis_db=0
CONFIG: whoosh_index_dir=whoosh_index
CONFIG: image_dir=./images
CONFIG: production=False
>>>> Running tests with ""
Fetching https://api.scryfall.com/bulk-data (cache ok)
CONFIG: slow_fetch=10.0
CONFIG: magic_database=cards
CONFIG: mysql_host=localhost
CONFIG: mysql_port=3306
CONFIG: mysql_user=root
CONFIG: mysql_passwd=
CONFIG: slow_query=999.0
Creating database cards
Database update required
Before BEGIN ([])
After BEGIN (['update_database'])
Fetching https://api.scryfall.com/sets (cache ok)
Fetching https://archive.scryfall.com/json/scryfall-default-cards.json (cache ok)
Fetching https://pennydreadfulmtg.github.io/modo-bugs/bugs.json (cache ok)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'update_bugged_cards'])
UNKNOWN BUGGED CARD: Eldrazi Spawn
UNKNOWN BUGGED CARD: Eldrazi Spawn
Before COMMIT (['update_database', 'update_bugged_cards'])
After COMMIT (['update_database'])
Fetching http://whatsinstandard.com/api/v6/standard.json (cache ok)
Fetching https://pennydreadfulmtg.github.io/EMN_legal_cards.txt (no cache)
CONFIG: save_historic_legal_lists=False
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/KLD_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/AER_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/AKH_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/HOU_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/XLN_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/RIX_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/DOM_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/M19_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/GRN_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/RNA_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/WAR_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/M20_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
Before COMMIT (['update_database', 'set_legal_cards'])
After COMMIT (['update_database'])
Fetching https://pennydreadfulmtg.github.io/ELD_legal_cards.txt (no cache)
Before BEGIN (['update_database'])
After BEGIN (['update_database', 'set_legal_cards'])
DatabaseException running ['dev.py', 'tests']:  [('Failed to execute `INSERT INTO card_legality (format_id, card_id, legality)\n             VALUES ` with `[]` because of `(1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near \'\' at line 2")`',)] Failed to execute `INSERT INTO card_legality (format_id, card_id, legality)
             VALUES ` with `[]` because of `(1064, "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '' at line 2")`
TravisBuddy Request Identifier: bd04fbe0-4e1d-11ea-b00e-d175f66e4ddd
@vorpal-buildbot vorpal-buildbot merged commit 4c67742 into master Feb 13, 2020
6 checks passed
6 checks passed
Codacy/PR Quality Review Up to standards. A positive pull request.
Details
Summary no rules match, no planned actions
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
continuous-integration/travis-ci/push The Travis CI build passed
Details
pdm/automerge Ready to merge
pyup.io/safety-ci No dependencies with known security vulnerabilities.
Details
@codecov

This comment has been minimized.

Copy link

codecov bot commented Feb 13, 2020

Codecov Report

Merging #7053 into master will increase coverage by 0.1%.
The diff coverage is 12.5%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master    #7053     +/-   ##
=========================================
+ Coverage   45.87%   45.98%   +0.1%     
=========================================
  Files         274      274             
  Lines       13773    13814     +41     
  Branches     2090     2109     +19     
=========================================
+ Hits         6319     6352     +33     
- Misses       7158     7166      +8     
  Partials      296      296
Impacted Files Coverage Δ
maintenance/post_rotation.py 0% <0%> (ø) ⬆️
decksite/league.py 34.32% <0%> (-0.12%) ⬇️
magic/fetcher.py 25.31% <0%> (ø) ⬆️
rotation_script/rotation_script.py 0% <0%> (ø) ⬆️
logsite/data/game.py 83.87% <100%> (ø) ⬆️
magic/image_fetcher.py 35.66% <0%> (+1.27%) ⬆️
decksite/data/archetype.py 57.51% <0%> (+7.51%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1314ed3...4b6ba95. Read the comment docs.

@vorpal-buildbot

This comment has been minimized.

Copy link
Contributor

vorpal-buildbot commented Feb 13, 2020

Seen on LOGS, PROD (created by @silasary and merged by @vorpal-buildbot 18 seconds ago) Please check your changes!

cached_path = os.path.join(os.path.abspath(os.path.dirname(__file__)), 'legal_cards')
if os.path.exists(os.path.join(cached_path, url)):
h = open(os.path.join(cached_path, url), encoding=encoding)
legal = h.readlines()
h.close()
return [l.strip() for l in legal]

url = 'http://pdmtgo.com/' + url
url = 'https://pennydreadfulmtg.github.io/' + url

This comment has been minimized.

Copy link
@bakert

bakert Feb 15, 2020

Member

What's the benefit of using the github address? You're staging there?

This comment has been minimized.

Copy link
@silasary

silasary Feb 16, 2020

Author Member

Yeah, and the rotation script automatically pushes there, whereas S3 needs manual intervention.

It means our internal tools will be faster and require less human intervention.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.