You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
46 lines
971 B
Python
46 lines
971 B
Python
# import urllib.request
|
|
# from datetime import datetime
|
|
# import time
|
|
# import mmap
|
|
# import os
|
|
# print(os.getpid())
|
|
# print(os.getpgid(os.getpid()))
|
|
|
|
|
|
|
|
# with open("./data", "r+b") as f:
|
|
# mm = mmap.mmap(f.fileno(), 0)
|
|
# time.sleep(1000000)
|
|
# # lis = []
|
|
# # while True:
|
|
# # lis.clear()
|
|
# # for _ in range(1024 * 1024 * 400):
|
|
# # if len(lis) < 1024 * 1024 * 50:
|
|
# # lis.append(_)
|
|
# # print("Ok")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# import time
|
|
# from datetime import datetime
|
|
# import urllib.request
|
|
|
|
# while True:
|
|
# time.sleep(1)
|
|
# now = datetime.now().strftime("%Y-%m-%d %H:%M:%S")
|
|
# print(now)
|
|
# try:
|
|
# request = urllib.request.Request("http://www.baidu.com")
|
|
# with urllib.request.urlopen(request) as response:
|
|
# data = response.read()
|
|
# content = data.decode("utf-8")
|
|
# print(f"{len(content)}")
|
|
# except Exception as e:
|
|
# print(e)
|
|
|
|
|