Project

General

Profile

Feature #23289

Return both campaign name and stage name for the get_campaign_stage_name poms_client API

Added by Yuyi Guo 3 months ago. Updated 3 months ago.

Status:
Resolved
Priority:
Normal
Target version:
Start date:
09/17/2019
Due date:
% Done:

100%

Estimated time:
4.00 h
Spent time:
Scope:
Internal
Experiment:
-
Stakeholders:
Duration:

Description

The current poms_Client API: get_campaign_stage_name(experiment, campaign_stage_id, test=None, configfile=None) return campaign_stage_Name. We have a use case that we need to get the campaign name from a stage id. So make the API return both names will solve the problem.

History

#1 Updated by Vladimir Podstavkov 3 months ago

  • Estimated time set to 4.00 h
  • % Done changed from 0 to 100
  • Status changed from New to Resolved

#2 Updated by Yuyi Guo 3 months ago

Hi Vladimir:

I got below error while running the API. Could you take a look?
Yuyi

d=poms_client.get_campaign_stage_name(experiment, 1843, test=test, role=role)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/nashome/y/yuyi/project-py/poms/poms_client/python/poms_client.py", line 236, in get_campaign_stage_name
return json.loads(data)
File "/cvmfs/larsoft.opensciencegrid.org/products/python/v2_7_15a/Linux64bit+2.6-2.12/lib/python2.7/json/__init__.py", line 339, in loads
return _default_decoder.decode(s)
File "/cvmfs/larsoft.opensciencegrid.org/products/python/v2_7_15a/Linux64bit+2.6-2.12/lib/python2.7/json/decoder.py", line 364, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/cvmfs/larsoft.opensciencegrid.org/products/python/v2_7_15a/Linux64bit+2.6-2.12/lib/python2.7/json/decoder.py", line 382, in raw_decode
raise ValueError("No JSON object could be decoded")
ValueError: No JSON object could be decoded



Also available in: Atom PDF