File tree Expand file tree Collapse file tree 3 files changed +12
-4
lines changed
Expand file tree Collapse file tree 3 files changed +12
-4
lines changed Original file line number Diff line number Diff line change 3737- Fixed a bug where ``supervisorctl fg`` would swallow most XML-RPC faults.
3838 ``fg`` now prints the fault and exits.
3939
40+ - Parsing the config file will now fail with an error message if a process
41+ or group name contains a forward slash character (``/``) since it would
42+ break the URLs used by the web interface.
43+
40443.3.1 (2016-08-02)
4145------------------
4246
Original file line number Diff line number Diff line change 1212
1313def process_or_group_name (name ):
1414 """Ensures that a process or group name is not created with
15- characters that break the eventlistener protocol"""
15+ characters that break the eventlistener protocol or web UI URLs """
1616 s = str (name ).strip ()
17- if ' ' in s or ':' in s :
17+ if ' ' in s or ':' in s or '/' in s :
1818 raise ValueError ("Invalid name: " + repr (name ))
1919 return s
2020
Original file line number Diff line number Diff line change @@ -19,14 +19,18 @@ def test_strips_surrounding_whitespace(self):
1919 name = " foo\t "
2020 self .assertEqual (self ._callFUT (name ), "foo" )
2121
22- def test_disallows_inner_spaces (self ):
22+ def test_disallows_inner_spaces_for_eventlister_protocol (self ):
2323 name = "foo bar"
2424 self .assertRaises (ValueError , self ._callFUT , name )
2525
26- def test_disallows_colons (self ):
26+ def test_disallows_colons_for_eventlistener_protocol (self ):
2727 name = "foo:bar"
2828 self .assertRaises (ValueError , self ._callFUT , name )
2929
30+ def test_disallows_slashes_for_web_ui_urls (self ):
31+ name = "foo/bar"
32+ self .assertRaises (ValueError , self ._callFUT , name )
33+
3034class IntegerTests (unittest .TestCase ):
3135 def _callFUT (self , arg ):
3236 return datatypes .integer (arg )
You can’t perform that action at this time.
0 commit comments