python-filmaffinity 0.0.19__tar.gz → 0.0.21__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.
Files changed (33) hide show
  1. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/CHANGES.rst +13 -0
  2. python_filmaffinity-0.0.21/PKG-INFO +427 -0
  3. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/README.rst +15 -4
  4. python_filmaffinity-0.0.21/pyproject.toml +10 -0
  5. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/__init__.py +1 -2
  6. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/__meta__.py +4 -5
  7. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/client.py +150 -36
  8. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/detail.py +43 -20
  9. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/images.py +13 -9
  10. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/page.py +58 -17
  11. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/search.py +3 -3
  12. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/top_service.py +5 -2
  13. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/proxies.py +3 -1
  14. python_filmaffinity-0.0.21/python_filmaffinity.egg-info/PKG-INFO +427 -0
  15. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity.egg-info/SOURCES.txt +3 -1
  16. python_filmaffinity-0.0.21/python_filmaffinity.egg-info/requires.txt +8 -0
  17. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/setup.cfg +0 -3
  18. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/setup.py +14 -4
  19. python_filmaffinity-0.0.21/tests/test.py +221 -0
  20. python_filmaffinity-0.0.19/PKG-INFO +0 -391
  21. python_filmaffinity-0.0.19/python_filmaffinity.egg-info/PKG-INFO +0 -391
  22. python_filmaffinity-0.0.19/python_filmaffinity.egg-info/requires.txt +0 -4
  23. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/AUTHORS.rst +0 -0
  24. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/EXAMPLES.rst +0 -0
  25. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/LICENSE.rst +0 -0
  26. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/MANIFEST.in +0 -0
  27. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/config.py +0 -0
  28. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/exceptions.py +0 -0
  29. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/__init__.py +0 -0
  30. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity/pages/top.py +0 -0
  31. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity.egg-info/dependency_links.txt +0 -0
  32. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity.egg-info/not-zip-safe +0 -0
  33. {python_filmaffinity-0.0.19 → python_filmaffinity-0.0.21}/python_filmaffinity.egg-info/top_level.txt +0 -0
@@ -1,6 +1,19 @@
1
1
  Changelog
2
2
  =========
3
3
 
4
+ v0.0.21 (17-06-2026)
5
+ ********************
6
+
7
+ - Updated scraping for the current FilmAffinity layout.
8
+ - Replaced the deprecated user-agent dependency with an internal header pool.
9
+ - Added fast parser tests and optional live integration tests.
10
+ - Modernized packaging metadata and GitHub Actions.
11
+
12
+ v0.0.20 (28-09-2023)
13
+ ********************
14
+
15
+ - Scrapping updated
16
+
4
17
  v0.0.19 (22-06-2021)
5
18
  ********************
6
19
 
@@ -0,0 +1,427 @@
1
+ Metadata-Version: 2.4
2
+ Name: python_filmaffinity
3
+ Version: 0.0.21
4
+ Summary: Python wrapper for FilmAffinity
5
+ Home-page: https://github.com/sergiormb/python_filmaffinity
6
+ Download-URL: https://github.com/sergiormb/python_filmaffinity/tarball/0.0.21
7
+ Author: sergiormb
8
+ Author-email: sergiormb88@gmail.com
9
+ License: MIT
10
+ Keywords: filmaffinity movies films
11
+ Classifier: Environment :: Web Environment
12
+ Classifier: Intended Audience :: Developers
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python
15
+ Classifier: Programming Language :: Python
16
+ Classifier: Programming Language :: Python :: 3
17
+ Classifier: Programming Language :: Python :: 3.9
18
+ Classifier: Programming Language :: Python :: 3.10
19
+ Classifier: Programming Language :: Python :: 3.11
20
+ Classifier: Programming Language :: Python :: 3.12
21
+ Classifier: Programming Language :: Python :: 3.13
22
+ Classifier: Programming Language :: Python :: 3.14
23
+ Requires-Python: >=3.9
24
+ Description-Content-Type: text/x-rst
25
+ License-File: LICENSE.rst
26
+ License-File: AUTHORS.rst
27
+ Requires-Dist: beautifulsoup4>=4.9.1
28
+ Requires-Dist: requests>=2.24.0
29
+ Requires-Dist: requests-cache>=1.0.0
30
+ Provides-Extra: dev
31
+ Requires-Dist: build>=1.0; extra == "dev"
32
+ Requires-Dist: pytest>=8.0; extra == "dev"
33
+ Requires-Dist: twine>=5.0; extra == "dev"
34
+ Dynamic: author
35
+ Dynamic: author-email
36
+ Dynamic: classifier
37
+ Dynamic: description
38
+ Dynamic: description-content-type
39
+ Dynamic: download-url
40
+ Dynamic: home-page
41
+ Dynamic: keywords
42
+ Dynamic: license
43
+ Dynamic: license-file
44
+ Dynamic: provides-extra
45
+ Dynamic: requires-dist
46
+ Dynamic: requires-python
47
+ Dynamic: summary
48
+
49
+ *******************
50
+ Python FilmAffinity
51
+ *******************
52
+ This is a simple python scraping for the FilmAffinity.
53
+
54
+
55
+ .. image:: https://github.com/sergiormb/python_filmaffinity/workflows/Tests/badge.svg?branch=master
56
+ :target: https://github.com/sergiormb/python_filmaffinity/actions/workflows/python-test.yml?query=branch%3Amaster
57
+ .. image:: https://img.shields.io/github/license/mashape/apistatus.svg
58
+ :target: https://github.com/sergiormb/python_filmaffinity/blob/master/LICENSE.rst
59
+ .. image:: https://img.shields.io/pypi/pyversions/Django.svg
60
+ :target: https://pypi.python.org/pypi/python_filmaffinity/
61
+ .. image:: https://readthedocs.org/projects/python-filmaffinity/badge/?version=latest
62
+ :target: http://python-filmaffinity.readthedocs.io/en/latest/?badge=latest
63
+
64
+
65
+ Installation
66
+ ============
67
+
68
+ Pip
69
+ ***
70
+ ::
71
+
72
+ pip install python-filmaffinity
73
+
74
+
75
+ From Source
76
+ ***********
77
+
78
+ ::
79
+
80
+ git clone git@github.com:sergiormb/python_filmaffinity.git
81
+ cd python_filmaffinity
82
+ python setup.py install
83
+
84
+
85
+ Requirements
86
+ **********************
87
+
88
+ ::
89
+
90
+ requests >= 2.0.1
91
+ requests-cache >= 0.4.13
92
+ bs4 >= 0.0.1
93
+
94
+
95
+ Examples
96
+ ========
97
+
98
+ .. code-block:: python
99
+
100
+ import python_filmaffinity
101
+ service = python_filmaffinity.FilmAffinity()
102
+ movie = service.get_movie(title='Celda 211')
103
+ movie['title']
104
+ Celda 211
105
+ movie['rating']
106
+ 7.7
107
+ movie['directors']
108
+ ['Daniel Monzón']
109
+ movie['actors']
110
+ ['Luis Tosar', 'Alberto Ammann', 'Antonio Resines', 'Carlos Bardem', 'Marta Etura', 'Vicente Romero', 'Manuel Morón', 'Manolo Solo', 'Fernando Soto', 'Luis Zahera', 'Patxi Bisquert', 'Félix Cubero', 'Josean Bengoetxea', 'Juan Carlos Mangas', 'Jesús Carroza']
111
+
112
+
113
+ Usage
114
+ =====
115
+
116
+ language
117
+ ********
118
+
119
+ - Spanish: 'es'
120
+ - USA, UK: 'en'
121
+ - México: 'mx'
122
+ - Argentina: 'ar'
123
+ - Chile: 'cl'
124
+ - Colombia: 'co'
125
+
126
+
127
+ - Example
128
+
129
+ .. code-block:: python
130
+
131
+ import python_filmaffinity
132
+ service = python_filmaffinity.FilmAffinity(lang='en')
133
+
134
+
135
+ search
136
+ ******
137
+
138
+ +-----------+----------+--------+-----------------------------------+
139
+ | Parameter | Required | Type | Description |
140
+ +===========+==========+========+===================================+
141
+ | title | False | String | Search for the title of the movie |
142
+ +-----------+----------+--------+-----------------------------------+
143
+ | cast | False | String | Search movies by actor |
144
+ +-----------+----------+--------+-----------------------------------+
145
+ | director | False | String | Search movies by the director |
146
+ +-----------+----------+--------+-----------------------------------+
147
+ | from_year | False | String | Search start date |
148
+ +-----------+----------+--------+-----------------------------------+
149
+ | to_year | False | String | Search end date |
150
+ +-----------+----------+--------+-----------------------------------+
151
+
152
+ - Example
153
+
154
+ .. code-block:: python
155
+
156
+ movies = service.search(cast='Nicolas Cage')
157
+
158
+
159
+ get_movie
160
+ *********
161
+
162
+ +-----------+----------+--------+-----------------------------------+
163
+ | Parameter | Required | Type | Description |
164
+ +===========+==========+========+===================================+
165
+ | id | False | String | FilmAffinity id |
166
+ +-----------+----------+--------+-----------------------------------+
167
+ | title | False | String | Get movie by title |
168
+ +-----------+----------+--------+-----------------------------------+
169
+ | trailer | False | Boolean| Return movie with trailer |
170
+ +-----------+----------+--------+-----------------------------------+
171
+ | images | False | Boolean| Return movie with images |
172
+ +-----------+----------+--------+-----------------------------------+
173
+
174
+ - Example
175
+
176
+ .. code-block:: python
177
+
178
+ movies = service.get_movie(title='Avatar')
179
+ movies = service.get_movie(id='495280')
180
+
181
+
182
+ top_filmaffinity
183
+ ****************
184
+
185
+ +-----------+----------+--------+-----------------------------------+
186
+ | Parameter | Required | Type | Description |
187
+ +===========+==========+========+===================================+
188
+ | from_year | False | String | Search start date |
189
+ +-----------+----------+--------+-----------------------------------+
190
+ | to_year | False | String | Search end date |
191
+ +-----------+----------+--------+-----------------------------------+
192
+ | top | False | Integer| Number of elements |
193
+ +-----------+----------+--------+-----------------------------------+
194
+
195
+ - Example
196
+
197
+ .. code-block:: python
198
+
199
+ movies = service.top_filmaffinity()
200
+ movies = service.top_filmaffinity(from_year=2010, to_year=2011)
201
+
202
+
203
+ top_premieres
204
+ *************
205
+
206
+ +-----------+----------+--------+-----------------------------------+
207
+ | Parameter | Required | Type | Description |
208
+ +===========+==========+========+===================================+
209
+ | top | False | Integer| Number of elements |
210
+ +-----------+----------+--------+-----------------------------------+
211
+
212
+ - Example
213
+
214
+ .. code-block:: python
215
+
216
+ movies = service.top_premieres()
217
+
218
+
219
+ top_netflix, top_hbo, top_filmin, top_movistar, top_rakuten, top_tv_series
220
+ **************************************************************************
221
+
222
+ +-----------+----------+--------+-----------------------------------+
223
+ | Parameter | Required | Type | Description |
224
+ +===========+==========+========+===================================+
225
+ | top | False | Integer| Number of elements |
226
+ +-----------+----------+--------+-----------------------------------+
227
+
228
+ - Example
229
+
230
+ .. code-block:: python
231
+
232
+ movies = service.top_netflix()
233
+ movies = service.top_hbo(top=5)
234
+ movies = service.top_filmin()
235
+ movies = service.top_movistar()
236
+ movies = service.top_rakuten()
237
+ movies = service.top_tv_series()
238
+
239
+
240
+ recommend HBO, Netflix, Filmin, Movistar, Rakuten
241
+ *************************************************
242
+
243
+ +-----------+----------+--------+-----------------------------------+
244
+ | Parameter | Required | Type | Description |
245
+ +===========+==========+========+===================================+
246
+ | trailer | False | Boolean| Return movie with trailer |
247
+ +-----------+----------+--------+-----------------------------------+
248
+ | images | False | Boolean| Return movie with images |
249
+ +-----------+----------+--------+-----------------------------------+
250
+
251
+ - Example
252
+
253
+ .. code-block:: python
254
+
255
+ movies = service.recommend_netflix()
256
+ movies = service.recommend_hbo()
257
+ movies = service.recommend_filmin()
258
+ movies = service.recommend_movistar()
259
+ movies = service.recommend_rakuten()
260
+
261
+
262
+ Changelog
263
+ =========
264
+ v0.0.21 (17-06-2026)
265
+ ********************
266
+
267
+ - Updated scraping for the current FilmAffinity layout.
268
+ - Replaced the deprecated user-agent dependency with an internal header pool.
269
+ - Added fast parser tests and optional live integration tests.
270
+ - Modernized packaging metadata and GitHub Actions.
271
+
272
+ v0.0.20 (28-09-2023)
273
+ ********************
274
+
275
+ - Scrapping updated
276
+
277
+ v0.0.19 (22-06-2021)
278
+ ********************
279
+
280
+ - Fixed errors in get_country
281
+
282
+ v0.0.18 (26-02-2021)
283
+ ********************
284
+
285
+ - When images are requested, lets provide also the country where
286
+ they were published (@jcea)
287
+ - Correctly provide the trailers listed in filmaffinity (@jcea)
288
+ - Spurious search in youtube deleted (@jcea)
289
+ - Extract correctly when multiple genres (@jcea)
290
+ - Added "writers", "music", "cinematography" and "producers" (@jcea)
291
+ - Regression processing "original_title" in searches (@jcea)
292
+
293
+ v0.0.17 (18-02-2021)
294
+ ********************
295
+
296
+ - Deleted spaces at the end of the title (@jcea)
297
+ - Added original_title (@jcea)
298
+ - Fix directors scraping (@jcea)
299
+
300
+ v0.0.15 (03-08-2020)
301
+ ********************
302
+
303
+ - Search by genre
304
+
305
+ v0.0.14 (08-09-2018)
306
+ ********************
307
+
308
+ - Fixed errors
309
+
310
+ v0.0.13 (07-09-2018)
311
+ ********************
312
+
313
+ - Adds proxies and random user-agent in headers
314
+
315
+ v0.0.12 (27-08-2018)
316
+ ********************
317
+
318
+ - Changed description
319
+
320
+ v0.0.11 (27-08-2018)
321
+ ********************
322
+
323
+ - Fixed errors
324
+
325
+ v0.0.1O (27-08-2018)
326
+ ********************
327
+
328
+ - Fixed errors with SSL
329
+
330
+ v0.0.09 (28-12-2017)
331
+ ********************
332
+
333
+ - Replaces cachetools for requests-cache
334
+
335
+ v0.0.8 (26-12-2017)
336
+ *******************
337
+
338
+ - Add images
339
+ - Fixed errors
340
+
341
+ v0.0.7 (15-12-2017)
342
+ *******************
343
+
344
+ - Fixes encoding for the analyzed results
345
+ - Disabled limitations for all the supported languages
346
+ - Change of name to the main class.
347
+ - Adds initial language check and raise error if this is not in support
348
+ - Adds basic exceptions
349
+
350
+ v0.0.6 (12-06-2017)
351
+ *******************
352
+
353
+ - Add cachetools
354
+
355
+ v0.0.5 (13-06-2017)
356
+ *******************
357
+
358
+ - Fixed errors
359
+
360
+ v0.0.4 (11-06-2017)
361
+ *******************
362
+
363
+ - Top new DVDs
364
+ - Get movie with trailer
365
+ - Top TV series
366
+ - Return movies list with raiting
367
+
368
+
369
+ v0.0.3 (10-06-2017)
370
+ *******************
371
+
372
+ - Top Netlfix, HBO and Filmin
373
+ - Recommendation from Netflix, HBO or Filmin
374
+ - Fixed errors
375
+
376
+
377
+ v0.0.2 (31-05-2017)
378
+ *******************
379
+
380
+ - Search movies by title, year, director or cast.
381
+ - Get the filmaffinity top and search by year
382
+ - Get the premieres top
383
+
384
+
385
+ v0.0.1 (29-05-2017)
386
+ *******************
387
+
388
+ - Initial release.
389
+
390
+
391
+ Authors
392
+ *******
393
+
394
+
395
+ Lead
396
+ ====
397
+
398
+ - Sergio Pino, sergiormb88@gmail.com, `sergiormb.github.io <https://sergiormb.github.io>`_
399
+
400
+ Collaborators
401
+ =============
402
+
403
+ - opacam https://github.com/opacam
404
+ - jcea - https://www.jcea.es/ - https://blog.jcea.es/ - https://github.com/jcea
405
+
406
+ License
407
+ =======
408
+
409
+ The MIT License (MIT)
410
+
411
+ Permission is hereby granted, free of charge, to any person obtaining a copy
412
+ of this software and associated documentation files (the "Software"), to deal
413
+ in the Software without restriction, including without limitation the rights
414
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
415
+ copies of the Software, and to permit persons to whom the Software is
416
+ furnished to do so, subject to the following conditions:
417
+
418
+ The above copyright notice and this permission notice shall be included in all
419
+ copies or substantial portions of the Software.
420
+
421
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
422
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
423
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
424
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
425
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
426
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
427
+ SOFTWARE.
@@ -3,10 +3,9 @@ Python FilmAffinity
3
3
  *******************
4
4
  This is a simple python scraping for the FilmAffinity.
5
5
 
6
- .. image:: https://travis-ci.org/sergiormb/python_filmaffinity.svg?branch=master
7
- :target: https://travis-ci.org/sergiormb/python_filmaffinity
8
- .. image:: https://coveralls.io/repos/github/sergiormb/python_filmaffinity/badge.svg?branch=master
9
- :target: https://coveralls.io/github/sergiormb/python_filmaffinity?branch=master
6
+
7
+ .. image:: https://github.com/sergiormb/python_filmaffinity/workflows/Tests/badge.svg?branch=master
8
+ :target: https://github.com/sergiormb/python_filmaffinity/actions/workflows/python-test.yml?query=branch%3Amaster
10
9
  .. image:: https://img.shields.io/github/license/mashape/apistatus.svg
11
10
  :target: https://github.com/sergiormb/python_filmaffinity/blob/master/LICENSE.rst
12
11
  .. image:: https://img.shields.io/pypi/pyversions/Django.svg
@@ -214,6 +213,18 @@ recommend HBO, Netflix, Filmin, Movistar, Rakuten
214
213
 
215
214
  Changelog
216
215
  =========
216
+ v0.0.21 (17-06-2026)
217
+ ********************
218
+
219
+ - Updated scraping for the current FilmAffinity layout.
220
+ - Replaced the deprecated user-agent dependency with an internal header pool.
221
+ - Added fast parser tests and optional live integration tests.
222
+ - Modernized packaging metadata and GitHub Actions.
223
+
224
+ v0.0.20 (28-09-2023)
225
+ ********************
226
+
227
+ - Scrapping updated
217
228
 
218
229
  v0.0.19 (22-06-2021)
219
230
  ********************
@@ -0,0 +1,10 @@
1
+ [build-system]
2
+ requires = ["setuptools>=68", "wheel"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [tool.pytest.ini_options]
6
+ testpaths = ["tests"]
7
+ python_files = ["test.py", "test_*.py"]
8
+ markers = [
9
+ "integration: tests that call filmaffinity.com",
10
+ ]
@@ -1,9 +1,8 @@
1
1
  # -*- coding: utf-8 -*-
2
- from .__meta__ import *
2
+ from .__meta__ import *
3
3
  from .client import Client
4
4
  from .config import FIELDS_TYPE
5
5
 
6
-
7
6
  class FilmAffinity(Client):
8
7
 
9
8
  def get_movie(self, trailer=False, images=False, **kwargs):
@@ -5,16 +5,15 @@ __title__ = 'python_filmaffinity'
5
5
  __summary__ = 'Python wrapper for FilmAffinity'
6
6
  __url__ = 'https://github.com/sergiormb/python_filmaffinity'
7
7
 
8
- __version__ = '0.0.19'
8
+ __version__ = '0.0.21'
9
9
 
10
10
  __install_requires__ = [
11
+ 'beautifulsoup4>=4.9.1',
11
12
  'requests>=2.24.0',
12
- 'requests-cache>=0.5.2',
13
- 'bs4>=0.0.1',
14
- 'user_agent==0.1.9',
13
+ 'requests-cache>=1.0.0',
15
14
  ]
16
15
 
17
16
  __author__ = 'sergiormb'
18
17
  __email__ = 'sergiormb88@gmail.com'
19
18
 
20
- __license__ = 'MIT License'
19
+ __license__ = 'MIT'