-
Notifications
You must be signed in to change notification settings - Fork 14
add script for models repo stable #36
Conversation
| print('kpi:%s' % kpi_name) | ||
| if self.analysis_result[kpi_name]['change_rate'] > self.diff_thre: | ||
| suc = False | ||
| print("kpi: %s change_tate too bigger !!!!!!!!!!" % kpi_name) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what is tate?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
change_rate~~
| suc = False | ||
| print("kpi: %s change_tate too bigger !!!!!!!!!!" % kpi_name) | ||
| else: | ||
| print('kpi:%s' % kpi_name) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
: 后面留空格
|
|
||
| def RunCmd(cmd, shellformat=True): | ||
| """run local cmd""" | ||
| p = subprocess.Popen(cmd, shell=shellformat, close_fds=True, stdin=subprocess.PIPE, \ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use native XONSH
| if args.task_dir: | ||
| tasks = args.task_dir.split() | ||
| return tasks | ||
| ret, out, err = RunCmd('''cd tasks; git diff HEAD^ HEAD | grep "diff --git" | awk -F' ' {'print $4'}''') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
用 XONSH,不需要再增加一种执行cmd的方法
熟悉XONSH http://xon.sh/
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ok~ thank you
| tasks = get_changed_tasks(args) | ||
| times = args.times | ||
| for task in tasks: | ||
| try: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里直接挂了退出就可以了,不需要用try
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
这里等所有模型都跑完,输出所有错误模型再通知,似乎更好一些?~
resolve #28