File tree Expand file tree Collapse file tree 2 files changed +7
-6
lines changed
kernel_gateway/notebook_http Expand file tree Collapse file tree 2 files changed +7
-6
lines changed Original file line number Diff line number Diff line change 44
55import re
66import sys
7+ from traitlets import Unicode
78from traitlets .config .configurable import LoggingConfigurable
89
910def first_path_param_index (endpoint ):
@@ -63,8 +64,8 @@ class APICellParser(LoggingConfigurable):
6364 api_response_indicator : str
6465 Regex pattern for API response metadata annotations
6566 """
66- api_indicator = r'{}\s+(GET|PUT|POST|DELETE)\s+(\/.*)+'
67- api_response_indicator = r'{}\s+ResponseInfo\s+(GET|PUT|POST|DELETE)\s+(\/.*)+'
67+ api_indicator = Unicode ( default_value = r'{}\s+(GET|PUT|POST|DELETE)\s+(\/.*)+' )
68+ api_response_indicator = Unicode ( default_value = r'{}\s+ResponseInfo\s+(GET|PUT|POST|DELETE)\s+(\/.*)+' )
6869
6970 def __init__ (self , comment_prefix , * args , ** kwargs ):
7071 super (APICellParser , self ).__init__ (* args , ** kwargs )
Original file line number Diff line number Diff line change 55import json
66import re
77from kernel_gateway .notebook_http .cell .parser import first_path_param_index , APICellParser
8- from traitlets import default
8+ from traitlets import List , Unicode
99from traitlets .config .configurable import LoggingConfigurable
1010
1111def _swaggerlet_from_markdown (cell_source ):
@@ -62,9 +62,9 @@ class SwaggerCellParser(LoggingConfigurable):
6262 operation_response_indicator : str
6363 Regex pattern for API response metadata annotations
6464 """
65- operation_indicator = r'{}\s*operationId:\s*(.*)'
66- operation_response_indicator = r'{}\s*ResponseInfo\s+operationId:\s*(.*)'
67- notebook_cells = []
65+ operation_indicator = Unicode ( default_value = r'{}\s*operationId:\s*(.*)' )
66+ operation_response_indicator = Unicode ( default_value = r'{}\s*ResponseInfo\s+operationId:\s*(.*)' )
67+ notebook_cells = List ()
6868
6969 def __init__ (self , comment_prefix , * args , ** kwargs ):
7070 super (SwaggerCellParser , self ).__init__ (* args , ** kwargs )
You can’t perform that action at this time.
0 commit comments