Bläddra i källkod

Reduce wait between queries from 2s to 1s

tags/v0.4
Ben Kurtovic 3 år sedan
förälder
incheckning
a8a605fe05
2 ändrade filer med 4 tillägg och 4 borttagningar
  1. +2
    -2
      earwigbot/wiki/site.py
  2. +2
    -2
      earwigbot/wiki/sitesdb.py

+ 2
- 2
earwigbot/wiki/site.py Visa fil

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright (C) 2009-2019 Ben Kurtovic <ben.kurtovic@gmail.com>
# Copyright (C) 2009-2021 Ben Kurtovic <ben.kurtovic@gmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
@@ -91,7 +91,7 @@ class Site(object):
article_path=None, script_path=None, sql=None,
namespaces=None, login=(None, None), oauth=None,
cookiejar=None, user_agent=None, use_https=True,
assert_edit=None, maxlag=None, wait_between_queries=2,
assert_edit=None, maxlag=None, wait_between_queries=1,
logger=None, search_config=None):
"""Constructor for new Site instances.



+ 2
- 2
earwigbot/wiki/sitesdb.py Visa fil

@@ -1,6 +1,6 @@
# -*- coding: utf-8 -*-
#
# Copyright (C) 2009-2019 Ben Kurtovic <ben.kurtovic@gmail.com>
# Copyright (C) 2009-2021 Ben Kurtovic <ben.kurtovic@gmail.com>
#
# Permission is hereby granted, free of charge, to any person obtaining a copy
# of this software and associated documentation files (the "Software"), to deal
@@ -192,7 +192,7 @@ class SitesDB(object):
use_https = config.wiki.get("useHTTPS", True)
assert_edit = config.wiki.get("assert")
maxlag = config.wiki.get("maxlag")
wait_between_queries = config.wiki.get("waitTime", 2)
wait_between_queries = config.wiki.get("waitTime", 1)
logger = self._logger.getChild(name)
search_config = config.wiki.get("search", OrderedDict()).copy()



Laddar…
Avbryt
Spara