phantom_proxy 1.3.3 → 1.3.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: dd51c0e6b7b7b624070759913a14f094fec43a9c
4
- data.tar.gz: 0c4fea61eefd285db91c29057d937532e34dabbe
3
+ metadata.gz: 832a5113bf2ab41554ead8482e718e41df8f39d7
4
+ data.tar.gz: cd2a8d53139fdf1fca1ee1002f490c4cea6e57e0
5
5
  SHA512:
6
- metadata.gz: 6b9db1c9de242698bab6758a18c30bff9f3f34359adf5ac27745d3f5bba14ab77d69c77d96ee8ae3896cbac4ad10a6c34e1113bb4ad23b3d3a6ed9ec0587d2a8
7
- data.tar.gz: 5c8e96f3e2d87646cb6719e1698ff24b4685b4df8dc953be01311f712b916a51c1a82a0e262ba69bcdd836e3529767c9c05292f65ecff99418da5749ef9aaf95
6
+ metadata.gz: 5e2fb08a94320dbfee2caee0ab2d5a24a712cbc05ceecb107b0af5a373edc838cddf150476e6ba8428277c29cda088e106cf6314339ea1021c9c91057665444c
7
+ data.tar.gz: b51df0abe28cf99f3f474911aa7fd4176a6caeb9e3518ee996cb5c3db8f41571903a1d8ddec8b91f366943b6e99de49967446ff872e48eebe574e2ae7d7c21ae
@@ -45,7 +45,7 @@ module PhantomProxy
45
45
 
46
46
  @dom = invokePhantomJS(PhantomProxy.script_path, [picture, loadFrames, "\""+url+"\"", url_args_.length, url_args])
47
47
 
48
- #logger.info("Opened page: "+ /Open page: (.*?) END/.match(@dom)[1])
48
+ # logger.info("Opened page: "+ /Open page: (.*?) END/.match(@dom)[1])
49
49
 
50
50
  @ready = 503
51
51
  dom_text = "Failed to load page"
@@ -47,7 +47,9 @@ var loadpage = function(url, referer, success, failure, configure) {
47
47
  page.onResourceReceived = function(resource) {
48
48
  if (url == resource.url && resource.redirectURL && resource.stage == "end") {
49
49
  redirectURL = resource.redirectURL;
50
- console.log('FRAME_URL_ERROR_CODE: '+resource.status+'FRAME_URL_ERROR_CODE_END');
50
+ console.log('URL_FRAME_ERROR_CODE: '+resource.status+'URL_FRAME_ERROR_CODE_END');
51
+ } else if (url == resource.url && resource.stage == "end" && resource.status != 200 && (referer!=undefined || !resource.redirectURL)) {
52
+ console.log('URL_ERROR_CODE: '+resource.status+'URL_ERROR_CODE_END');
51
53
  }
52
54
  };
53
55
 
@@ -118,12 +120,12 @@ function main() {
118
120
  phantom.exit();
119
121
  }, function(page) {
120
122
  //page.customHeaders = {"Referer": "http://uk-amazon.icims.com/jobs/240290/account-representative---amazon-web-services---iberia/job"}
121
- page.onResourceReceived = function (response) {
122
- if (response.stage == "end" && response.url == address && response.status != 200)
123
- {
124
- console.log('URL_ERROR_CODE: '+response.status+'URL_ERROR_CODE_END');
125
- }
126
- };
123
+ // page.onResourceReceived = function (response) {
124
+ // if (response.stage == "end" && response.url == address && response.status != 200)
125
+ // {
126
+ // console.log('URL_ERROR_CODE: '+response.status+'URL_ERROR_CODE_END');
127
+ // }
128
+ // };
127
129
  });
128
130
  }
129
131
  }
@@ -1,3 +1,3 @@
1
1
  module PhantomProxy
2
- VERSION = "1.3.3"
2
+ VERSION = "1.3.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phantom_proxy
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.3.3
4
+ version: 1.3.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Suddani