requestium 0.3.0__tar.gz → 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,26 +1,85 @@
1
- Metadata-Version: 2.1
1
+ Metadata-Version: 2.4
2
2
  Name: requestium
3
- Version: 0.3.0
4
- Summary:
5
- Author: Joaquin Alori
6
- Author-email: joaquin@tryolabs.com
7
- Requires-Python: >=3.9,<=3.13
8
- Classifier: Programming Language :: Python :: 3
9
- Classifier: Programming Language :: Python :: 3.9
3
+ Version: 0.5.1
4
+ Author-email: Joaquin Alori <joaquin@tryolabs.com>
5
+ Maintainer-email: Judson Neer <jkudson.neer@gmail.com>
6
+ License: BSD 3-Clause License
7
+
8
+ Copyright (c) 2017, Tryolabs
9
+ All rights reserved.
10
+
11
+ Redistribution and use in source and binary forms, with or without
12
+ modification, are permitted provided that the following conditions are met:
13
+
14
+ * Redistributions of source code must retain the above copyright notice, this
15
+ list of conditions and the following disclaimer.
16
+
17
+ * Redistributions in binary form must reproduce the above copyright notice,
18
+ this list of conditions and the following disclaimer in the documentation
19
+ and/or other materials provided with the distribution.
20
+
21
+ * Neither the name of the copyright holder nor the names of its
22
+ contributors may be used to endorse or promote products derived from
23
+ this software without specific prior written permission.
24
+
25
+ THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
26
+ AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
27
+ IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
28
+ DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
29
+ FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
30
+ DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
31
+ SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
32
+ CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
33
+ OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
34
+ OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
35
+
36
+ Project-URL: source, https://github.com/tryolabs/requestium
37
+ Project-URL: download, https://pypi.org/project/requestium/#files
38
+ Project-URL: issues, https://github.com/tryolabs/requestium/issues
39
+ Classifier: Development Status :: 4 - Beta
40
+ Classifier: Intended Audience :: Developers
41
+ Classifier: License :: OSI Approved :: BSD License
10
42
  Classifier: Programming Language :: Python :: 3.10
11
43
  Classifier: Programming Language :: Python :: 3.11
12
44
  Classifier: Programming Language :: Python :: 3.12
13
- Requires-Dist: parsel (>=1.8.1,<2.0.0)
14
- Requires-Dist: requests (>=2.31.0,<3.0.0)
15
- Requires-Dist: selenium (>=4.15.2,<5.0.0)
16
- Requires-Dist: tldextract (>=5.1.1,<6.0.0)
45
+ Classifier: Programming Language :: Python :: 3.13
46
+ Classifier: Programming Language :: Python :: 3.14
47
+ Classifier: Natural Language :: English
48
+ Classifier: Operating System :: MacOS
49
+ Classifier: Operating System :: Microsoft :: Windows
50
+ Classifier: Operating System :: POSIX
51
+ Classifier: Operating System :: OS Independent
52
+ Classifier: Environment :: Web Environment
53
+ Classifier: Programming Language :: Python :: Implementation :: CPython
54
+ Classifier: Topic :: Software Development :: Libraries :: Python Modules
55
+ Classifier: Topic :: Software Development :: Testing
56
+ Requires-Python: >=3.10
17
57
  Description-Content-Type: text/markdown
58
+ License-File: LICENSE
59
+ Requires-Dist: parsel>=1.7
60
+ Requires-Dist: requests>=2.27
61
+ Requires-Dist: selenium>=4.32
62
+ Requires-Dist: tldextract>=5.3
63
+ Provides-Extra: dev
64
+ Requires-Dist: bandit[sarif]==1.9.2; extra == "dev"
65
+ Requires-Dist: mypy==1.19.1; extra == "dev"
66
+ Requires-Dist: pre-commit~=4.5.0; extra == "dev"
67
+ Requires-Dist: pytest-cov~=7.0.0; extra == "dev"
68
+ Requires-Dist: pytest-xdist~=3.8.0; extra == "dev"
69
+ Requires-Dist: pytest~=9.0.0; extra == "dev"
70
+ Requires-Dist: ruff==0.14.11; extra == "dev"
71
+ Requires-Dist: ssort==0.16.0; extra == "dev"
72
+ Requires-Dist: types-requests==2.32.4.20260107; extra == "dev"
73
+ Dynamic: license-file
18
74
 
19
75
  ![Requestium](https://user-images.githubusercontent.com/14966348/32966130-8bb15b00-cbb7-11e7-9faf-85963ec5bd82.png)
20
76
  ========
21
77
 
22
- [![Build Status](https://travis-ci.org/tryolabs/requestium.svg?branch=master)](https://travis-ci.org/tryolabs/requestium)
23
78
  [![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
79
+ [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/requestium)](https://pypi.org/project/requestium/)
80
+ [![PyPI](https://img.shields.io/pypi/v/requestium?color=blue)](https://pypi.org/project/requestium/)
81
+ [![Coverage](https://raw.githubusercontent.com/tryolabs/requestium/python-coverage-comment-action-data/badge.svg)](https://htmlpreview.github.io/?https://github.com/tryolabs/requestium/blob/python-coverage-comment-action-data/htmlcov/index.html)
82
+ [![Python checks](https://github.com/tryolabs/requestium/actions/workflows/python.yml/badge.svg)](https://github.com/tryolabs/requestium/actions/workflows/python.yml)
24
83
 
25
84
  Requestium is a Python library that merges the power of [Requests](https://github.com/requests/requests), [Selenium](https://github.com/SeleniumHQ/selenium), and [Parsel](https://github.com/scrapy/parsel) into a single integrated tool for automatizing web actions.
26
85
 
@@ -54,7 +113,7 @@ options = {'arguments': ['headless']}
54
113
  s = Session(webdriver_path='./chromedriver', default_timeout=15, webdriver_options=options)
55
114
  ```
56
115
 
57
- Since headless mode is common, there's a shortcut for it by pecifying `headless=True`.
116
+ Since headless mode is common, there's a shortcut for it by specifying `headless=True`.
58
117
 
59
118
  ```python
60
119
  from requestium import Session, Keys
@@ -115,9 +174,10 @@ s.driver.get('http://www.samplesite.com/sample/process')
115
174
 
116
175
  The driver object is a Selenium webdriver object, so you can use any of the normal selenium methods plus new methods added by Requestium.
117
176
  ```python
118
- s.driver.find_element_by_xpath("//input[@class='user_name']").send_keys('James Bond', Keys.ENTER)
177
+ s.driver.find_element("xpath", "//input[@class='user_name']").send_keys('James Bond', Keys.ENTER)
119
178
 
120
- # New method which waits for element to load instead of failing, useful for single page web apps
179
+ # New methods which wait for element to load instead of failing, useful for single page web apps
180
+ s.driver.ensure_element("xpath", "//div[@attribute='button']").click()
121
181
  s.driver.ensure_element_by_xpath("//div[@attribute='button']").click()
122
182
  ```
123
183
 
@@ -137,7 +197,7 @@ s.post('http://www.samplesite.com/sample2', data={'key1': 'value1'})
137
197
  Requestium adds several 'ensure' methods to the driver object, as Selenium is known to be very finicky about selecting elements and cookie handling.
138
198
 
139
199
  ### Wait for element
140
- The `ensure_element_by_` methods waits for the element to be loaded in the browser and returns it as soon as it loads. It's named after Selenium's `find_element_by_` methods (which immediately raise an exception if they can't find the element).
200
+ The `ensure_element` and `ensure_element_by_` methods wait for the element to be loaded in the browser and returns it as soon as it loads. They're named after Selenium's `find_element` and `find_element_by_` methods (which immediately raise an exception if they can't find the element).
141
201
 
142
202
  Requestium can wait for an element to be in any of the following states:
143
203
  - present (default)
@@ -145,16 +205,17 @@ Requestium can wait for an element to be in any of the following states:
145
205
  - visible
146
206
  - invisible (useful for things like waiting for *loading...* gifs to disappear)
147
207
 
148
- These methods are very useful for single page web apps where the site is dynamically changing its elements. We usually end up completely replacing our `find_element_by_` calls with `ensure_element_by_` calls as they are more flexible.
208
+ These methods are very useful for single page web apps where the site is dynamically changing its elements. We usually end up completely replacing our `find_element` and `find_element_by_` calls with `ensure_element` and `ensure_element_by_` calls as they are more flexible.
149
209
 
150
210
  Elements you get using these methods have the new `ensure_click` method which makes the click less prone to failure. This helps with getting through a lot of the problems with Selenium clicking.
151
211
 
152
212
  ```python
153
- s.driver.ensure_element_by_xpath("//li[@class='b1']", state='clickable', timeout=5).ensure_click()
213
+ s.driver.ensure_element("xpath", "//li[@class='b1']", state='clickable', timeout=5).ensure_click()
154
214
 
155
215
  # === We also added these methods named in accordance to Selenium's api design ===
156
216
  # ensure_element_by_id
157
217
  # ensure_element_by_name
218
+ # ensure_element_by_xpath
158
219
  # ensure_element_by_link_text
159
220
  # ensure_element_by_partial_link_text
160
221
  # ensure_element_by_tag_name
@@ -205,18 +266,18 @@ reddit_user_name = ''
205
266
 
206
267
  s = Session('./chromedriver', default_timeout=15)
207
268
  s.driver.get('http://reddit.com')
208
- s.driver.find_element_by_xpath("//a[@href='https://www.reddit.com/login']").click()
269
+ s.driver.find_element("xpath", "//a[@href='https://www.reddit.com/login']").click()
209
270
 
210
271
  print('Waiting for elements to load...')
211
- s.driver.ensure_element_by_class_name("desktop-onboarding-sign-up__form-toggler",
272
+ s.driver.ensure_element("class name", "desktop-onboarding-sign-up__form-toggler",
212
273
  state='visible').click()
213
274
 
214
275
  if reddit_user_name:
215
- s.driver.ensure_element_by_id('user_login').send_keys(reddit_user_name)
216
- s.driver.ensure_element_by_id('passwd_login').send_keys(Keys.BACKSPACE)
276
+ s.driver.ensure_element('id', 'user_login').send_keys(reddit_user_name)
277
+ s.driver.ensure_element('id', 'passwd_login').send_keys(Keys.BACKSPACE)
217
278
  print('Please log-in in the chrome browser')
218
279
 
219
- s.driver.ensure_element_by_class_name("desktop-onboarding__title", timeout=60, state='invisible')
280
+ s.driver.ensure_element("class name", "desktop-onboarding__title", timeout=60, state='invisible')
220
281
  print('Thanks!')
221
282
 
222
283
  if not reddit_user_name:
@@ -251,7 +312,7 @@ reddit_user_name = ''
251
312
 
252
313
  driver = webdriver.Chrome('./chromedriver')
253
314
  driver.get('http://reddit.com')
254
- driver.find_element_by_xpath("//a[@href='https://www.reddit.com/login']").click()
315
+ driver.find_element("xpath", "//a[@href='https://www.reddit.com/login']").click()
255
316
 
256
317
  print('Waiting for elements to load...')
257
318
  WebDriverWait(driver, 15).until(
@@ -262,7 +323,7 @@ if reddit_user_name:
262
323
  WebDriverWait(driver, 15).until(
263
324
  EC.presence_of_element_located((By.ID, 'user_login'))
264
325
  ).send_keys(reddit_user_name)
265
- driver.find_element_by_id('passwd_login').send_keys(Keys.BACKSPACE)
326
+ driver.find_element('id', 'passwd_login').send_keys(Keys.BACKSPACE)
266
327
  print('Please log-in in the chrome browser')
267
328
 
268
329
  try:
@@ -313,4 +374,3 @@ This project intends to be a drop-in replacement of Requests' Session object, wi
313
374
 
314
375
  ## License
315
376
  Copyright © 2018, [Tryolabs](https://tryolabs.com/). Released under the [BSD 3-Clause](https://github.com/tryolabs/requestium/blob/master/LICENSE).
316
-
@@ -1,8 +1,11 @@
1
1
  ![Requestium](https://user-images.githubusercontent.com/14966348/32966130-8bb15b00-cbb7-11e7-9faf-85963ec5bd82.png)
2
2
  ========
3
3
 
4
- [![Build Status](https://travis-ci.org/tryolabs/requestium.svg?branch=master)](https://travis-ci.org/tryolabs/requestium)
5
4
  [![License](https://img.shields.io/badge/License-BSD%203--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause)
5
+ [![PyPI - Python Version](https://img.shields.io/pypi/pyversions/requestium)](https://pypi.org/project/requestium/)
6
+ [![PyPI](https://img.shields.io/pypi/v/requestium?color=blue)](https://pypi.org/project/requestium/)
7
+ [![Coverage](https://raw.githubusercontent.com/tryolabs/requestium/python-coverage-comment-action-data/badge.svg)](https://htmlpreview.github.io/?https://github.com/tryolabs/requestium/blob/python-coverage-comment-action-data/htmlcov/index.html)
8
+ [![Python checks](https://github.com/tryolabs/requestium/actions/workflows/python.yml/badge.svg)](https://github.com/tryolabs/requestium/actions/workflows/python.yml)
6
9
 
7
10
  Requestium is a Python library that merges the power of [Requests](https://github.com/requests/requests), [Selenium](https://github.com/SeleniumHQ/selenium), and [Parsel](https://github.com/scrapy/parsel) into a single integrated tool for automatizing web actions.
8
11
 
@@ -36,7 +39,7 @@ options = {'arguments': ['headless']}
36
39
  s = Session(webdriver_path='./chromedriver', default_timeout=15, webdriver_options=options)
37
40
  ```
38
41
 
39
- Since headless mode is common, there's a shortcut for it by pecifying `headless=True`.
42
+ Since headless mode is common, there's a shortcut for it by specifying `headless=True`.
40
43
 
41
44
  ```python
42
45
  from requestium import Session, Keys
@@ -97,9 +100,10 @@ s.driver.get('http://www.samplesite.com/sample/process')
97
100
 
98
101
  The driver object is a Selenium webdriver object, so you can use any of the normal selenium methods plus new methods added by Requestium.
99
102
  ```python
100
- s.driver.find_element_by_xpath("//input[@class='user_name']").send_keys('James Bond', Keys.ENTER)
103
+ s.driver.find_element("xpath", "//input[@class='user_name']").send_keys('James Bond', Keys.ENTER)
101
104
 
102
- # New method which waits for element to load instead of failing, useful for single page web apps
105
+ # New methods which wait for element to load instead of failing, useful for single page web apps
106
+ s.driver.ensure_element("xpath", "//div[@attribute='button']").click()
103
107
  s.driver.ensure_element_by_xpath("//div[@attribute='button']").click()
104
108
  ```
105
109
 
@@ -119,7 +123,7 @@ s.post('http://www.samplesite.com/sample2', data={'key1': 'value1'})
119
123
  Requestium adds several 'ensure' methods to the driver object, as Selenium is known to be very finicky about selecting elements and cookie handling.
120
124
 
121
125
  ### Wait for element
122
- The `ensure_element_by_` methods waits for the element to be loaded in the browser and returns it as soon as it loads. It's named after Selenium's `find_element_by_` methods (which immediately raise an exception if they can't find the element).
126
+ The `ensure_element` and `ensure_element_by_` methods wait for the element to be loaded in the browser and returns it as soon as it loads. They're named after Selenium's `find_element` and `find_element_by_` methods (which immediately raise an exception if they can't find the element).
123
127
 
124
128
  Requestium can wait for an element to be in any of the following states:
125
129
  - present (default)
@@ -127,16 +131,17 @@ Requestium can wait for an element to be in any of the following states:
127
131
  - visible
128
132
  - invisible (useful for things like waiting for *loading...* gifs to disappear)
129
133
 
130
- These methods are very useful for single page web apps where the site is dynamically changing its elements. We usually end up completely replacing our `find_element_by_` calls with `ensure_element_by_` calls as they are more flexible.
134
+ These methods are very useful for single page web apps where the site is dynamically changing its elements. We usually end up completely replacing our `find_element` and `find_element_by_` calls with `ensure_element` and `ensure_element_by_` calls as they are more flexible.
131
135
 
132
136
  Elements you get using these methods have the new `ensure_click` method which makes the click less prone to failure. This helps with getting through a lot of the problems with Selenium clicking.
133
137
 
134
138
  ```python
135
- s.driver.ensure_element_by_xpath("//li[@class='b1']", state='clickable', timeout=5).ensure_click()
139
+ s.driver.ensure_element("xpath", "//li[@class='b1']", state='clickable', timeout=5).ensure_click()
136
140
 
137
141
  # === We also added these methods named in accordance to Selenium's api design ===
138
142
  # ensure_element_by_id
139
143
  # ensure_element_by_name
144
+ # ensure_element_by_xpath
140
145
  # ensure_element_by_link_text
141
146
  # ensure_element_by_partial_link_text
142
147
  # ensure_element_by_tag_name
@@ -187,18 +192,18 @@ reddit_user_name = ''
187
192
 
188
193
  s = Session('./chromedriver', default_timeout=15)
189
194
  s.driver.get('http://reddit.com')
190
- s.driver.find_element_by_xpath("//a[@href='https://www.reddit.com/login']").click()
195
+ s.driver.find_element("xpath", "//a[@href='https://www.reddit.com/login']").click()
191
196
 
192
197
  print('Waiting for elements to load...')
193
- s.driver.ensure_element_by_class_name("desktop-onboarding-sign-up__form-toggler",
198
+ s.driver.ensure_element("class name", "desktop-onboarding-sign-up__form-toggler",
194
199
  state='visible').click()
195
200
 
196
201
  if reddit_user_name:
197
- s.driver.ensure_element_by_id('user_login').send_keys(reddit_user_name)
198
- s.driver.ensure_element_by_id('passwd_login').send_keys(Keys.BACKSPACE)
202
+ s.driver.ensure_element('id', 'user_login').send_keys(reddit_user_name)
203
+ s.driver.ensure_element('id', 'passwd_login').send_keys(Keys.BACKSPACE)
199
204
  print('Please log-in in the chrome browser')
200
205
 
201
- s.driver.ensure_element_by_class_name("desktop-onboarding__title", timeout=60, state='invisible')
206
+ s.driver.ensure_element("class name", "desktop-onboarding__title", timeout=60, state='invisible')
202
207
  print('Thanks!')
203
208
 
204
209
  if not reddit_user_name:
@@ -233,7 +238,7 @@ reddit_user_name = ''
233
238
 
234
239
  driver = webdriver.Chrome('./chromedriver')
235
240
  driver.get('http://reddit.com')
236
- driver.find_element_by_xpath("//a[@href='https://www.reddit.com/login']").click()
241
+ driver.find_element("xpath", "//a[@href='https://www.reddit.com/login']").click()
237
242
 
238
243
  print('Waiting for elements to load...')
239
244
  WebDriverWait(driver, 15).until(
@@ -244,7 +249,7 @@ if reddit_user_name:
244
249
  WebDriverWait(driver, 15).until(
245
250
  EC.presence_of_element_located((By.ID, 'user_login'))
246
251
  ).send_keys(reddit_user_name)
247
- driver.find_element_by_id('passwd_login').send_keys(Keys.BACKSPACE)
252
+ driver.find_element('id', 'passwd_login').send_keys(Keys.BACKSPACE)
248
253
  print('Please log-in in the chrome browser')
249
254
 
250
255
  try:
@@ -0,0 +1,145 @@
1
+ [project]
2
+ name = "requestium"
3
+ version = "0.5.1"
4
+ readme = { file = "README.md", content-type = "text/markdown" }
5
+ requires-python = ">=3.10"
6
+ license = { file = "LICENSE" }
7
+ authors = [
8
+ { name = "Joaquin Alori", email = "joaquin@tryolabs.com" }
9
+ ]
10
+ maintainers = [
11
+ { name = "Judson Neer", email = "jkudson.neer@gmail.com" },
12
+ ]
13
+ classifiers = [
14
+ "Development Status :: 4 - Beta",
15
+ "Intended Audience :: Developers",
16
+ "License :: OSI Approved :: BSD License",
17
+ "Programming Language :: Python :: 3.10",
18
+ "Programming Language :: Python :: 3.11",
19
+ "Programming Language :: Python :: 3.12",
20
+ "Programming Language :: Python :: 3.13",
21
+ "Programming Language :: Python :: 3.14",
22
+ "Natural Language :: English",
23
+ "Operating System :: MacOS",
24
+ "Operating System :: Microsoft :: Windows",
25
+ "Operating System :: POSIX",
26
+ "Operating System :: OS Independent",
27
+ "Environment :: Web Environment",
28
+ "Programming Language :: Python :: Implementation :: CPython",
29
+ "Topic :: Software Development :: Libraries :: Python Modules",
30
+ "Topic :: Software Development :: Testing",
31
+ ]
32
+ dependencies = [
33
+ "parsel>=1.7",
34
+ "requests>=2.27",
35
+ "selenium>=4.32",
36
+ "tldextract>=5.3",
37
+ ]
38
+
39
+ [project.urls]
40
+ source = "https://github.com/tryolabs/requestium"
41
+ download = "https://pypi.org/project/requestium/#files"
42
+ issues = "https://github.com/tryolabs/requestium/issues"
43
+
44
+ [project.optional-dependencies]
45
+ dev = [
46
+ "bandit[sarif]==1.9.2",
47
+ "mypy==1.19.1",
48
+ "pre-commit~=4.5.0",
49
+ "pytest-cov~=7.0.0",
50
+ "pytest-xdist~=3.8.0",
51
+ "pytest~=9.0.0",
52
+ "ruff==0.14.11",
53
+ "ssort==0.16.0",
54
+ "types-requests==2.32.4.20260107",
55
+ ]
56
+
57
+ [tool]
58
+
59
+ [tool.ruff]
60
+ line-length = 160
61
+ include = [
62
+ "requestium/**/*.py",
63
+ "tests/**/*.py",
64
+ ]
65
+
66
+ [tool.ruff.lint]
67
+ extend-select = [
68
+ "A", # flake8-builtins (A)
69
+ "ANN", # flake8-annotations (ANN)
70
+ "ARG", # flake8-unused-arguments (ARG)
71
+ "B", # flake8-bugbear (B)
72
+ "BLE", # flake8-blind-except (BLE)
73
+ "C4", # flake8-comprehensions (C4)
74
+ "C90", # mccabe (C90)
75
+ "D", # pydocstyle (D)
76
+ "DTZ", # flake8-datetimez (DTZ)
77
+ "E", # pycodestyle-error (E)
78
+ "EM", # flake8-errmsg (EM)
79
+ "EXE", # flake8-executable (EXE)
80
+ "F", # Pyflakes (F)
81
+ "FA", # flake8-future-annotations (FA)
82
+ "FBT", # flake8-boolean-trap (FBT)
83
+ "FIX", # flake8-fixme (FIX)
84
+ "G", # flake8-logging-format (G)
85
+ "I", # isort (I)
86
+ "ICN", # flake8-import-conventions (ICN)
87
+ "INP", # flake8-no-pep420 (INP)
88
+ "INT", # flake8-gettext (INT)
89
+ "ISC", # flake8-implicit-str-concat (ISC)
90
+ "LOG", # flake8-logging (LOG)
91
+ "N", # pep8-naming (N)
92
+ "PIE", # flake8-pie (PIE)
93
+ "PL", # Pylint (PL)
94
+ "PT", # flake8-pytest-style (PT)
95
+ "PTH", # flake8-use-pathlib (PTH)
96
+ "Q", # flake8-quotes (Q)
97
+ "RET", # flake8-return (RET)
98
+ "RSE", # flake8-raise (RSE)
99
+ "RUF", # Ruff-specific rules (RUF)
100
+ "SIM", # flake8-simplify (SIM)
101
+ "SLF", # flake8-self (SLF)
102
+ "T10", # flake8-debugger (T10)
103
+ "T20", # flake8-print (T20)
104
+ "TC", # flake8-type-checking (TC)
105
+ "TD", # flake8-todos (TD)
106
+ "TID", # flake8-tidy-imports (TID)
107
+ "UP", # pyupgrade (UP)
108
+ "W", # pycodestyle-warning (W)
109
+ "YTT", # flake8-2020 (YTT)
110
+ ]
111
+ ignore = [
112
+ "ANN002", # missing-type-args (ANN002)
113
+ "ANN003", # missing-type-kwargs (ANN003)
114
+ "D100", # undocumented-public-module (D100)
115
+ "D102", # undocumented-public-method (D102)
116
+ "D103", # undocumented-public-function (D103)
117
+ "D104", # undocumented-public-package (D104)
118
+ "D107", # undocumented-public-init (D107)
119
+ "D203", # incorrect-blank-line-before-class (D203)
120
+ "D212", # multi-line-summary-first-line (D212)
121
+ "FIX002", # line-contains-todo (FIX002)
122
+ ]
123
+
124
+ [tool.ruff.lint.per-file-ignores]
125
+ "**/{tests,docs}/*" = [
126
+ "SLF001", # private-member-access (SLF001)
127
+ "PLR2004", # magic-value-comparison (PLR2004)
128
+ ]
129
+
130
+ [tool.pytest]
131
+ addopts = ["-n", "auto", "--cov=requestium", "--no-cov-on-fail"]
132
+ testpaths = [
133
+ "tests",
134
+ ]
135
+
136
+ [tool.coverage]
137
+
138
+ [tool.coverage.run]
139
+ branch = true
140
+ relative_files = true
141
+
142
+ [tool.coverage.report]
143
+ exclude_also = [
144
+ "logger\\.",
145
+ ]
@@ -1,4 +1,5 @@
1
1
  from selenium.common import exceptions # noqa: F401
2
+ from selenium.webdriver.common.by import By # noqa: F401
2
3
  from selenium.webdriver.common.keys import Keys # noqa: F401
3
4
  from selenium.webdriver.support.ui import Select # noqa: F401
4
5
 
@@ -0,0 +1,6 @@
1
+ from .requestium_mixin import ( # noqa: F401
2
+ DriverMixin,
3
+ _ensure_click,
4
+ )
5
+ from .requestium_response import RequestiumResponse # noqa: F401
6
+ from .requestium_session import Session # noqa: F401