Feature/pkgdb #29

Merged
merged 4 commits into from Mar 4, 2014

Conversation

Projects
None yet
2 participants
Contributor

ralphbean commented Mar 4, 2014

This should fix #28.

fedbadges/utils.py
+# TODO -- delete this once pkgdb2 goes live.
+def _get_pkgdb1_packages_for(config, username):
+ log.debug("Requesting pkgdb1 packages for user %r" % username)
+ pkgdb1_base_url = 'https://admin.fedoraproject.org/pkgdb'
@pypingou

pypingou Mar 4, 2014

Owner

just a thought, not sure worth patching, but since we have fedbadges.rules.utils.use_pkgdb2 couldn't we store the pkgdb_url in the config regardless of pkgdb1/2 ?

@ralphbean

ralphbean Mar 4, 2014

Contributor

Yes, good catch.

Owner

pypingou commented Mar 4, 2014

One small question but it looks sane, 👍
Is there a way to add tests for this code?

Contributor

ralphbean commented Mar 4, 2014

Is there a way to add tests for this code?

Yes, but we'd either need to mock out the requests library, or allow network communication. But I'd rather not. ;)

ralphbean added a commit that referenced this pull request Mar 4, 2014

@ralphbean ralphbean merged commit 8320d71 into develop Mar 4, 2014

1 check passed

default PEP8bot says "OK"
Details

@ralphbean ralphbean deleted the feature/pkgdb branch Mar 4, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment