Skip to content

Commit

Permalink
Properly escape backslashes in Python strings (#634)
Browse files Browse the repository at this point in the history
  • Loading branch information
daboehme authored Jan 16, 2025
1 parent 98fd2f2 commit 1bfdfb2
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion test/ci_app_tests/test_json.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def test_jsontree(self):

target_cmd = [ './ci_test_macros' ]
query_cmd = [ '../../src/tools/cali-query/cali-query',
'-q', 'SELECT count(),sum(time.inclusive.duration.ns),loop,iteration#main\ loop group by loop,iteration#main\ loop format json-split' ]
'-q', 'SELECT count(),sum(time.inclusive.duration.ns),loop,iteration#main\\ loop group by loop,iteration#main\\ loop format json-split' ]

caliper_config = {
'CALI_CONFIG_PROFILE' : 'serial-trace',
Expand Down
2 changes: 1 addition & 1 deletion test/ci_app_tests/test_loopreport.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ def test_loopreport_target_loop_selection(self):
""" Loop statistics option """
def test_loop_stats(self):
target_cmd = [ './ci_test_macros', '10', 'spot,loop.stats,output=stdout' ]
query_cmd = [ '../../src/tools/cali-query/cali-query', '-q', 'let r=leaf() select * where r=main\ loop format json' ]
query_cmd = [ '../../src/tools/cali-query/cali-query', '-q', 'let r=leaf() select * where r=main\\ loop format json' ]

obj = json.loads( cat.run_test_with_query(target_cmd, query_cmd, None) )

Expand Down
2 changes: 1 addition & 1 deletion test/ci_app_tests/test_monitor.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def test_loopmonitor_iter_interval(self):
caliper_config = {
'CALI_SERVICES_ENABLE' : 'loop_monitor,trace,report',
'CALI_LOOP_MONITOR_ITERATION_INTERVAL' : '5',
'CALI_REPORT_CONFIG' : 'select * where iteration#main\ loop format expand',
'CALI_REPORT_CONFIG' : 'select * where iteration#main\\ loop format expand',
'CALI_REPORT_FILENAME' : 'stdout',
'CALI_LOG_VERBOSITY' : '0'
}
Expand Down
4 changes: 2 additions & 2 deletions test/ci_app_tests/test_report.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def test_report_nested_key(self):

caliper_config = {
'CALI_SERVICES_ENABLE' : 'event,trace,report',
'CALI_REPORT_CONFIG' : 'select *,count() group by path,iteration#main\ loop format expand',
'CALI_REPORT_CONFIG' : 'select *,count() group by path,iteration#main\\ loop format expand',
'CALI_LOG_VERBOSITY' : '0'
}

Expand Down Expand Up @@ -97,7 +97,7 @@ def test_report_aggregation_aliases(self):

caliper_config = {
'CALI_SERVICES_ENABLE' : 'event,trace,report',
'CALI_REPORT_CONFIG' : 'select *,count() as my\\ count\\ alias group by path,iteration#main\ loop format expand',
'CALI_REPORT_CONFIG' : 'select *,count() as my\\ count\\ alias group by path,iteration#main\\ loop format expand',
'CALI_LOG_VERBOSITY' : '0'
}

Expand Down
2 changes: 1 addition & 1 deletion test/ci_app_tests/test_textlog.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ def test_textlog_with_end_event(self):

caliper_config = {
'CALI_SERVICES_ENABLE' : 'event,textlog',
'CALI_TEXTLOG_TRIGGER' : 'iteration#main\ loop',
'CALI_TEXTLOG_TRIGGER' : 'iteration#main\\ loop',
'CALI_TEXTLOG_FORMATSTRING' : '%region% iteration: %[2]iteration#main loop%',
'CALI_LOG_VERBOSITY' : '0',
}
Expand Down

0 comments on commit 1bfdfb2

Please sign in to comment.