cloudnet-api-client 0.5.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.
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## 0.5.1 – 2025-04-04
9
+
10
+ - Raise if downloading failed after retries
11
+ - Adjust logging
12
+
8
13
  ## 0.5.0 – 2025-04-04
9
14
 
10
15
  - Add option to query one site
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cloudnet-api-client
3
- Version: 0.5.0
3
+ Version: 0.5.1
4
4
  Summary: Cloudnet API client
5
5
  Author-email: Simo Tukiainen <simo.tukiainen@fmi.fi>
6
6
  License-File: LICENSE
@@ -30,7 +30,7 @@ async def download_files(
30
30
  destination = output_path / meta.download_url.split("/")[-1]
31
31
  full_paths.append(destination)
32
32
  if destination.exists() and _file_checksum_matches(meta, destination):
33
- logging.info(f"Already downloaded: {destination}")
33
+ logging.debug(f"Already downloaded: {destination}")
34
34
  continue
35
35
  task = asyncio.create_task(
36
36
  _download_file_with_retries(
@@ -61,6 +61,7 @@ async def _download_file_with_retries(
61
61
  logging.warning(f"Attempt {attempt} failed for {url}: {e}")
62
62
  if attempt == max_retries:
63
63
  logging.error(f"Giving up on {url} after {max_retries} attempts.")
64
+ raise e
64
65
  else:
65
66
  # Exponential backoff before retrying
66
67
  await asyncio.sleep(2**attempt)
@@ -93,7 +94,7 @@ async def _download_file(
93
94
  break
94
95
  file_out.write(chunk)
95
96
  bar.update(len(chunk))
96
- logging.info(f"Downloaded: {destination}")
97
+ logging.debug(f"Downloaded: {destination}")
97
98
 
98
99
 
99
100
  def _file_checksum_matches(
@@ -0,0 +1 @@
1
+ __version__ = "0.5.1"
@@ -1 +0,0 @@
1
- __version__ = "0.5.0"