joe-habel / YouTube-View-Bot

A rotating proxy solution to bot YouTube views
96 stars 82 forks source link

multicore when set to true fail silently on ubuntu 18 #1

Open naproach opened 5 years ago

naproach commented 5 years ago

Hi, The script works perfectly if multicoreis set to false. However, when multicoreis set to trueit fails silently. ### My machine settings:

processor       : 3
vendor_id       : GenuineIntel
cpu family      : 6
model           : 63
model name      : Intel(R) Xeon(R) CPU @ 2.30GHz
stepping        : 0
microcode       : 0x1
cpu MHz         : 2300.000
cache size      : 46080 KB
physical id     : 0
siblings        : 4
core id         : 1
cpu cores       : 2
apicid          : 3
initial apicid  : 3
fpu             : yes
fpu_exception   : yes
cpuid level     : 13
wp              : yes
flags           : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush mmx fxsr sse sse2 ss ht syscall nx pdpe1gb rdtscp lm constant_tsc rep_good nopl xtopology nonstop_tsc cpuid pni pclmulqdq ssse3 fma cx16 pcid sse4_1 sse4_2 x2apic movbe popcnt aes xsave avx f16c rdrand hypervisor lahf_lm abm invpcid_single pti ssbd ibrs ibpb stibp fsgsbase tsc_adjust bmi1 avx2 smep bmi2 erms invpcid xsaveopt arat arch_capabilities
bugs            : cpu_meltdown spectre_v1 spectre_v2 spec_store_bypass l1tf
bogomips        : 4600.00
clflush size    : 64
cache_alignment : 64
address sizes   : 46 bits physical, 48 bits virtual
power management:

I tried to add the following to the code:

            handler = pool.apply_async(search_and_click, args=[ua,sleep_time,search_string,proxy,proxies,sleep_after])
        handler.get()

It gave me the following error:

Traceback (most recent call last):
  File "/home/username/anaconda3/lib/python3.7/site-packages/fake_useragent/fake.py", line 136, in __getattr__
    return random.choice(self.data_browsers[browser])
KeyError: 'getstate'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "viewbot.py", line 113, in <module>
    handler.get()
  File "/home/username/anaconda3/lib/python3.7/multiprocessing/pool.py", line 683, in get
    raise self._value
  File "/home/username/anaconda3/lib/python3.7/multiprocessing/pool.py", line 457, in _handle_tasks
    put(task)
  File "/home/username/anaconda3/lib/python3.7/multiprocessing/connection.py", line 206, in send
    self._send_bytes(_ForkingPickler.dumps(obj))
  File "/home/username/anaconda3/lib/python3.7/multiprocessing/reduction.py", line 51, in dumps
    cls(buf, protocol).dump(obj)
  File "/home/username/anaconda3/lib/python3.7/site-packages/fake_useragent/fake.py", line 139, in __getattr__
    raise FakeUserAgentError('Error occurred during getting browser')  # noqa
fake_useragent.errors.FakeUserAgentError: Error occurred during getting browser
naproach commented 5 years ago

New update: I've tested the script on windows machine same problem. Ram for first machine 24GB for the second: 16GB