Skip to content

This merges all the bugfix PR's I had into one. #2754

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

Merged
merged 13 commits into from
Mar 30, 2017
Merged

Conversation

ericholscher
Copy link
Member

Fix errors caused by calling dict on a Response.

This errors in all the cases I tested (202, 400), so I'm not sure what the
original intent was. This gives users 500's on project import if GH import
fails, so probably a pretty high priority to fix.

--

Fix CORS requests not having ORIGIN

--

Fix unicode handling in resolver

We should probably upgrade to Python 3 to remove all these issues, but this
at least will fix this one.

--

Validate the JSON file we're trying to load works.

This fixes errors on search indexing of files that don't fit the format.
This was triggering on eg. searchindex.json in the JSON builders

--

Remove the call to our API from old projects.

This stops a large number of requests from old pages. It depends on v1 of
our API and it broken.

This stops a large number of requests from old pages.
It depends on v1 of our API and it broken.
This fixes errors on search indexing of files that don't fit the format.
This was triggering on eg. `searchindex.json` in the JSON builders
We should probably upgrade to Python 3 to remove all these issues,
but this at least will fix this one.
This errors in all the cases I tested (202, 400),
so I'm not sure what the original intent was.
This gives users 500's on project import if GH import fails,
so probably a pretty high priority to fix.
@ericholscher ericholscher added the PR: work in progress Pull request is not ready for full review label Mar 28, 2017
@ericholscher ericholscher requested a review from agjohnson March 28, 2017 00:28
@ericholscher ericholscher added PR: ready for review and removed PR: work in progress Pull request is not ready for full review labels Mar 28, 2017
Copy link
Contributor

@agjohnson agjohnson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yay, less errors!

@@ -214,5 +214,5 @@ def setup_webhook(self, project):
log.error('Bitbucket webhook creation failed for project: %s',
project)
log.debug('Bitbucket webhook creation failure response: %s',
dict(resp))
resp.content)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

resp.json() is more correct. Also, feel free to drop this, I have a fix in my branch.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That only works for JSON content, and most of the issues here are the responses aren't valid JSON.

@@ -205,7 +205,7 @@ def setup_webhook(self, project):
log.error('GitHub webhook creation failed for project: %s',
project)
log.debug('GitHub webhook creation failure response: %s',
dict(resp))
resp.content)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above

promoted_version.slug in added_versions):
promoted_version.active = True
promoted_version.save()
trigger_build(project=project, version=promoted_version)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This removed get_stable_version call, what was the problem there? Any side effects on this?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It wasn't used, so I figured not, it seemed like a weird thing to have side effects, but didn't check.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No side effects, just dead code.

@@ -67,7 +67,7 @@
}
);

checkVersion(slug, version);
// checkVersion(slug, version);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Might be a good spot for a comment on why this is disabled

@ericholscher
Copy link
Member Author

ericholscher commented Mar 30, 2017

Gonna merge this and get it deployed to hopefully reduce errors over the weekend -- the resp changes shouldn't cause bad conflicts, so will include those in, since it's blowing up project import sometimes atm.

@ericholscher ericholscher merged commit 756e6e7 into master Mar 30, 2017
@stsewd stsewd deleted the bugfix-bundle branch August 15, 2018 22:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants