Project

General

Profile

Bug #7400

--environment not dealt with properly (but -e is)

Added by Philip Rodrigues over 5 years ago. Updated about 5 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
-
Target version:
Start date:
12/02/2014
Due date:
% Done:

0%

Estimated time:
First Occurred:
Occurs In:
Stakeholders:
Duration:

Description

Something is up with the way that --environment is handled. I think it's not being expanded on the client side, but the server's trying to do it. Examples:

"""
$ FOO=BAR jobsub_submit --environment=FOO file://helloworld.sh

RESPONSE ERROR:
you used -e FOO , but $FOO must be set first for this to work!
"""

And for a variable that is certainly set on the server:

"""
$ echo $LD_LIBRARY_PATH
/grid/fermiapp/products/common/db/../prd/jobsub_tools/v1_2p_p1/Linux-2/lib/:/grid/fermiapp/products/common/db/../prd/ifdhc/v1_3_2/Linux64bit-2-6-2-12/lib:/grid/fermiapp/products/minerva/prd/dcap/v2_32_f0408/Linux-2-4/lib:/grid/fermiapp/minerva/software_releases/v10r8p1/lcg/external/ROOT/5.34.05/x86_64-slc6-gcc44-opt/lib:/usr/lib64:/minerva/app/users/rodriges/sw-sl6/lib:

$ jobsub_submit --environment=LD_LIBRARY_PATH file://helloworld.sh
[... then do jobsub_fetchlog ...]

$ grep LD_LIBRARY_PATH *.cmd

helloworld.sh_20141202_124844_28224_0_1.cmd:environment = LD_LIBRARY_PATH=/fnal/ups/prd/jobsub_tools/v1_3_5/Linux-2/lib/
"""

History

#1 Updated by Kenneth Herner over 5 years ago

Hi Phil,

Try exporting your variable. It should work then.

Ken

#2 Updated by Parag Mhashilkar over 5 years ago

  • Assignee set to Dennis Box
  • Target version set to v1.1

#3 Updated by Dennis Box over 5 years ago

  • Status changed from New to Assigned

#4 Updated by Dennis Box over 5 years ago

  • Status changed from Assigned to Feedback
  • Assignee changed from Dennis Box to Parag Mhashilkar

#5 Updated by Parag Mhashilkar over 5 years ago

  • Assignee changed from Parag Mhashilkar to Dennis Box

Following will throw exception if there are two or more '=' (example: --environment=FOO=BAR) specified by mistake. We should handle the error condition gracefully

        if argv[i].find('=')>0:
            arg,val=argv[i].split('=')

Make the changes to handle this condition and merge it to master

#6 Updated by Philip Rodrigues over 5 years ago

I get the same error when I export the variable FOO

#7 Updated by Dennis Box over 5 years ago

  • Status changed from Feedback to Resolved

use case export FOO='BAR=BAZ' ; jobsub_submit --expermiment=FOO ... handled now. Merged into master

#8 Updated by Parag Mhashilkar about 5 years ago

  • Target version changed from v1.1 to v1.0.5

#9 Updated by Parag Mhashilkar about 5 years ago

  • Status changed from Resolved to Closed


Also available in: Atom PDF