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

Fix release-monitoring.org html scraping. #86

Merged
merged 2 commits into from Nov 24, 2015
Merged

Conversation

ralphbean
Copy link
Contributor

Kinda ugly here, but login with release-monitoring.org broke when we
added a search form to every page there.

Hotness would try to scrape each page for a form, and then extract the
csrf_token from that form. Except now, there are two forms on every
page, so that scraping broke.

This code updates each attempt at that to look explicitly for the form
it is interested in.

Kinda ugly here, but login with release-monitoring.org broke when we
added a search form to every page there.

Hotness would try to scrape each page for a form, and then extract the
csrf_token from that form.  Except now, there are **two** forms on every
page, so that scraping broke.

This code updates each attempt at that to look explicitly for the form
it is interested in.
@pypingou
Copy link
Member

Stupid idea: can we look for the csrf_token field anywhere in the page (ie: without searching for a specific form first)? Even if there are multiple csrf_token on the page, any of them should work.

@ralphbean
Copy link
Contributor Author

Stupid idea

Good idea! Done in 54c132d.

@pypingou
Copy link
Member

Cool, 👍

ralphbean added a commit that referenced this pull request Nov 24, 2015
Fix release-monitoring.org html scraping.
@ralphbean ralphbean merged commit 7e94856 into develop Nov 24, 2015
@ralphbean ralphbean deleted the feature/soup-to-nuts branch November 24, 2015 14:27
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.

None yet

2 participants