Skip to content
This repository has been archived by the owner on Feb 8, 2018. It is now read-only.

Fix npm sync regression #4176

Merged
merged 2 commits into from
Nov 9, 2016
Merged

Fix npm sync regression #4176

merged 2 commits into from
Nov 9, 2016

Conversation

chadwhitacre
Copy link
Contributor

@chadwhitacre
Copy link
Contributor Author

Blech. "Failing test" didn't fail. Failed locally, I promise! :-/

@chadwhitacre chadwhitacre force-pushed the fix-npm-sync-regressions branch from abb3591 to faba8b1 Compare November 9, 2016 03:28
@chadwhitacre
Copy link
Contributor Author

The tests are not being skipped.

screen shot 2016-11-08 at 7 29 54 pm

https://travis-ci.org/gratipay/gratipay.com/builds/174399249#L1150-L1151

Both of those are failing for me locally:

_______________________________________ Tests.test_rf_fetches_a_readme _______________________________________
Traceback (most recent call last):
  File "/Users/whit537/personal/gratipay/gratipay.com/tests/py/test_npm_sync.py", line 95, in test_rf_fetches_a_readme
    readmes.fetch(self.db, fetch)
  File "/Users/whit537/personal/gratipay/gratipay.com/gratipay/package_managers/readmes.py", line 93, in fetch
    threaded_map(Fetcher(db, _fetch), dirty, 4)
TypeError: Fetcher() takes exactly 1 argument (2 given)
______________________________________ Tests.test_rp_processes_a_readme ______________________________________
Traceback (most recent call last):
  File "/Users/whit537/personal/gratipay/gratipay.com/tests/py/test_npm_sync.py", line 124, in test_rp_processes_a_readme
    readmes.process(self.db)
  File "/Users/whit537/personal/gratipay/gratipay.com/gratipay/package_managers/readmes.py", line 97, in process
    dirty = db.all('SELECT id, package_manager, name, description, readme_raw '
  File "/Users/whit537/personal/gratipay/gratipay.com/env/lib/python2.7/site-packages/postgres/__init__.py", line 548, in all
    return cursor.all(sql, parameters)
  File "/Users/whit537/personal/gratipay/gratipay.com/env/lib/python2.7/site-packages/postgres/cursors.py", line 145, in all
    self.execute(sql, parameters)
  File "/Users/whit537/personal/gratipay/gratipay.com/env/lib/python2.7/site-packages/psycopg2/extras.py", line 288, in execute
    return super(NamedTupleCursor, self).execute(query, vars)
ProgrammingError: syntax error at or near "BY"
LINE 1: ... packages WHERE readme_needs_to_be_processedORDER BY package...
                                                             ^

==================================== 2 failed, 4 passed in 14.77 seconds =====================================

@chadwhitacre
Copy link
Contributor Author

I think Travis pulled the wrong commit? Restarting ...

@chadwhitacre
Copy link
Contributor Author

Now it's got the right commit ...

@chadwhitacre
Copy link
Contributor Author

There we go! 👍

@chadwhitacre chadwhitacre force-pushed the fix-npm-sync-regressions branch from abb3591 to e38a1c4 Compare November 9, 2016 03:36
@chadwhitacre
Copy link
Contributor Author

chadwhitacre commented Nov 9, 2016

Once travis is green I'm going to merge and deploy this so the next scheduler run picks it up. Then I'll look at the other bug, the one in the fetcher.

@chadwhitacre chadwhitacre merged commit 11532ec into master Nov 9, 2016
@chadwhitacre chadwhitacre deleted the fix-npm-sync-regressions branch November 9, 2016 03:47
@chadwhitacre chadwhitacre mentioned this pull request Nov 21, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant