Skip to content
Snippets Groups Projects
Commit fc7c0645 authored by Glenn Glazer's avatar Glenn Glazer
Browse files

SL-321: add in resource files, more CLI handling fixes

parent 2bb42148
No related branches found
No related tags found
No related merge requests found
This directory only exists as a place for the summary.json file to exist when the unit tests are run on a Mac, where the file goes to a sibling directory of the scripts dir. In Linux and Windows, the JSON file goes into the same directory as the script.
See:
test_get_summary.py
update_manager.get_summary()
for more details
- coyot 201606.02
{"Type":"viewer","Version":"4.0.5.315117","Channel":"Second Life Release"}
#!/usr/bin/env python
"""\
@file InstallerError.py
@author coyot
@date 2016-05-16
@brief custom exception class for VMP
$LicenseInfo:firstyear=2016&license=viewerlgpl$
Second Life Viewer Source Code
Copyright (C) 2016, Linden Research, Inc.
This library is free software; you can redistribute it and/or
modify it under the terms of the GNU Lesser General Public
License as published by the Free Software Foundation;
version 2.1 of the License only.
This library is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
License along with this library; if not, write to the Free Software
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
Linden Research, Inc., 945 Battery Street, San Francisco, CA 94111 USA
$/LicenseInfo$
"""
"""
usage:
>>> import InstallerError
>>> import os
>>> try:
... os.mkdir('/tmp')
... except OSError, oe:
... ie = InstallerError.InstallerError(oe, "foo")
... raise ie
Traceback (most recent call last):
File "<stdin>", line 5, in <module>
InstallerError.InstallerError: [Errno [Errno 17] File exists: '/tmp'] foo
"""
class InstallerError(OSError):
def __init___(self, message):
Exception.__init__(self, message)
......@@ -106,11 +106,12 @@ def capture_vmp_args(arg_list = None, cmd_line = None):
no_dashes = vmp_params[param]
count = cmd_line[no_dashes]['count']
param_args = []
if count:
for argh in range(1,count):
if count > 0:
for argh in range(0,count):
param_args.append(vmp_queue.popleft())
#the parameter name is the key, the (possibly empty) list of args is the value
cli_overrides[vmp_params[param]] = param_args
print "cli override param %s vmp_param %s args %s count %s" % (param, vmp_params[param], param_args, count)
#to prevent KeyErrors on missing keys, set the remainder to None
for key in vmp_params:
......
indra/viewer_components/manager/icons/SL_Logo.gif

1.29 KiB

indra/viewer_components/manager/icons/SL_Logo.png

1.45 KiB

indra/viewer_components/manager/icons/head-sl-logo.gif

960 B

indra/viewer_components/manager/icons/head-sl-logo.png

2.26 KiB

......@@ -252,8 +252,15 @@ def query_vvm(log_file_handle = None, platform_key = None, settings = None, summ
#normal case, no testing key
test_ok = 'testok'
UUID = make_VVM_UUID_hash(platform_key)
print repr(channelname)
print repr(version)
print repr(platform_key)
print repr(platform_version)
print repr(test_ok)
print repr(UUID)
#because urljoin can't be arsed to take multiple elements
query_string = '/v1.0/' + channelname + '/' + version + '/' + platform_key + '/' + platform_version + '/' + test_ok + '/' + UUID
#channelname is a list because although it can only be one word, it is a kind of argument and viewer args can take multiple keywords.
query_string = '/v1.0/' + channelname[0] + '/' + version + '/' + platform_key + '/' + platform_version + '/' + test_ok + '/' + UUID
VVMService = llrest.SimpleRESTService(name='VVM', baseurl=base_URI)
try:
result_data = VVMService.get(query_string)
......@@ -351,7 +358,7 @@ def update_manager(cli_overrides = None):
parent_dir = get_parent_path(platform_key)
log_file_handle = get_log_file_handle(parent_dir)
settings = None
print "parent dir: " + str(parent_dir)
print "cli_overrides: " + str(cli_overrides)
#check to see if user has install rights
#get the owner of the install and the current user
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment