mirror of
https://github.com/ail-project/ail-framework.git
synced 2024-11-10 08:38:28 +00:00
cleanup, add FIXME
This commit is contained in:
parent
63b29176c1
commit
277d138a5d
2 changed files with 10 additions and 12 deletions
|
@ -84,11 +84,12 @@ if __name__ == "__main__":
|
|||
time.sleep(10)
|
||||
continue
|
||||
|
||||
# FIXME do it in the paste class
|
||||
lines_infos = PST.get_lines_info()
|
||||
|
||||
PST.save_attribute_redis("p_nb_lines", lines_infos[0])
|
||||
PST.save_attribute_redis("p_max_length_line", lines_infos[1])
|
||||
|
||||
# FIXME Not used.
|
||||
PST.store.sadd("Pastes_Objects", PST.p_path)
|
||||
if lines_infos[1] >= args.max:
|
||||
h.pub_channel = channel_0
|
||||
|
|
|
@ -62,17 +62,14 @@ if __name__ == "__main__":
|
|||
time.sleep(10)
|
||||
continue
|
||||
|
||||
encoding = PST._get_p_encoding()
|
||||
language = PST._get_p_language()
|
||||
|
||||
PST.save_attribute_redis("p_encoding", encoding)
|
||||
PST.save_attribute_redis("p_language", language)
|
||||
|
||||
PST.store.sadd("Pastes_Objects", PST.p_path)
|
||||
|
||||
# FIXME do it directly in the class
|
||||
PST.save_attribute_redis("p_encoding", PST._get_p_encoding())
|
||||
PST.save_attribute_redis("p_language", PST._get_p_language())
|
||||
# FIXME why not all saving everything there.
|
||||
PST.save_all_attributes_redis()
|
||||
# FIXME Not used.
|
||||
PST.store.sadd("Pastes_Objects", PST.p_path)
|
||||
except IOError:
|
||||
print "CRC Checksum Failed on :", PST.p_path
|
||||
publisher.error('{0};{1};{2};{3};{4}'.format(
|
||||
"Duplicate", PST.p_source, PST.p_date, PST.p_name,
|
||||
"CRC Checksum Failed"))
|
||||
publisher.error('Duplicate;{};{};{};CRC Checksum Failed'.format(
|
||||
PST.p_source, PST.p_date, PST.p_name))
|
||||
|
|
Loading…
Reference in a new issue