-
Notifications
You must be signed in to change notification settings - Fork 14
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
Improvements for captcha detection (WIP) #65
Conversation
wait for visible, pattern, page actions back action #52 provide collection action - for cases when rules are not defined before actions are performed #64 postActions support concurrent cases actions support - when we don't know what to do exactly performance improved for wait action actions results rule type - for cases when we don't need parse possibility to use blank scopes for rules, for virtual rules which can get results from actions for example Refs #57 🐗
@@ -457,7 +496,8 @@ PhantomEnvironment.prototype = _.create(Environment.prototype, /**@lends Phantom | |||
var args = [].slice.call(arguments); | |||
args = args.slice(3); | |||
this._page.onResourceRequested(callback, /* @covignore */ function (requestData) { | |||
debug('Resource requested %s', requestData.url); | |||
// todo: decide, remove or leave | |||
// debug('Resource requested %s', requestData.url); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it's really annoying, what do you think @maZahaca
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep. We can cut this. That was made only for testing work which is related to loading resources.
@@ -3,6 +3,8 @@ var vow = require('vow'), | |||
|
|||
function Environment(options) { | |||
debug('Initializing...'); | |||
|
|||
this._errbacks = []; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
errback is callback for error )) In this particular case it's errbacks for evaluateJs
fucntions. Sometimes we need to know that something going wrong. For example: if we use wait
and on first iteration code fails, we should stop waiting. We add errback before wait
and remove it when wait
is completed.
Am I right, that this PR includes #61 ? |
EXIST: 'exist' | ||
EXIST: 'exist', | ||
BACK: 'back', | ||
PROVIDE_COLLECTION: 'provideCollection' |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is it for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sometimes we do not know what are rules for parsing before actions are performed. Also we have conditional actions and last action can return collection to parse, this collection will be attached to the rule which actions are performed for.
yep |
use action results in next action "show more" pagination :boar:
waitForQuery action transforms for all type of rules :boar:
7cf7df4
to
a685dbe
Compare
open action :boar:
PhantomEnvironment._page memory leak fixed :boar:
…-goose-babe # Conflicts: # lib/PhantomEnvironment.js
…-goose-babe # Conflicts: # lib/PhantomEnvironment.js
pause action wait reverted :boar:
…action.rules * Improved using rule.type = array for string results * Added decodeURI action
Improved provideRules
6dcf779
to
fc3476c
Compare
Refs #57
🐗