Skip to content

Commit 2bdc6b7

Browse files
committed
fixed silly problems with finding the validate target feed
1 parent ac99322 commit 2bdc6b7

File tree

5 files changed

+12
-11
lines changed

5 files changed

+12
-11
lines changed

.bumpversion.cfg

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
[bumpversion]
2-
current_version = 0.24.0
2+
current_version = 0.25.0
33
commit = True
44
tag = True
55

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
SPDX-License-Identifier: MIT
1010

11-
version="0.24.0"
11+
version="0.25.0"
1212

1313
What's New?
1414
===========

elmclient/__meta__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
app = 'elmoslcquery'
1111
description = 'Commandline OSLC query for ELM'
12-
version = '0.24.0'
12+
version = '0.25.0'
1313
license = 'MIT'
1414
author_name = 'Ian Barnard'
1515
author_mail = 'ian.barnard@uk.ibm.com'

elmclient/examples/validate.py

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -85,9 +85,9 @@ def do_validate(inputargs=None):
8585
parser_validate = subparsers.add_parser('validate', help='Validate a feed on this app' )
8686

8787
parser_validate.add_argument( 'feedid', help='The feed id - this can be an integer corresponding to the number in the list of feeds, or a unique string (case-sensitive!) which matches part of or all of exactly one feed ID or name')
88-
parser_validate.add_argument('-r', '--repair', action="store_true", help="Use to automatically resolve problems encountered in the feed. Ignored if not supported by the feed.")
89-
parser_validate.add_argument('-s', '--resetIncrementalData', action="store_true", help="Same the web UI option. If true the system will discard past validation results and recheck the entire feed again. Otherwise, only changes since last time will be validated. This option is normally only needed if indicated so by IBM support.")
9088
parser_validate.add_argument('-f', '--full', action="store_true", help="Same the web UI option. If true the entire TRS feed will be checked, which takes much longer. This may return more accurate results. This does not discard past validation results, so future validations can still be incremental. If this option consistently returns different results then you may need to also reset the incremental data")
89+
parser_validate.add_argument('-i', '--resetIncrementalData', action="store_true", help="Same the web UI option. If true the system will discard past validation results and recheck the entire feed again. Otherwise, only changes since last time will be validated. This option is normally only needed if indicated so by IBM support.")
90+
parser_validate.add_argument('-r', '--repair', action="store_true", help="Use to automatically resolve problems encountered in the feed. Ignored if not supported by the feed.")
9191

9292
args = parser.parse_args(inputargs)
9393

@@ -229,9 +229,11 @@ def do_validate(inputargs=None):
229229
feedid = int( args.feedid )
230230
if feedid < 0 or feedid > len(feeds):
231231
raise Exception( f"Invalid feed number {feedid}" )
232-
id = feeds[feedid]['id']
232+
theid = feeds[feedid]['id']
233233
name = feeds[feedid]['name']
234-
print( f"Using list entry {feedid} which has {id=} and {name=}" )
234+
print( f"Using list entry {feedid} which has {theid=} and {name=}" )
235+
# print( f"Validating feed '{theid}' '{feeds[feedid]['name']}'" )
236+
# theid = feeds[id]['id']
235237
# or try to match a string against the feed IDs or names - zero or >1 match is an error!
236238
else:
237239
matches = 0
@@ -249,9 +251,8 @@ def do_validate(inputargs=None):
249251
raise Exception( f"No id or name contains '{args.feedid}'" )
250252
if matches > 1:
251253
raise Exception( f"id '{args.feedid}' matches more than one id or name" )
252-
id = firstid
253-
theid = feeds[id]['id']
254-
print( f"Validating feed '{feeds[id]['name']}'" )
254+
theid = feeds[firstid]['id']
255+
print( f"Validating feed '{theid}' '{feeds[firstid]['name']}'" )
255256

256257
result = app.validate( theid, repair=args.repair, resetIncrementalData=args.resetIncrementalData, full=args.full )
257258
# print( f"{result=}" )

setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
# This call to setup() does all the work
1717
setup(
1818
name="elmclient",
19-
version="0.24.0",
19+
version="0.25.0",
2020
description="Python client for ELM with examples of OSLC Query, ReqIF import/export, Reportable REST, and more",
2121
long_description=README,
2222
long_description_content_type="text/markdown",

0 commit comments

Comments
 (0)