mirror of
https://github.com/StuffAnThings/qbit_manage.git
synced 2025-09-16 18:14:31 +08:00
minor bug fix
This commit is contained in:
parent
e1c458dafe
commit
90f836205b
3 changed files with 6 additions and 4 deletions
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
3.0.0
|
||||
3.0.1
|
|
@ -129,7 +129,9 @@ class Config:
|
|||
if isinstance(tag_details,str):
|
||||
tags['new_tag'] = self.util.check_for_attribute(self.data, tag_url, parent="tags",default=default_tag)
|
||||
self.util.check_for_attribute(self.data, "tag", parent="tags",subparent=tag_url, default=tags['new_tag'],do_print=False)
|
||||
if tags['new_tag'] == default_tag: self.data['tags'][tag_url]['tag'] = default_tag
|
||||
if tags['new_tag'] == default_tag:
|
||||
if self.data["tags"][tag_url] is None: self.data["tags"][tag_url] = {}
|
||||
self.data['tags'][tag_url]['tag'] = default_tag
|
||||
# Using Format 2
|
||||
else:
|
||||
tags['new_tag'] = self.util.check_for_attribute(self.data, "tag", parent="tags", subparent=tag_url, default=tag_url)
|
||||
|
@ -141,6 +143,7 @@ class Config:
|
|||
if tags['url']:
|
||||
default_tag = tags['url'].split('/')[2].split(':')[0]
|
||||
tags['new_tag'] = self.util.check_for_attribute(self.data, "tag", parent="tags",subparent=default_tag, default=default_tag)
|
||||
if self.data["tags"][default_tag] is None: self.data["tags"][default_tag] = {}
|
||||
self.data['tags'][default_tag]['tag'] = default_tag
|
||||
logger.warning(f'No tags matched for {tags["url"]}. Please check your config.yml file. Setting tag to {default_tag}')
|
||||
return (tags)
|
||||
|
|
|
@ -101,7 +101,7 @@ logger.setLevel(log_lev)
|
|||
|
||||
def fmt_filter(record):
|
||||
record.levelname = f"[{record.levelname}]"
|
||||
#record.filename = f"[{record.filename}:{record.lineno}]"
|
||||
record.filename = f"[{record.filename}:{record.lineno}]"
|
||||
return True
|
||||
|
||||
cmd_handler = logging.StreamHandler()
|
||||
|
@ -215,7 +215,6 @@ def start():
|
|||
|
||||
end_time = datetime.now()
|
||||
run_time = str(end_time - start_time).split('.')[0]
|
||||
#util.separator(f"Finished {start_type}Run\n {', '.join(stats_summary) if len(stats_summary)>0 else ''} \nRun Time: {run_time}")
|
||||
util.separator(f"Finished {start_type}Run\n {os.linesep.join(stats_summary) if len(stats_summary)>0 else ''} \nRun Time: {run_time}")
|
||||
|
||||
def end():
|
||||
|
|
Loading…
Add table
Reference in a new issue