From 587d6882ef7343358bf12fa919eb00517fc2d25d Mon Sep 17 00:00:00 2001 From: Bob Weigel Date: Mon, 10 Aug 2026 16:06:28 -0400 Subject: [PATCH] do not warn --- CHANGES.txt | 3 ++- hapiclient/capabilities.py | 12 ++++++------ hapiclient/info.py | 2 +- 3 files changed, 9 insertions(+), 8 deletions(-) diff --git a/CHANGES.txt b/CHANGES.txt index 7f5af7e..6e2c56a 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -134,4 +134,5 @@ v0.3.1: v0.3.2: 2026-07-08 -- Date parsing warning https://github.com/hapi-server/client-python/pull/104 v0.3.3b0: - 2026-07-22 -- Makefile and related updates \ No newline at end of file + 2026-07-22 -- Makefile and related updates + 2026-08-10 -- Don't warn if binary not available \ No newline at end of file diff --git a/hapiclient/capabilities.py b/hapiclient/capabilities.py index 8732cf4..bcf710a 100644 --- a/hapiclient/capabilities.py +++ b/hapiclient/capabilities.py @@ -18,15 +18,14 @@ def capabilities(SERVER): def get_format(SERVER, format): """Return the transport format to use, accounting for server capabilities. - If the requested format is not supported by the server, falls back to 'csv' - with a warning. + If the requested format is not supported by the server, falls back to 'csv'. """ - from hapiclient.util import error, warning + from hapiclient.util import error cformats = ['csv', 'binary'] # client formats if format not in cformats: - msg = 'This client does not handle transport format "%s". Available options: %s' + msg = 'This client does not handle streaming format "%s". Available options: %s' error(msg % (format, ', '.join(cformats))) if format != 'csv': @@ -39,8 +38,9 @@ def get_format(SERVER, format): return 'csv' if format not in formats: - msg = 'Requested transport format "%s" not avaiable from %s. Will use "csv". Available options: %s' - warning(msg % (format, SERVER, ', '.join(formats))) + #from hapiclient.util import warning + #msg = 'Requested streaming format "%s" not available from %s. Will use "csv". Available options: %s' + #warning(msg % (format, SERVER, ', '.join(formats))) format = 'csv' if 'binary' not in formats: diff --git a/hapiclient/info.py b/hapiclient/info.py index fd3b2f0..45356d6 100644 --- a/hapiclient/info.py +++ b/hapiclient/info.py @@ -9,7 +9,7 @@ def info(SERVER, DATASET, PARAMETERS, opts): meta = meta_cache_read(SERVER, DATASET, opts) if meta is not None: - return meta + return meta cat = catalog(SERVER) url = SERVER + '/info?' + query_name(cat, 'dataset') + '=' + DATASET