nneonneo / 2048-ai

AI for the 2048 game
MIT License
1.09k stars 279 forks source link

connection refused #67

Open itnygr2 opened 3 years ago

itnygr2 commented 3 years ago

os: ubuntu 18.04 python: 3.7 i only tested firefox, i checked twice to make sure i followed every instruction but the following error appeared:

py 2048.py -b firefox
Traceback (most recent call last):
  File "2048.py", line 154, in <module>
    exit(main(sys.argv[1:]))
  File "2048.py", line 125, in main
    ctrl = FirefoxDebuggerControl(args.port)
  File "/home/m/projects/boardgames/2048/2048-ai/ffctrl.py", line 45, in __init__
    self.sock.connect(('localhost', port))
ConnectionRefusedError: [Errno 111] Connection refused
nneonneo commented 3 years ago

I have just tested with Firefox 90 on macOS, and it still works. (I just pushed 5b892173be44f482e521fd028799a3a605b68404 to fix an unrelated issue with exception processing, but it would not have affected this issue).

The connection refused error suggests that Firefox remote debugging is not in fact enabled. Please double check that you have enabled all of the relevant about:config options, that you have quit Firefox, and that you have started it with the correct command-line parameter.

This screenshot shows my about:config with the correct configuration. Additionally, note that the browser address bar shows a "robot" that indicates that remote debugging has been enabled. If you do not see these options enabled in about:config, or if your browser does not show the robot, then you may not have set it up correctly.

Screen Shot 2021-07-22 at 5 02 57 PM