Skip to content

Commit 48d0ddf

Browse files
Merge pull request #1006 from linsword13/cleanup
Change the user-agent name to ramblebot
2 parents 97bfa2f + 75f29a4 commit 48d0ddf

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lib/ramble/ramble/util/web.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,21 +23,21 @@
2323
import llnl.util.lang
2424
from llnl.util.filesystem import mkdirp, rename
2525

26+
import ramble
2627
import ramble.config
2728
from ramble.util.logger import logger
2829

2930
import spack
3031
import spack.error
3132
import spack.url
32-
import spack.util.crypto
3333
import spack.util.gcs as gcs_util
3434
import spack.util.s3 as s3_util
3535
import spack.util.url as url_util
3636
from spack.util.compression import ALLOWED_ARCHIVE_TYPES
3737
from spack.util.path import convert_to_posix_path
3838

3939
#: User-Agent used in Request objects
40-
SPACK_USER_AGENT = f"Spackbot/{spack.spack_version}"
40+
RAMBLE_USER_AGENT = f"Ramblebot/{ramble.ramble_version}"
4141

4242

4343
# Also, HTMLParseError is deprecated and never raised.
@@ -113,7 +113,7 @@ def read_from_url(url, accept_content_type=None):
113113
url = url_util.format(url)
114114
if sys.platform == "win32" and url_scheme == "file":
115115
url = convert_to_posix_path(url)
116-
req = Request(url, headers={"User-Agent": SPACK_USER_AGENT})
116+
req = Request(url, headers={"User-Agent": RAMBLE_USER_AGENT})
117117

118118
content_type = None
119119
is_web_url = url_scheme in ("http", "https")

0 commit comments

Comments
 (0)