ferrum 0.6 → 0.6.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/lib/ferrum/frame.rb +4 -0
- data/lib/ferrum/page/frames.rb +2 -4
- data/lib/ferrum/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 4f5179f765dbfb25cfbb1512958c5c4e8d2e8b486d48973bd2d2922389f74f8f
|
4
|
+
data.tar.gz: 47f2b8cc7afc75c06dffe27fae3e3a54558c86579c412d6806e9713e3282c0e8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9566908dab8979128138801a7b105905e0198e4873b9c668e231078108a31cc6e7586ab4c4405c527908ffb9557d255bc9a02b6e878392946b2eb1d79f8cc0a0
|
7
|
+
data.tar.gz: 4b4fa5c411f0831a0fbd80ac880621e0459ff8dc976d828c1b88dfbf5f05023a096b2a6696269048416b7bdcef1f34f8d360a841e0798bb936277a96b4da4929
|
data/README.md
CHANGED
@@ -17,6 +17,8 @@ this code inside in one form or another but the thing is you don't need capybara
|
|
17
17
|
if you are going to crawl sites. You crawl, not test. Besides that clean
|
18
18
|
lightweight API to browser is what Ruby was missing, so here it comes.
|
19
19
|
|
20
|
+
If you like this project, please consider to [become a backer](https://www.patreon.com/rferrum) on Patreon.
|
21
|
+
|
20
22
|
## Install
|
21
23
|
|
22
24
|
There's no official Chrome or Chromium package for Linux don't install it this
|
data/lib/ferrum/frame.rb
CHANGED
data/lib/ferrum/page/frames.rb
CHANGED
@@ -11,11 +11,9 @@ module Ferrum
|
|
11
11
|
@frames.values
|
12
12
|
end
|
13
13
|
|
14
|
-
def frame_by(id: nil,
|
14
|
+
def frame_by(id: nil, name: nil)
|
15
15
|
if id
|
16
16
|
@frames[id]
|
17
|
-
elsif execution_id
|
18
|
-
frames.find { |f| f.execution_id == execution_id }
|
19
17
|
elsif name
|
20
18
|
frames.find { |f| f.name == name }
|
21
19
|
else
|
@@ -96,7 +94,7 @@ module Ferrum
|
|
96
94
|
|
97
95
|
on("Runtime.executionContextDestroyed") do |params|
|
98
96
|
execution_id = params["executionContextId"]
|
99
|
-
frame =
|
97
|
+
frame = frames.find { |f| f.execution_id?(execution_id) }
|
100
98
|
frame.execution_id = nil
|
101
99
|
end
|
102
100
|
|
data/lib/ferrum/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: ferrum
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 0.6.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Dmitry Vorotilin
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2019-10-
|
11
|
+
date: 2019-10-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: websocket-driver
|