meteocatpy 0.0.21 → 1.0.2

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.
package/.gitlab-ci.yml CHANGED
@@ -29,12 +29,12 @@ default:
29
29
  github_job:
30
30
  stage: github
31
31
  script:
32
- - git checkout master # Asegurarse de estar en la rama master
33
- - git remote set-url origin "$GH_REMOTE_URL" # Cambiar la URL para GitHub
34
- # - poetry run semantic-release version # Generar nueva versión
35
- # - poetry run semantic-release publish # Ejecutar el comando para publicar el release
36
- - git push origin master # Hacer push al repositorio de GitHub
37
- allow_failure: true # Opcional: evita que el pipeline falle completamente
32
+ - git checkout master
33
+ - git remote set-url origin "$GH_REMOTE_URL"
34
+ - git config --global user.name "$GIT_USER_NAME"
35
+ - git config --global user.email "$GIT_USER_EMAIL"
36
+ - git remote set-url origin "https://x-access-token:${GH_TOKEN}@github.com/figorr/meteocatpy.git"
37
+ allow_failure: true
38
38
  only:
39
39
  - master
40
40
 
package/CHANGELOG.md CHANGED
@@ -1,3 +1,26 @@
1
+ ## [1.0.2](https://github.com/figorr/meteocatpy/compare/v1.0.1...v1.0.2) (2025-11-06)
2
+
3
+
4
+ ### Bug Fixes
5
+
6
+ * Python 3.14 full support (aiohttp 3.11.10) ([e228668](https://github.com/figorr/meteocatpy/commit/e22866820c6a1c1673e0ed8461a40eaf01d298f8))
7
+
8
+ ## [1.0.1](https://github.com/figorr/meteocatpy/compare/v1.0.0...v1.0.1) (2025-02-05)
9
+
10
+
11
+ ### Bug Fixes
12
+
13
+ * 1.0.1 ([fc92ac1](https://github.com/figorr/meteocatpy/commit/fc92ac1fe40ff31cb0c38c5864d53209f42e128d))
14
+ * fix lightning api call code ([9abc092](https://github.com/figorr/meteocatpy/commit/9abc092b6951051279887d8ab09e2551371ea3b8))
15
+
16
+ ## [1.0.0](https://github.com/figorr/meteocatpy/compare/v0.0.20...v1.0.0) (2025-02-04)
17
+
18
+
19
+ ### Bug Fixes
20
+
21
+ * 1.0.0 ([c237e77](https://github.com/figorr/meteocatpy/commit/c237e7736f3504f19a1bb2e39ed7edd3264de115))
22
+
23
+
1
24
  ## [0.0.21](https://github.com/figorr/meteocatpy/compare/v0.0.20...v0.0.21) (2025-02-04)
2
25
 
3
26
 
@@ -14,12 +14,12 @@ from .exceptions import (
14
14
 
15
15
  _LOGGER = logging.getLogger(__name__)
16
16
 
17
- class MeteocatLightningData:
17
+ class MeteocatLightning:
18
18
  """Clase para interactuar con los datos de rayos de la API de Meteocat."""
19
19
 
20
20
  def __init__(self, api_key: str):
21
21
  """
22
- Inicializa la clase MeteocatStationData.
22
+ Inicializa la clase MeteocatLightning.
23
23
 
24
24
  Args:
25
25
  api_key (str): Clave de API para autenticar las solicitudes.
@@ -29,7 +29,6 @@ class MeteocatLightningData:
29
29
  "Content-Type": "application/json",
30
30
  "X-Api-Key": self.api_key,
31
31
  }
32
- self.variables = MeteocatVariables(api_key)
33
32
 
34
33
  @staticmethod
35
34
  def get_current_date():
@@ -1,2 +1,2 @@
1
1
  # version.py
2
- __version__ = "1.0.0"
2
+ __version__ = "1.0.2"
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "meteocatpy",
3
- "version": "0.0.21",
3
+ "version": "1.0.2",
4
4
  "description": "[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\r [![Python version compatibility](https://img.shields.io/pypi/pyversions/meteocatpy)](https://pypi.org/project/meteocatpy)\r [![pipeline status](https://gitlab.com/figorr/meteocatpy/badges/master/pipeline.svg)](https://gitlab.com/figorr/meteocatpy/commits/master)",
5
5
  "main": "index.js",
6
6
  "directories": {
package/poetry.lock CHANGED
@@ -119,21 +119,6 @@ yarl = ">=1.17.0,<2.0"
119
119
  [package.extras]
120
120
  speedups = ["Brotli", "aiodns (>=3.2.0)", "brotlicffi"]
121
121
 
122
- [[package]]
123
- name = "aioresponses"
124
- version = "0.7.7"
125
- description = "Mock out requests made by ClientSession from aiohttp package"
126
- optional = false
127
- python-versions = "*"
128
- files = [
129
- {file = "aioresponses-0.7.7-py2.py3-none-any.whl", hash = "sha256:6975f31fe5e7f2113a41bd387221f31854f285ecbc05527272cd8ba4c50764a3"},
130
- {file = "aioresponses-0.7.7.tar.gz", hash = "sha256:66292f1d5c94a3cb984f3336d806446042adb17347d3089f2d3962dd6e5ba55a"},
131
- ]
132
-
133
- [package.dependencies]
134
- aiohttp = ">=3.3.0,<4.0.0"
135
- packaging = ">=22.0"
136
-
137
122
  [[package]]
138
123
  name = "aiosignal"
139
124
  version = "1.3.1"
@@ -3309,5 +3294,5 @@ type = ["pytest-mypy"]
3309
3294
 
3310
3295
  [metadata]
3311
3296
  lock-version = "2.0"
3312
- python-versions = ">=3.12,<3.14"
3313
- content-hash = "6d509b52a264f5b0a35a2dd692d63c2c12cc8b866ba64f35779d1d2a6f64db2b"
3297
+ python-versions = ">=3.12,<4.0"
3298
+ content-hash = "8ef18586dfea205b5f593ad7ca036529093dcbc192da6907d2f7df63d53a0829"
package/pyproject.toml CHANGED
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "meteocatpy"
3
- version = "1.0.0"
3
+ version = "1.0.2"
4
4
  description = "Script para obtener datos meteorológicos de la API de Meteocat"
5
5
  authors = ["figorr <jdcuartero@yahoo.es>"]
6
6
  license = "Apache-2.0"
@@ -10,7 +10,7 @@ keywords = ['meteocatpy', 'meteocat']
10
10
 
11
11
 
12
12
  [tool.poetry.dependencies]
13
- python = ">=3.12,<3.14"
13
+ python = ">=3.12,<4.0"
14
14
  requests = "^2.32.3"
15
15
  python-dotenv = "^1.0.1"
16
16
  simplejson = "^3.19.3"
@@ -21,7 +21,10 @@ aiofiles = "^24.1.0"
21
21
  voluptuous = "^0.15.2"
22
22
  geopy = "^2.4.1"
23
23
  tzdata = "^2024.2"
24
- aiohttp = ">=3.10.11,<4.0.0"
24
+ aiohttp = [
25
+ {version = ">=3.10.11,<4.0.0", python = "<3.14"},
26
+ {version = ">=3.8.0", python = ">=3.14"}
27
+ ]
25
28
  diskcache = "^5.6.3"
26
29
  semantic-release = "^0.1.0"
27
30
 
@@ -69,4 +72,7 @@ pre-commit = "^3.3.1"
69
72
  pytest = "^8.3.3"
70
73
  pytest-asyncio = "^0.24.0"
71
74
  syrupy = "^4.7.2"
72
- aioresponses = "^0.7.7"
75
+ # aioresponses = [
76
+ # {version = "^0.7.7", python = "<3.14"},
77
+ # {version = "^0.8.0", python = ">=3.14"}
78
+ # ]
@@ -2,7 +2,7 @@ import os
2
2
  import pytest
3
3
  import json
4
4
  from dotenv import load_dotenv
5
- from meteocatpy.lightning import MeteocatLightningData
5
+ from meteocatpy.lightning import MeteocatLightning
6
6
 
7
7
  # Cargar variables desde el archivo .env
8
8
  load_dotenv()
@@ -18,7 +18,7 @@ assert REGION_CODI_TEST, "Region codi test is required"
18
18
  @pytest.mark.asyncio
19
19
  async def test_lightning():
20
20
  # Crear una instancia de MeteocatLightningData con la API Key
21
- lightning_client = MeteocatLightningData(API_KEY)
21
+ lightning_client = MeteocatLightning(API_KEY)
22
22
 
23
23
  # Obtener los datos de rayos
24
24
  lightning_data = await lightning_client.get_lightning_data(REGION_CODI_TEST)
@@ -29,7 +29,7 @@ async def test_lightning():
29
29
  os.makedirs('tests/files', exist_ok=True)
30
30
 
31
31
  # Guardar los datos de rayos en un archivo JSON
32
- with open(f'tests/files/lightning_{REGION_CODI_TEST}_data.json', 'w', encoding='utf-8') as f:
32
+ with open(f'tests/files/lightning_{REGION_CODI_TEST}.json', 'w', encoding='utf-8') as f:
33
33
  json.dump(lightning_data, f, ensure_ascii=False, indent=4)
34
34
 
35
35
  # Verificar que los datos de rayos sean una lista