No available wheel for Python 3.8

Steps to reproduce
Using Python 3.8: pip install sqreen or pip install py-mini-racer
Expected behavior
Successful installation
Actual behavior

Full output
Running setup.py install for py-mini-racer ... - \ | / - \ | / - \ | / - error
    ERROR: Command errored out with exit status 1:
     command: /home/circleci/project/venv/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py'"'"'; __file__='"'"'/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-dn0y2bzo/install-record.txt --single-version-externally-managed --compile --install-headers /home/circleci/project/venv/include/site/python3.8/py-mini-racer
         cwd: /tmp/pip-install-5zbtunzs/py-mini-racer/
    Complete output (221 lines):
    running install
    running build
    running build_py
    creating build
    creating build/lib.linux-x86_64-3.8
    creating build/lib.linux-x86_64-3.8/py_mini_racer
    copying py_mini_racer/py_mini_racer.py -> build/lib.linux-x86_64-3.8/py_mini_racer
    copying py_mini_racer/__init__.py -> build/lib.linux-x86_64-3.8/py_mini_racer
    creating build/lib.linux-x86_64-3.8/py_mini_racer/extension
    copying py_mini_racer/extension/__init__.py -> build/lib.linux-x86_64-3.8/py_mini_racer/extension
    copying py_mini_racer/extension/v8_build.py -> build/lib.linux-x86_64-3.8/py_mini_racer/extension
    running egg_info
    writing py_mini_racer.egg-info/PKG-INFO
    writing dependency_links to py_mini_racer.egg-info/dependency_links.txt
    writing top-level names to py_mini_racer.egg-info/top_level.txt
    reading manifest file 'py_mini_racer.egg-info/SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    warning: no previously-included files matching '__pycache__' found under directory '*'
    warning: no previously-included files matching '*.py[co]' found under directory '*'
    writing manifest file 'py_mini_racer.egg-info/SOURCES.txt'
    copying py_mini_racer/extension/mini_racer_extension.cc -> build/lib.linux-x86_64-3.8/py_mini_racer/extension
    running build_ext
    running build_v8
    cloning depot tools submodule
    Initialized empty Git repository in /tmp/pip-install-5zbtunzs/py-mini-racer/.git/
    Cloning into 'vendor/depot_tools'...
    building v8
    DEBUG:py_mini_racer.extension.v8_build:Calling: 'fetch v8' from working directory /tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8
    WARNING: Your metrics.cfg file was invalid or nonexistent. A new one will be created.
    1>________ running 'git -c core.deltaBaseCacheLimit=2g clone --no-checkout --progress https://chromium.googlesource.com/v8/v8.git /tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8/_gclient_v8_HvIQh_' in '/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8'
    1>Cloning into '/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8/_gclient_v8_HvIQh_'...
    1>remote: Sending approximately 583.46 MiB ...
    1>remote: Counting objects: 1
    1>remote: Counting objects: 7759, done
    1>remote: Finding sources:   1% (1/99)
    1>remote: Finding sources:   2% (2/99)
    1>remote: Finding sources:   3% (3/99)
    1>remote: Finding sources:   4% (4/99)
    1>remote: Finding sources:   5% (5/99)
    1>remote: Finding sources:   6% (6/99)
    1>remote: Finding sources:   7% (7/99)
    1>remote: Finding sources:   8% (8/99)
    1>remote: Finding sources:   9% (9/99)
    1>remote: Finding sources:  10% (10/99)
    1>remote: Finding sources:  11% (11/99)
    1>remote: Finding sources:  12% (12/99)
    1>remote: Finding sources:  13% (13/99)
    1>remote: Finding sources:  14% (14/99)
    1>remote: Finding sources:  15% (15/99)
    1>remote: Finding sources:  16% (16/99)
    1>remote: Finding sources:  17% (17/99)
    1>remote: Finding sources:  18% (18/99)
    1>remote: Finding sources:  19% (19/99)
    1>remote: Finding sources:  20% (20/99)
    1>remote: Finding sources:  21% (21/99)
    1>remote: Finding sources:  22% (22/99)
    1>remote: Finding sources:  23% (23/99)
    1>remote: Finding sources:  24% (24/99)
    1>remote: Finding sources:  25% (25/99)
    1>remote: Finding sources:  26% (26/99)
    1>remote: Finding sources:  27% (27/99)
    1>remote: Finding sources:  28% (28/99)
    1>remote: Finding sources:  29% (29/99)
    1>remote: Finding sources:  30% (30/99)
    1>remote: Finding sources:  31% (31/99)
    1>remote: Finding sources:  32% (32/99)
    1>remote: Finding sources:  33% (33/99)
    1>remote: Finding sources:  34% (34/99)
    1>remote: Finding sources:  35% (35/99)
    1>remote: Finding sources:  36% (36/99)
    1>remote: Finding sources:  37% (37/99)
    1>remote: Finding sources:  38% (38/99)
    1>remote: Finding sources:  39% (39/99)
    1>remote: Finding sources:  40% (40/99)
    1>remote: Finding sources:  41% (41/99)
    1>remote: Finding sources:  42% (42/99)
    1>remote: Finding sources:  43% (43/99)
    1>remote: Finding sources:  44% (44/99)
    1>remote: Finding sources:  45% (45/99)
    1>remote: Finding sources:  46% (46/99)
    1>remote: Finding sources:  47% (47/99)
    1>remote: Finding sources:  48% (48/99)
    1>remote: Finding sources:  49% (49/99)
    1>remote: Finding sources:  50% (50/99)
    1>remote: Finding sources:  51% (51/99)
    1>remote: Finding sources:  52% (52/99)
    1>remote: Finding sources:  53% (53/99)
    1>remote: Finding sources:  54% (54/99)
    1>remote: Finding sources:  55% (55/99)
    1>remote: Finding sources:  56% (56/99)
    1>remote: Finding sources:  57% (57/99)
    1>remote: Finding sources:  58% (58/99)
    1>remote: Finding sources:  59% (59/99)
    1>remote: Finding sources:  60% (60/99)
    1>remote: Finding sources:  61% (61/99)
    1>remote: Finding sources:  62% (62/99)
    1>remote: Finding sources:  63% (63/99)
    1>remote: Finding sources:  64% (64/99)
    1>remote: Finding sources:  65% (65/99)
    1>remote: Finding sources:  66% (66/99)
    1>remote: Finding sources:  67% (67/99)
    1>remote: Finding sources:  68% (68/99)
    1>remote: Finding sources:  69% (69/99)
    1>remote: Finding sources:  70% (70/99)
    1>remote: Finding sources:  71% (71/99)
    1>remote: Finding sources:  72% (72/99)
    1>remote: Finding sources:  73% (73/99)
    1>remote: Finding sources:  74% (74/99)
    1>remote: Finding sources:  75% (75/99)
    1>remote: Finding sources:  76% (76/99)
    1>remote: Finding sources:  77% (77/99)
    1>remote: Finding sources:  78% (78/99)
    1>remote: Finding sources:  79% (79/99)
    1>remote: Finding sources:  80% (80/99)
    1>remote: Finding sources:  81% (81/99)
    1>remote: Finding sources:  82% (82/99)
    1>remote: Finding sources:  83% (83/99)
    1>remote: Finding sources:  84% (84/99)
    1>remote: Finding sources:  85% (85/99)
    1>remote: Finding sources:  86% (86/99)
    1>remote: Finding sources:  87% (87/99)
    1>remote: Finding sources:  88% (88/99)
    1>remote: Finding sources:  89% (89/99)
    1>remote: Finding sources:  90% (90/99)
    1>remote: Finding sources:  91% (91/99)
    1>remote: Finding sources:  92% (92/99)
    1>remote: Finding sources:  93% (93/99)
    1>remote: Finding sources:  94% (94/99)
    1>remote: Finding sources:  95% (95/99)
    1>remote: Finding sources:  96% (96/99)
    1>remote: Finding sources:  97% (97/99)
    1>remote: Finding sources:  98% (98/99)
    1>remote: Finding sources: 100% (99/99)
    1>remote: Finding sources: 100% (99/99)
    1>Receiving objects:   0% (1/710106)
    1>Receiving objects:   1% (7102/710106)
    1>Receiving objects:   2% (14203/710106)
    1>Receiving objects:   3% (21304/710106)
    1>Receiving objects:   4% (28405/710106), 10.63 MiB | 21.26 MiB/s
    1>Receiving objects:   5% (35506/710106), 10.63 MiB | 21.26 MiB/s
    1>Receiving objects:   6% (42607/710106), 10.63 MiB | 21.26 MiB/s
    1>Receiving objects:   7% (49708/710106), 10.63 MiB | 21.26 MiB/s
    1>Receiving objects:   7% (50384/710106), 10.63 MiB | 21.26 MiB/s
    1>Receiving objects:   8% (56809/710106), 21.87 MiB | 21.86 MiB/s
    1>Receiving objects:   9% (63910/710106), 21.87 MiB | 21.86 MiB/s
    1>Receiving objects:  10% (71011/710106), 21.87 MiB | 21.86 MiB/s
    1>Receiving objects:  11% (78112/710106), 21.87 MiB | 21.86 MiB/s
    1>Receiving objects:  12% (85213/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  13% (92314/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  14% (99415/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  15% (106516/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  16% (113617/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  17% (120719/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  17% (122224/710106), 34.10 MiB | 22.73 MiB/s
    1>Receiving objects:  18% (127820/710106), 59.17 MiB | 29.58 MiB/s
    1>Receiving objects:  19% (134921/710106), 59.17 MiB | 29.58 MiB/s
    1>Receiving objects:  20% (142022/710106), 59.17 MiB | 29.58 MiB/s
    1>Receiving objects:  21% (149123/710106), 59.17 MiB | 29.58 MiB/s
    1>Receiving objects:  22% (156224/710106), 59.17 MiB | 29.58 MiB/s
    1>Receiving objects:  23% (163325/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  24% (170426/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  25% (177527/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  26% (184628/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  27% (191729/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  28% (198830/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  29% (205931/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  30% (213032/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  31% (220133/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  32% (227234/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  33% (234335/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  34% (241437/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  35% (248538/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  36% (255639/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  37% (262740/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  38% (269841/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  39% (276942/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  40% (284043/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  41% (291144/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  42% (298245/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  43% (305346/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  44% (312447/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  45% (319548/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  46% (326649/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  47% (333750/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  48% (340851/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  49% (347952/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  50% (355053/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  51% (362155/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  52% (369256/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  53% (376357/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  53% (380670/710106), 85.47 MiB | 34.19 MiB/s
    1>Receiving objects:  54% (383458/710106), 114.43 MiB | 38.14 MiB/s
    1>Receiving objects:  55% (390559/710106), 129.13 MiB | 36.89 MiB/s
    1>Receiving objects:  55% (397058/710106), 129.13 MiB | 36.89 MiB/s
    1>Receiving objects:  56% (397660/710106), 142.87 MiB | 35.71 MiB/s
    1>Receiving objects:  57% (404761/710106), 159.08 MiB | 35.35 MiB/s
    1>Receiving objects:  57% (407194/710106), 159.08 MiB | 35.35 MiB/s
    1>Receiving objects:  58% (411862/710106), 193.16 MiB | 38.06 MiB/s
    1>Receiving objects:  58% (418371/710106), 193.16 MiB | 38.06 MiB/s
    1>Receiving objects:  59% (418963/710106), 212.34 MiB | 39.61 MiB/s
    1>Receiving objects:  60% (426064/710106), 230.30 MiB | 38.03 MiB/s
    1>Receiving objects:  60% (430814/710106), 230.30 MiB | 38.03 MiB/s
    1>Receiving objects:  61% (433165/710106), 247.34 MiB | 35.97 MiB/s
    1>Receiving objects:  62% (440266/710106), 267.01 MiB | 33.91 MiB/s
    1>Receiving objects:  62% (442318/710106), 267.01 MiB | 33.91 MiB/s
    1>Receiving objects:  63% (447367/710106), 304.61 MiB | 35.94 MiB/s
    1>Receiving objects:  63% (451728/710106), 304.61 MiB | 35.94 MiB/s
    1>Receiving objects:  64% (454468/710106), 322.93 MiB | 36.41 MiB/s
    1>Receiving objects:  64% (460291/710106), 340.28 MiB | 36.39 MiB/s
    1>Receiving objects:  65% (461569/710106), 358.19 MiB | 36.67 MiB/s
    1>Receiving objects:  65% (466976/710106), 370.67 MiB | 35.19 MiB/s
    1>Receiving objects:  66% (468670/710106), 389.31 MiB | 35.34 MiB/s
    1>Receiving objects:  67% (475772/710106), 407.29 MiB | 35.55 MiB/s
    1>Receiving objects:  67% (476988/710106), 407.29 MiB | 35.55 MiB/s
    1>Receiving objects:  68% (482873/710106), 442.55 MiB | 34.62 MiB/s
    1>Receiving objects:  68% (487668/710106), 442.55 MiB | 34.62 MiB/s
    1>Receiving objects:  69% (489974/710106), 470.71 MiB | 32.85 MiB/s
    1>Receiving objects:  69% (492983/710106), 470.71 MiB | 32.85 MiB/s
    1>Receiving objects:  70% (497075/710106), 497.42 MiB | 30.95 MiB/s
    1>Receiving objects:  70% (497678/710106), 497.42 MiB | 30.95 MiB/s
    1>Receiving objects:  71% (504176/710106), 524.59 MiB | 30.06 MiB/s
    1>Receiving objects:  71% (505123/710106), 524.59 MiB | 30.06 MiB/s
    1>Receiving objects:  72% (511277/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  73% (518378/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  74% (525479/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  75% (532580/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  76% (539681/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  77% (546782/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  78% (553883/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  79% (560984/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  80% (568085/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  81% (575186/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  82% (582287/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  83% (589388/710106), 537.31 MiB | 28.89 MiB/s
    1>Receiving objects:  84% (596490/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  85% (603591/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  86% (610692/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  87% (617793/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  88% (624894/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  89% (631995/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  90% (639096/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  91% (646197/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  92% (653298/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  93% (660399/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  94% (667500/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  95% (674601/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  96% (681702/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  96% (682160/710106), 556.99 MiB | 29.34 MiB/s
    1>Receiving objects:  97% (688803/710106), 578.55 MiB | 30.22 MiB/s
    1>Receiving objects:  98% (695904/710106), 578.55 MiB | 30.22 MiB/s
    1>Receiving objects:  99% (703005/710106), 578.55 MiB | 30.22 MiB/s
    1>remote: Total 710106 (delta 588549), reused 710077 (delta 588549)
    1>Receiving objects: 100% (710106/710106), 578.55 MiB | 30.22 MiB/s
    1>Receiving objects: 100% (710106/710106), 583.66 MiB | 34.10 MiB/s, done.
    1>Resolving deltas:   0% (0/588549)
    1>Resolving deltas:   1% (5900/588549)
    1>Resolving deltas:   2% (11837/588549)
    1>Resolving deltas:   3% (17661/588549)
    1>Resolving deltas:   4% (23550/588549)
    1>Resolving deltas:   5% (29431/588549)
    1>Resolving deltas:   6% (35314/588549)
    1>Resolving deltas:   7% (41204/588549)
    1>Resolving deltas:   8% (47100/588549)
    1>Resolving deltas:   8% (48522/588549)
    1>Resolving deltas:   9% (56575/588549)
    1>Resolving deltas:  10% (58980/588549)
    1>Resolving deltas:  11% (64755/588549)
    1>Resolving deltas:  12% (70630/588549)
    1>Resolving deltas:  13% (76513/588549)
    1>Resolving deltas:  14% (82476/588549)
    1>Resolving deltas:  15% (88416/588549)
    1>Resolving deltas:  16% (94247/588549)
    1>Resolving deltas:  16% (98705/588549)
    1>Resolving deltas:  17% (100191/588549)
    1>Resolving deltas:  18% (106007/588549)
    1>Resolving deltas:  19% (111936/588549)
    1>Resolving deltas:  20% (117725/588549)
    1>Resolving deltas:  21% (125564/588549)
    1>Resolving deltas:  22% (129511/588549)
    1>Resolving deltas:  23% (137702/588549)
    1>Resolving deltas:  24% (142904/588549)
    1>Resolving deltas:  25% (148167/588549)
    1>Resolving deltas:  26% (153130/588549)
    1>Resolving deltas:  26% (153937/588549)
    1>Resolving deltas:  27% (160171/588549)
    1>Resolving deltas:  28% (165131/588549)
    1>Resolving deltas:  29% (170866/588549)
    1>Resolving deltas:  30% (177951/588549)
    1>Resolving deltas:  31% (182562/588549)
    1>Resolving deltas:  32% (188746/588549)
    1>Resolving deltas:  33% (194225/588549)
    1>Resolving deltas:  34% (200151/588549)
    1>Resolving deltas:  35% (206106/588549)
    1>Resolving deltas:  36% (212122/588549)
    1>Resolving deltas:  37% (217961/588549)
    1>Resolving deltas:  38% (223755/588549)
    1>Resolving deltas:  39% (229705/588549)
    1>Resolving deltas:  40% (235549/588549)
    1>Resolving deltas:  41% (241815/588549)
    1>Resolving deltas:  42% (247944/588549)
    1>Resolving deltas:  43% (253112/588549)
    1>Resolving deltas:  44% (259376/588549)
    1>Resolving deltas:  45% (265130/588549)
    1>Resolving deltas:  45% (269926/588549)
    1>Resolving deltas:  46% (270930/588549)
    1>Resolving deltas:  47% (276764/588549)
    1>Resolving deltas:  48% (282749/588549)
    1>Resolving deltas:  49% (291121/588549)
    1>Resolving deltas:  50% (294290/588549)
    1>Resolving deltas:  50% (298230/588549)
    1>Resolving deltas:  51% (300241/588549)
    1>Resolving deltas:  51% (305948/588549)
    1>Resolving deltas:  52% (306151/588549)
    1>Resolving deltas:  53% (311953/588549)
    1>Resolving deltas:  53% (315774/588549)
    1>Resolving deltas:  54% (317819/588549)
    1>Resolving deltas:  55% (325016/588549)
    1>Resolving deltas:  56% (331261/588549)
    1>Resolving deltas:  56% (333823/588549)
    1>Resolving deltas:  57% (335513/588549)
    1>Resolving deltas:  58% (341426/588549)
    1>Resolving deltas:  58% (345378/588549)
    1>Resolving deltas:  59% (347280/588549)
    1>Resolving deltas:  60% (353130/588549)
    1>Resolving deltas:  60% (358804/588549)
    1>Resolving deltas:  61% (359017/588549)
    1>Resolving deltas:  62% (364901/588549)
    1>Resolving deltas:  63% (370821/588549)
    1>Resolving deltas:  63% (375832/588549)
    1>Resolving deltas:  64% (376764/588549)
    1>Resolving deltas:  65% (386942/588549)
    1>Resolving deltas:  66% (388470/588549)
    1>Resolving deltas:  66% (389171/588549)
    1>Resolving deltas:  67% (394331/588549)
    1>Resolving deltas:  67% (395809/588549)
    1>Resolving deltas:  68% (400216/588549)
    1>Resolving deltas:  68% (404303/588549)
    1>Resolving deltas:  69% (406107/588549)
    1>Resolving deltas:  70% (411988/588549)
    1>Resolving deltas:  70% (414667/588549)
    1>Resolving deltas:  71% (417876/588549)
    1>Resolving deltas:  72% (423781/588549)
    1>Resolving deltas:  72% (425093/588549)
    1>Resolving deltas:  73% (429644/588549)
    1>Resolving deltas:  73% (432888/588549)
    1>Resolving deltas:  74% (435550/588549)
    1>Resolving deltas:  75% (441419/588549)
    1>Resolving deltas:  75% (445779/588549)
    1>Resolving deltas:  76% (447331/588549)
    1>Resolving deltas:  77% (453696/588549)
    1>Resolving deltas:  77% (456601/588549)
    1>Resolving deltas:  78% (459192/588549)
    1>Resolving deltas:  79% (464980/588549)
    1>Resolving deltas:  80% (470841/588549)
    1>Resolving deltas:  80% (475022/588549)
    1>Resolving deltas:  81% (476745/588549)
    1>Resolving deltas:  82% (482611/588549)
    1>Resolving deltas:  82% (487074/588549)
    1>Resolving deltas:  83% (489124/588549)
    1>Resolving deltas:  84% (494460/588549)
    1>Resolving deltas:  84% (495097/588549)
    1>Resolving deltas:  85% (500293/588549)
    1>Resolving deltas:  85% (503697/588549)
    1>Resolving deltas:  86% (506172/588549)
    1>Resolving deltas:  86% (511256/588549)
    1>Resolving deltas:  87% (512219/588549)
    1>Resolving deltas:  87% (516587/588549)
    1>Resolving deltas:  88% (518551/588549)
    1>Resolving deltas:  88% (522761/588549)
    1>Resolving deltas:  89% (523998/588549)
    1>Resolving deltas:  89% (529352/588549)
    1>Resolving deltas:  90% (529704/588549)
    1>Resolving deltas:  90% (533460/588549)
    1>Resolving deltas:  91% (536127/588549)
    1>Resolving deltas:  91% (537524/588549)
    1>Resolving deltas:  91% (539567/588549)
    1>Resolving deltas:  92% (542106/588549)
    1>Resolving deltas:  92% (546714/588549)
    1>Resolving deltas:  93% (547386/588549)
    1>Resolving deltas:  94% (553335/588549)
    1>Resolving deltas:  94% (559068/588549)
    1>Resolving deltas:  95% (559941/588549)
    1>Resolving deltas:  96% (565223/588549)
    1>Resolving deltas:  97% (571913/588549)
    1>Resolving deltas:  97% (574566/588549)
    1>Resolving deltas:  98% (578572/588549)
    1>Resolving deltas:  99% (582947/588549)
    1>Resolving deltas:  99% (587459/588549)
    1>Resolving deltas: 100% (588549/588549)
    1>Resolving deltas: 100% (588549/588549), done.
    [0:01:37] Still working on:
    [0:01:37]   v8

    ________ running 'cipd ensure -log-level error -root /tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8 -ensure-file /tmp/tmpAi_jXx.ensure' in '.'
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    ________ running 'vpython v8/third_party/depot_tools/update_depot_tools_toggle.py --disable' in '/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8'
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    ________ running 'vpython v8/build/landmines.py --landmine-scripts v8/tools/get_landmines.py' in '/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8'
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    ________ running 'download_from_google_storage --no_resume --platform=linux* --no_auth --bucket chromium-clang-format -s v8/buildtools/linux64/clang-format.sha1' in '/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8'
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    Failed to fetch file gs://chromium-clang-format/942fc8b1789144b8071d3fc03ff0fcbe1cf81ac8 for v8/buildtools/linux64/clang-format. [Err: bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    [E2019-10-16T14:41:15.528075Z 6914 0 annotate.go:241] original error: no such package
    [E2019-10-16T14:41:15.528099Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528107Z 6914 0 annotate.go:241] goroutine 113:
    [E2019-10-16T14:41:15.528119Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/cipd/client/cipd/client.go:1683 - cipd.humanErr()
    [E2019-10-16T14:41:15.528126Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/cipd/client/cipd/client.go:740 - cipd.(*clientImpl).ResolveVersion()
    [E2019-10-16T14:41:15.528133Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/cipd/client/cipd/resolver.go:176 - cipd.(*Resolver).resolveVersion.func1()
    [E2019-10-16T14:41:15.528142Z 6914 0 annotate.go:241] #3 go.chromium.org/luci/common/sync/promise/promise.go:84 - promise.(*Promise).runGen()
    [E2019-10-16T14:41:15.528148Z 6914 0 annotate.go:241] #4 runtime/asm_amd64.s:1337 - runtime.goexit()
    [E2019-10-16T14:41:15.528158Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528164Z 6914 0 annotate.go:241] goroutine 16:
    [E2019-10-16T14:41:15.528170Z 6914 0 annotate.go:241] From frame 0 to 0, the following wrappers were found:
    [E2019-10-16T14:41:15.528176Z 6914 0 annotate.go:241]   internal reason: MultiError 2/2: following first non-nil error.
    [E2019-10-16T14:41:15.528182Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528186Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/cipd/client/cipd/ensure/file.go:255 - ensure.(*File).Resolve.func1.1()
    [E2019-10-16T14:41:15.528192Z 6914 0 annotate.go:241]   reason: failed to resolve infra/python/wheels/cffi/linux-amd64_cp32_abi3@version:1.10.0 (line 0)
    [E2019-10-16T14:41:15.528201Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528207Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/common/sync/parallel/runner.go:51 - parallel.(*WorkItem).execute()
    [E2019-10-16T14:41:15.528213Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/common/sync/parallel/runner.go:145 - parallel.(*Runner).dispatchLoopBody.func1()
    [E2019-10-16T14:41:15.528219Z 6914 0 annotate.go:241] #3 runtime/asm_amd64.s:1337 - runtime.goexit()
    [E2019-10-16T14:41:15.528225Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528231Z 6914 0 annotate.go:241] goroutine 1:
    [E2019-10-16T14:41:15.528237Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/vpython/venv/config.go:183 - venv.(*Config).makeEnv()
    [E2019-10-16T14:41:15.528245Z 6914 0 annotate.go:241]   reason: failed to resolve packages
    [E2019-10-16T14:41:15.528251Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528257Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/vpython/venv/venv.go:163 - venv.With()
    [E2019-10-16T14:41:15.528264Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/vpython/run.go:62 - vpython.Run()
    [E2019-10-16T14:41:15.528271Z 6914 0 annotate.go:241] #3 go.chromium.org/luci/vpython/application/application.go:312 - application.(*application).mainImpl()
    [E2019-10-16T14:41:15.528276Z 6914 0 annotate.go:241] #4 go.chromium.org/luci/vpython/application/application.go:397 - application.(*Config).Main.func1()
    [E2019-10-16T14:41:15.528283Z 6914 0 annotate.go:241] #5 go.chromium.org/luci/vpython/application/support.go:46 - application.run()
    [E2019-10-16T14:41:15.528288Z 6914 0 annotate.go:241] #6 go.chromium.org/luci/vpython/application/application.go:396 - application.(*Config).Main()
    [E2019-10-16T14:41:15.528295Z 6914 0 annotate.go:241] #7 vpython/main.go:105 - main.mainImpl()
    [E2019-10-16T14:41:15.528303Z 6914 0 annotate.go:241] #8 vpython/main.go:111 - main.main()
    [E2019-10-16T14:41:15.528309Z 6914 0 annotate.go:241] #9 runtime/proc.go:200 - runtime.main()
    [E2019-10-16T14:41:15.528316Z 6914 0 annotate.go:241] #10 runtime/asm_amd64.s:1337 - runtime.goexit()
    ]
    0> Failed to fetch file gs://chromium-clang-format/942fc8b1789144b8071d3fc03ff0fcbe1cf81ac8 for v8/buildtools/linux64/clang-format, skipping. [Err: bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    bash: warning: setlocale: LC_ALL: cannot change locale (en_US.UTF-8)
    [E2019-10-16T14:41:15.528075Z 6914 0 annotate.go:241] original error: no such package
    [E2019-10-16T14:41:15.528099Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528107Z 6914 0 annotate.go:241] goroutine 113:
    [E2019-10-16T14:41:15.528119Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/cipd/client/cipd/client.go:1683 - cipd.humanErr()
    [E2019-10-16T14:41:15.528126Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/cipd/client/cipd/client.go:740 - cipd.(*clientImpl).ResolveVersion()
    [E2019-10-16T14:41:15.528133Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/cipd/client/cipd/resolver.go:176 - cipd.(*Resolver).resolveVersion.func1()
    [E2019-10-16T14:41:15.528142Z 6914 0 annotate.go:241] #3 go.chromium.org/luci/common/sync/promise/promise.go:84 - promise.(*Promise).runGen()
    [E2019-10-16T14:41:15.528148Z 6914 0 annotate.go:241] #4 runtime/asm_amd64.s:1337 - runtime.goexit()
    [E2019-10-16T14:41:15.528158Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528164Z 6914 0 annotate.go:241] goroutine 16:
    [E2019-10-16T14:41:15.528170Z 6914 0 annotate.go:241] From frame 0 to 0, the following wrappers were found:
    [E2019-10-16T14:41:15.528176Z 6914 0 annotate.go:241]   internal reason: MultiError 2/2: following first non-nil error.
    [E2019-10-16T14:41:15.528182Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528186Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/cipd/client/cipd/ensure/file.go:255 - ensure.(*File).Resolve.func1.1()
    [E2019-10-16T14:41:15.528192Z 6914 0 annotate.go:241]   reason: failed to resolve infra/python/wheels/cffi/linux-amd64_cp32_abi3@version:1.10.0 (line 0)
    [E2019-10-16T14:41:15.528201Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528207Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/common/sync/parallel/runner.go:51 - parallel.(*WorkItem).execute()
    [E2019-10-16T14:41:15.528213Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/common/sync/parallel/runner.go:145 - parallel.(*Runner).dispatchLoopBody.func1()
    [E2019-10-16T14:41:15.528219Z 6914 0 annotate.go:241] #3 runtime/asm_amd64.s:1337 - runtime.goexit()
    [E2019-10-16T14:41:15.528225Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528231Z 6914 0 annotate.go:241] goroutine 1:
    [E2019-10-16T14:41:15.528237Z 6914 0 annotate.go:241] #0 go.chromium.org/luci/vpython/venv/config.go:183 - venv.(*Config).makeEnv()
    [E2019-10-16T14:41:15.528245Z 6914 0 annotate.go:241]   reason: failed to resolve packages
    [E2019-10-16T14:41:15.528251Z 6914 0 annotate.go:241]
    [E2019-10-16T14:41:15.528257Z 6914 0 annotate.go:241] #1 go.chromium.org/luci/vpython/venv/venv.go:163 - venv.With()
    [E2019-10-16T14:41:15.528264Z 6914 0 annotate.go:241] #2 go.chromium.org/luci/vpython/run.go:62 - vpython.Run()
    [E2019-10-16T14:41:15.528271Z 6914 0 annotate.go:241] #3 go.chromium.org/luci/vpython/application/application.go:312 - application.(*application).mainImpl()
    [E2019-10-16T14:41:15.528276Z 6914 0 annotate.go:241] #4 go.chromium.org/luci/vpython/application/application.go:397 - application.(*Config).Main.func1()
    [E2019-10-16T14:41:15.528283Z 6914 0 annotate.go:241] #5 go.chromium.org/luci/vpython/application/support.go:46 - application.run()
    [E2019-10-16T14:41:15.528288Z 6914 0 annotate.go:241] #6 go.chromium.org/luci/vpython/application/application.go:396 - application.(*Config).Main()
    [E2019-10-16T14:41:15.528295Z 6914 0 annotate.go:241] #7 vpython/main.go:105 - main.mainImpl()
    [E2019-10-16T14:41:15.528303Z 6914 0 annotate.go:241] #8 vpython/main.go:111 - main.main()
    [E2019-10-16T14:41:15.528309Z 6914 0 annotate.go:241] #9 runtime/proc.go:200 - runtime.main()
    [E2019-10-16T14:41:15.528316Z 6914 0 annotate.go:241] #10 runtime/asm_amd64.s:1337 - runtime.goexit()
    ]
    Downloading 1 files took 3.880252 second(s)
    Error: Command 'download_from_google_storage --no_resume --platform=linux* --no_auth --bucket chromium-clang-format -s v8/buildtools/linux64/clang-format.sha1' returned non-zero exit status 1 in /tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8
    Running: gclient root
    Running: gclient config --spec 'solutions = [
      {
        "url": "https://chromium.googlesource.com/v8/v8.git",
        "managed": False,
        "name": "v8",
        "deps_file": "DEPS",
        "custom_deps": {},
      },
    ]
    '
    Running: gclient sync --with_branch_heads
    Subprocess failed with return code 2.
    Traceback (most recent call last):
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 161, in build_extension
        self.run_command('build_v8')
      File "/usr/local/lib/python3.8/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/lib/python3.8/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 208, in run
        build_v8()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 179, in build_v8
        ensure_v8_src()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 63, in ensure_v8_src
        fetch_v8(path)
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 75, in fetch_v8
        call("fetch v8")
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 38, in call
        return subprocess.check_call(cmd, shell=True, env=current_env)
      File "/usr/local/lib/python3.8/subprocess.py", line 364, in check_call
        raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command 'fetch v8' returned non-zero exit status 2.
    Traceback (most recent call last):
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 161, in build_extension
        self.run_command('build_v8')
      File "/usr/local/lib/python3.8/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/lib/python3.8/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 208, in run
        build_v8()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 179, in build_v8
        ensure_v8_src()
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 63, in ensure_v8_src
        fetch_v8(path)
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 75, in fetch_v8
        call("fetch v8")
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/py_mini_racer/extension/v8_build.py", line 38, in call
        return subprocess.check_call(cmd, shell=True, env=current_env)
      File "/usr/local/lib/python3.8/subprocess.py", line 364, in check_call
        raise CalledProcessError(retcode, cmd)
    subprocess.CalledProcessError: Command 'fetch v8' returned non-zero exit status 2.

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 212, in <module>
        setup(
      File "/home/circleci/project/venv/lib/python3.8/site-packages/setuptools/__init__.py", line 145, in setup
        return distutils.core.setup(**attrs)
      File "/usr/local/lib/python3.8/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/usr/local/lib/python3.8/distutils/dist.py", line 966, in run_commands
        self.run_command(cmd)
      File "/usr/local/lib/python3.8/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/home/circleci/project/venv/lib/python3.8/site-packages/setuptools/command/install.py", line 61, in run
        return orig.install.run(self)
      File "/usr/local/lib/python3.8/distutils/command/install.py", line 545, in run
        self.run_command('build')
      File "/usr/local/lib/python3.8/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/lib/python3.8/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/usr/local/lib/python3.8/distutils/command/build.py", line 135, in run
        self.run_command(cmd_name)
      File "/usr/local/lib/python3.8/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/lib/python3.8/distutils/dist.py", line 985, in run_command
        cmd_obj.run()
      File "/home/circleci/project/venv/lib/python3.8/site-packages/setuptools/command/build_ext.py", line 84, in run
        _build_ext.run(self)
      File "/usr/local/lib/python3.8/distutils/command/build_ext.py", line 340, in run
        self.build_extensions()
      File "/usr/local/lib/python3.8/distutils/command/build_ext.py", line 449, in build_extensions
        self._build_extensions_serial()
      File "/usr/local/lib/python3.8/distutils/command/build_ext.py", line 474, in _build_extensions_serial
        self.build_extension(ext)
      File "/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py", line 180, in build_extension
        raise Exception(err_msg % repr(e))
    Exception: py_mini_racer failed to build, ensure you have an up-to-date pip (>= 8.1) to use the wheel instead
                To update pip: 'pip install -U pip'
                See also: https://github.com/sqreen/PyMiniRacer#binary-builds-availability

                Original error: CalledProcessError(2, 'fetch v8')
    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/circleci/project/venv/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py'"'"'; __file__='"'"'/tmp/pip-install-5zbtunzs/py-mini-racer/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-dn0y2bzo/install-record.txt --single-version-externally-managed --compile --install-headers /home/circleci/project/venv/include/site/python3.8/py-mini-racer Check the logs for full command output.
WARNING: You are using pip version 19.2.3, however version 19.3 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

System configuration
PyMiniRacer version: 0.1.18
Python version: 3.8.0

I'd add to this that the current version is incompatible with 3.8.0:
    import sqreen
  File "/usr/local/lib/python3.8/dist-packages/sqreen/__init__.py", line 10, in <module>
    from .runner_thread import start
  File "/usr/local/lib/python3.8/dist-packages/sqreen/runner_thread.py", line 36, in <module>
    from .remote_command import RemoteCommand
  File "/usr/local/lib/python3.8/dist-packages/sqreen/remote_command.py", line 17, in <module>
    from .rules_callbacks import cb_from_rule
  File "/usr/local/lib/python3.8/dist-packages/sqreen/rules_callbacks/__init__.py", line 42, in <module>
    from .reflected_xss import ReflectedXSSCB
  File "/usr/local/lib/python3.8/dist-packages/sqreen/rules_callbacks/reflected_xss.py", line 9, in <module>
    from cgi import escape
ImportError: cannot import name 'escape' from 'cgi' (/usr/lib/python3.8/cgi.py)

Hello Adam, thanks for reporting the issue. It should be fixed now as we pushed Python 3.8 wheels for Linux and MacOS on PYPI.


Encryption failing for cross-platform use.

I've created a sample project for testing. I encrypt a string with Obj-c and attempt to decrypt it on using Android. I'm able to Decrypt the string on iOS but not Android. Any help would be greatly appreciated...  Many thanks     I receive a 'bad padding exception'
Obj-C Code:
    NSString *plainText = @"this is my plain text";
    NSString *keyy = @"simplekey";
    NSString *iiv = @"1234123412341234";

    NSString *encryptedString = [[CryptLib alloc] encryptPlainText:plainText key:keyy iv:iiv];

same issue here.

Same issue

Same issue

Issue Happen only in iOS13

no, iOS 11 and 12 also


Apply REACTION_EMOJI to messages you're included in

Users should be able to "react" with the REACTION_EMOJI to messages they're included in but only recognize other users, not themselves. Ex:

:fistbump: Nice work this week alice bob working through your first Dojo. Great learning/coaching experiences with the team!

bob should be able to attach the REACTION_EMOJI to be able to send a fist bump to alice

Was completed along with group recognition.


Contributing and tools

📝 Update the Contributing documentation

Remove the outdated flit section
Mention pre-commit and how to use it
Describe how to set-up the development dependencies
Describe how to run tests

⬆ Bump ruff pre-commit hook
This also does a minor formatting diff on some files

🤖 Add mypy pre-commit hook
With this, it's not needed to install mypy directly, as pre-commit will do it in a separate virtual env

🌱 Run lint in a separate ci job
Before this commit, the linting was done in the test matrix (once per python version). This is not necessary, as the linting is the same for all versions.
Now, the linting is fully delegated to pre-commit, and executed as a separate job.
By doing this we delegate ruff completely to pre-commit, and so the linting script and the ruff requirement for testing is removed.

Hi @ivantodorovich, thanks for these contributions! To get this reviewed and merged more easily, I suggest to break this PR up into atomic bits, each representing one functionality change or improvement.

As most of these edits have gone out-of-date with the current master branch, I'll go ahead and close this one. Always happy to reconsider new PRs of course, and ideally let's stick to one atomic change per PR 🙏


Error in the old 1.12 version

I have to use the old 1.12 version because the new one requires Comfy >=2.0.0 which requires Rails >= 5.2, which I don't have time to upgrade to. I'm on Rails 5.0.2
I assumed the old version 1.12 of comfy blog would work with Comfy 1.12, but it doesn't
Expected behavior
When creating a new blog I should not get dumped into an error page
Actual behavior
  ArgumentError in Comfy::Admin::Blog::Blogs#new
 gems/comfy_blog-1.12.3/app/views/comfy/admin/blog/blogs/_form.html.haml where line #5 raised
wrong number of arguments (given 0, expected 1)
# List of available application layouts
  def self.app_layouts_for_select(view_paths)
    view_paths.map(&:to_s).select { |path| path.start_with?(Rails.root.to_s) }.flat_map do |full_path|
      Dir.glob("#{full_path}/layouts/**/*.html.*").collect do |filename|
        filename.gsub!("#{full_path}/layouts/", '')

Steps to reproduce

Install Comfy blog 1.12 in a working Comfy 1.12 system
Generate and run migrations
Go to the admin page and click on 'Blogs' in the left menu
Click the 'New Blog' button.
You get dumped into the error page

System configuration
Rails version:
5.0.2
CMS version:
1.12
Ruby version:
2.4.0

Yeah. It's possible that something got out of sync in 1.12. If you can fix the issue and make a PR I'll release 1.12.4. Thanks!

There's quite a lot of errors in this version. The test suite only finds the first 4 errors, all related to this issue. Was there a time when the test suite ran without errors?
Sample of one of the errors when running the suite
ActionView::Template::Error: wrong number of arguments (given 0, expected 1)
comfortable_mexican_sofa (1.12.11) app/models/comfy/cms/layout.rb:48:in `app_layouts_for_select'

Seems it's looking for something in the main comfy app but it's not there.
Line 5 in the admin/blog/blogs/_form.html.haml is the problem
 - if (options = Comfy::Cms::Layout.app_layouts_for_select).present?

I fixed this one by changing it to
 - if (options = Comfy::Cms::Layout.app_layouts_for_select(lookup_context.view_paths)).present?

That gets me past the admin problem. But then I have other issues.

the path to the blog has two forward slashes in it my-site//blog/etc

the path to blog at isn't relative to the site, so the browser sees it as a new host, which it can't find
e.g.
This is the first blog post

Note the //blog which makes the browser think it's a host not a relative path name
Both these errors are related to the // before the path to the blogs. But I can't see where that's coming from.
There must be a missing test or this error would not have crept in.

I'm going to take a look a bit later. Pretty sure // problem was fixed long time ago. Maybe only for 2.0 though.

OK thanks

I've just sent a PR to fix this problem. But not the //


Bug: The time interval of the special event (Christmas) was incorrectly checked, as a result of which the event was only available until 01.01 00:00:00

Fixed by ef842dd commit

Fixed by ef842dd commit


Fix DeepSpeed lr scheduler logic

What does this PR do?
Fixes https://github.com/PyTorchLightning/pytorch-lightning/issues/8520
Does your PR introduce any breaking changes ? If yes, please list them.
None
Before submitting

[x] Was this discussed/approved via a GitHub issue? (not for typos and docs)
[x] Did you read the contributor guideline, Pull Request section?
[x] Did you make sure your PR does only one thing, instead of bundling different changes together?
[x] Did you make sure to update the documentation with your changes? (if necessary)
[x] Did you write any new necessary tests? (not for typos and docs)
[x] Did you verify new and existing tests pass locally with your changes?
[x] Did you update the CHANGELOG? (not for typos, docs, test updates, or internal minor changes/refactorings)
[x] Did you list all the breaking changes introduced by this pull request?

PR review

[x] Is this pull request ready for review? (if not, please submit in draft mode)
[x] Check that all items from Before submitting are resolved
[x] Make sure the title is self-explanatory and the description concisely explains the PR
[x] Add labels and milestones (and optionally projects) to the PR so it can be classified

Thanks @carmocca!


#722: Add support for tls1.3

Coverage remained the same at 93.691% when pulling 85b52c678b91dd7021683bca1a93adfe163b1a91 on dair-targ:722-support-tls1.3 into 91961c6b51b8ae091d5f674d70ea6af3e8b44c42 on jakubroztocil:master.


ValueError: min() arg is an empty sequence

The following simple test:
import os
import pdftotree

filename = '/home/chhenning/data/2N6N-0117.pdf'
htmlpath = '/home/chhenning/temp'

pdftotree.parse(filename, htmlpath, model_path=None, favor_figures=False, visualize=True)

creates the following output:
Digitized PDF detected, building tree structure
float division by zero
float division by zero
float division by zero
(89.33853599999992, 89.33853599999992, 50)
Traceback (most recent call last):
  File "chh_test.py", line 10, in <module>
    pdftotree.parse(filename, htmlpath, model_path=None, favor_figures=False, visualize=True)
  File "/home/chhenning/repos/pdftotree/pdftotree/core.py", line 57, in parse
    pdf_tree = extractor.get_tree_structure(model, favor_figures)
  File "/home/chhenning/repos/pdftotree/pdftotree/TreeExtract.py", line 195, in get_tree_structure
    favor_figures)
  File "/home/chhenning/repos/pdftotree/pdftotree/pdf/pdf_parsers.py", line 615, in parse_tree_structure
    figures_page = get_figures(mentions, elems.layout.bbox, page_num, boxes_figures, page_width, page_height)
  File "/home/chhenning/repos/pdftotree/pdftotree/pdf/pdf_parsers.py", line 945, in get_figures
    page_stat = Node(boxes)
  File "/home/chhenning/repos/pdftotree/pdftotree/pdf/node.py", line 44, in __init__
    self.set_bbox(bound_elems(elems))
  File "/home/chhenning/repos/pdftotree/pdftotree/pdf/vector_utils.py", line 101, in bound_elems
    group_x0 = min(map(lambda l:l.x0,elems))
ValueError: min() arg is an empty sequence

Could you attach that file?

Can I send it to you via email?

Would prefer if you could attach to this issue to allow anyone to help debug.

Yeah, sorry I cannot find it online and so I would rather not share it. Anyways, here is another one that throws errors.
Summary of Benefits for BlueAdvantage HMO Plan on Pathway HMO Network.pdf

btw, most of the files I try run into errors. Maybe it has something to do with the pdf generators my client is using?

Great, thanks for that file. I'm seeing an IndexError there. As you can tell, pdftotree is still very much in development. We'll try to take a look at this soon.

@chhenning Sure, we are very happy to debug with your data. You can send email to<EMAIL_ADDRESS>

Here is the more complete traceback:
$ pdftotree -vv 2N6N-0117.pdf
[INFO] pdftotree.core - Digitized PDF detected, building tree structure...
[ERROR] pdftotree.TreeExtract - division by zero
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 148, in get_candidates_alignments
    nodes, features = parse_layout(elems, font_stat)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 39, in parse_layout
    char_width = get_char_width(boxes)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 1187, in get_char_width
    return box_len_sum / num_char_sum
ZeroDivisionError: division by zero
[ERROR] pdftotree.TreeExtract - division by zero
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 148, in get_candidates_alignments
    nodes, features = parse_layout(elems, font_stat)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 39, in parse_layout
    char_width = get_char_width(boxes)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 1187, in get_char_width
    return box_len_sum / num_char_sum
ZeroDivisionError: division by zero
[ERROR] pdftotree.TreeExtract - division by zero
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 148, in get_candidates_alignments
    nodes, features = parse_layout(elems, font_stat)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 39, in parse_layout
    char_width = get_char_width(boxes)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 1187, in get_char_width
    return box_len_sum / num_char_sum
ZeroDivisionError: division by zero
[ERROR] pdftotree.TreeExtract - (89.33853599999992, 89.33853599999992, 50)
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 148, in get_candidates_alignments
    nodes, features = parse_layout(elems, font_stat)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 56, in parse_layout
    boxes_segments, boxes_curves, boxes_figures, page_width, combine)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 67, in cluster_vertically_aligned_boxes
    plane.extend(boxes)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 341, in extend
    self.add(obj)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 346, in add
    for k in self._getrange((obj.x0, obj.y0, obj.x1, obj.y1)):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 334, in _getrange
    for x in drange(x0, x1, self.gridsize):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 171, in drange
    assert v0 < v1, str((v0, v1, d))
AssertionError: (89.33853599999992, 89.33853599999992, 50)
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/.venv/bin/pdftotree", line 6, in <module>
    exec(compile(open(__file__).read(), __file__, 'exec'))
  File "/home/lwhsiao/repos/pdftotree/bin/pdftotree", line 82, in <module>
    args.favor_figures, args.visualize)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/core.py", line 58, in parse
    pdf_tree = extractor.get_tree_structure(model, favor_figures)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 188, in get_tree_structure
    favor_figures)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 695, in parse_tree_structure
    boxes_figures, page_width, page_height)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 1108, in get_figures
    page_stat = Node(boxes)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/node.py", line 40, in __init__
    self.set_bbox(bound_elems(elems))
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/vector_utils.py", line 101, in bound_elems
    group_x0 = min(map(lambda l:l.x0,elems))
ValueError: min() arg is an empty sequence

After the latest push on bugfix, we just have the assertion errors here.
$ pdftotree 2N6N-0117.pdf -vv
[INFO] pdftotree.core - Digitized PDF detected, building tree structure...
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 1.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes were found to cluster.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 2.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes were found to cluster.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 3.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes were found to cluster.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 4.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 5.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 6.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 13.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 14.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 15.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 17.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 18.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 19.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 20.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 21.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 22.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 23.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 24.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 25.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 26.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 27.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 28.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 29.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 30.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 31.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 32.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 33.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 34.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 35.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 36.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 38.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 40.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 41.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 42.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 43.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 44.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 46.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 47.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 49.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 50.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 52.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 53.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 54.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 55.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 58.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 59.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 60.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 61.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 62.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 63.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 65.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 66.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 67.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 68.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 69.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 70.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 71.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 72.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 73.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 74.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 76.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 78.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 80.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 81.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 82.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 83.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 84.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 85.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 86.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 87.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 88.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 89.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 90.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 91.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 93.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 94.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 95.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 96.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 98.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 99.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 100.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 101.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 102.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 103.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 104.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 105.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 106.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 107.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 108.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 109.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 110.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 111.
[ERROR] pdftotree.TreeExtract - (89.33853599999992, 89.33853599999992, 50)
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 149, in get_candidates_alignments
    nodes, features = parse_layout(elems, font_stat)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 56, in parse_layout
    boxes_segments, boxes_curves, boxes_figures, page_width, combine)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 72, in cluster_vertically_aligned_boxes
    plane.extend(boxes)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 341, in extend
    self.add(obj)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 346, in add
    for k in self._getrange((obj.x0, obj.y0, obj.x1, obj.y1)):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 334, in _getrange
    for x in drange(x0, x1, self.gridsize):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 171, in drange
    assert v0 < v1, str((v0, v1, d))
AssertionError: (89.33853599999992, 89.33853599999992, 50)
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 113.
[INFO] pdftotree.utils.pdf.layout_utils - No boxes were found on page 114.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes to get figures from on page 2.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes to get figures from on page 3.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No text found. Defaulting to char_width = 2.0.
[WARNING] pdftotree.utils.pdf.pdf_parsers - No boxes to get figures from on page 4.
Traceback (most recent call last):
  File "/home/lwhsiao/repos/pdftotree/.venv/bin/pdftotree", line 6, in <module>
    exec(compile(open(__file__).read(), __file__, 'exec'))
  File "/home/lwhsiao/repos/pdftotree/bin/pdftotree", line 82, in <module>
    args.favor_figures, args.visualize)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/core.py", line 58, in parse
    pdf_tree = extractor.get_tree_structure(model, favor_figures)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/TreeExtract.py", line 189, in get_tree_structure
    favor_figures)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 697, in parse_tree_structure
    boxes_figures, page_width, page_height)
  File "/home/lwhsiao/repos/pdftotree/pdftotree/utils/pdf/pdf_parsers.py", line 1107, in get_figures
    plane.extend(boxes)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 341, in extend
    self.add(obj)
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 346, in add
    for k in self._getrange((obj.x0, obj.y0, obj.x1, obj.y1)):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 334, in _getrange
    for x in drange(x0, x1, self.gridsize):
  File "/home/lwhsiao/repos/pdftotree/.venv/lib/python3.5/site-packages/pdfminer/utils.py", line 171, in drange
    assert v0 < v1, str((v0, v1, d))
AssertionError: (89.33853599999992, 89.33853599999992, 50)


💄 Add custom font sizing for app name

Category

Cosmetic / Feature

Overview

Add the ability to change the font size for the app name when shown on the tile

Issue Number (if applicable)

Closes #1326

Screenshot

We all know my history on making changes for this x) Please help me test it.

Added maximum font size to 64, size is defined in pixels and although 64 can seem high, I'm not about to judge people that want to go that high.

@Meierschlumpf please rereview


PHP7 session pb - login in catalog

It seems a problem with sessions in php 7
Warning: session_regenerate_id(): Session callback expects true/false return value
Warning: session_regenerate_id(): Session object destruction failed. ID: user (path: /tmp/)
The rpoblem apear when you want to log in on catalog
line 127 :   session_regenerate_id(true);

@oitsuki is it a xamp specific problem? I can not reproduce on wamp.

No it's not on wamp but on ubuntu xenial
PHP Version 	7.0.4-7ubuntu2
Server configuration
Register Globals 	Off
Magic Quotes 	Off
Files upload 	On
Session auto start 	Off
Session use trans sid 	Off

Thanks for the report. This has been fixed already.


Unittesting

The Unittests which are currently available are the predefined ones. Should we invest time in Unittests in addition to e2e-tests?

Yes you are right, we should 👍 . We are using end-to-end tests, but these can not test certain situations 👍


tests: fix B015

B015 Pointless comparison. This comparison does nothing but wastes CPU instructions. Remove it.
This is a followup to #681; this time fixing a warning from one of my favorite flake8 extensions, bugbear. The warning (above) tells you to remove pointless comparisons, but 95% of the time, such as all the cases here, they tend to be missed asserts in PyTest.

Although technically the way these were caught was by "pointless comparisons," they're not pointless—they're attempts at assertions that failed to get the word "asset" (or somehow lost it). Similarly, before I added the rule that "the truth value of an array is ambiguous," there had been assertions that always returned true, even if the arrays on both sides of the == didn't match.  That's probably why NumPy introduced that rule.
This automated check has revealed two failing tests. Both contain a trivial thing to fix: the string representation of a floating point number has a trailing .0, but one of them also has a substantial error: ak.from_json(file) was recently modified to accept a sequence of JSON documents into an array. In this particular file, it has only one document and should be one level less nested than it is—the new rule about accepting a sequence of JSONs shouldn't make a single JSON into an item in an array.
This test from way back in the "0018" era would have caught this introduced error, but it was missing the word assert. It's a great automated check!
I'll fix this tomorrow when I get to my computer, unless @ianna gets to it first. (This is in the new multi-line JSON handling. If only one full JSON document is observed, it should not be considered the first in a series, but the entirety of that single document.)

Although technically the way these were caught was by "pointless comparisons," they're not pointless—they're attempts at assertions that failed to get the word "asset" (or somehow lost it). Similarly, before I added the rule that "the truth value of an array is ambiguous," there had been assertions that always returned true, even if the arrays on both sides of the == didn't match.  That's probably why NumPy introduced that rule.
This automated check has revealed two failing tests. Both contain a trivial thing to fix: the string representation of a floating point number has a trailing .0, but one of them also has a substantial error: ak.from_json(file) was recently modified to accept a sequence of JSON documents into an array. In this particular file, it has only one document and should be one level less nested than it is—the new rule about accepting a sequence of JSONs shouldn't make a single JSON into an item in an array.
This test from way back in the "0018" era would have caught this introduced error, but it was missing the word assert. It's a great automated check!
I'll fix this tomorrow when I get to my computer, unless @ianna gets to it first. (This is in the new multi-line JSON handling. If only one full JSON document is observed, it should not be considered the first in a series, but the entirety of that single document.)

I'm using my fork, so gh pr checkout 682 will check this out if you use the GitHub command line tool without any fuss. If put something in that I think others will be likely to edit, I try to use the main repo, generally, just to simplify collaboration. I didn't know this would actually catch a bug. :)

I'm using my fork, so gh pr checkout 682 will check this out if you use the GitHub command line tool without any fuss. If put something in that I think others will be likely to edit, I try to use the main repo, generally, just to simplify collaboration. I didn't know this would actually catch a bug. :)

I've actually had a discussion with the author of this check on special cases, by the way. There is a very rare, special case where you have to use a # noqa for it (no questions asked, didn't realize that at first): if you have a comparison that throws an error that you want to catch in your tests. But yes, it's fantastic and one of my favorites. :)

I've actually had a discussion with the author of this check on special cases, by the way. There is a very rare, special case where you have to use a # noqa for it (no questions asked, didn't realize that at first): if you have a comparison that throws an error that you want to catch in your tests. But yes, it's fantastic and one of my favorites. :)

I had been thinking that this was a bug introduced by PR #543, but I was wrong. It wasn't reading a single JSON document as though it were a JSONs stream, it was writing a single JSON document with one level too deep nesting.
I did some forensics on it: there was a time when the tojson_part was changed from assuming it was inside a beginlist()/endlist() pair to creating the beginlist()/endlist() pair if it's a list type. That means an update in two places: inside tojson_part and outside of it in the Content::tojson that calls it. (Here is what it looked like in olden times, just after these functions were introduced, and here is what it looked like right before I put in this fix. The builder.beginlist()/builder.endlist() was removed from the overload that creates a string to agree with the new definition within tojson_part, but it was not removed from the overload that writes to a file.)
When this change was put in, I must have been testing the string output because that's easy to write a test around. I would have been assuming that the file version was okay because there were tests of JSON input and output "since forever." So I was explicitly relying on the test that apparently didn't have the word assert before it.

I had been thinking that this was a bug introduced by PR #543, but I was wrong. It wasn't reading a single JSON document as though it were a JSONs stream, it was writing a single JSON document with one level too deep nesting.
I did some forensics on it: there was a time when the tojson_part was changed from assuming it was inside a beginlist()/endlist() pair to creating the beginlist()/endlist() pair if it's a list type. That means an update in two places: inside tojson_part and outside of it in the Content::tojson that calls it. (Here is what it looked like in olden times, just after these functions were introduced, and here is what it looked like right before I put in this fix. The builder.beginlist()/builder.endlist() was removed from the overload that creates a string to agree with the new definition within tojson_part, but it was not removed from the overload that writes to a file.)
When this change was put in, I must have been testing the string output because that's easy to write a test around. I would have been assuming that the file version was okay because there were tests of JSON input and output "since forever." So I was explicitly relying on the test that apparently didn't have the word assert before it.

It's green. :)

It's green. :)


Exact body match

Hi,
it seems that it doesn't do a exact body match,
i.e if body has a attribute and spec doesn't have it, it is true.
i think it is due to this
https://github.com/node-nock/nock/blob/master/lib/match_body.js#L60-L65
is this by design?

A workaround is to convert the object to a string with JSON.stringify, then the match must be exact, but you lose the ability of using a RegExp in attribute values.
nock(url).post('/foo', JSON.stringify({ your: 'object' }))

A quick note on @dhinus solution. It does work but you will need to also ensure that you put the properties in the correct order. The following will give different results:
JSON.stringify({a: 1, b: 2})
JSON.stringify({b: 2, a: 1})

@antonsamper true, I noticed that too after posting my comment. Thanks for adding a note about that.

syntax suggestions fro PR:
nock(domain)
        .post(path, data, **strict**)
        .reply(responseCode, responseData);

or
nock(domain)
        .post(path, data)
        .strict()
        .reply(responseCode, responseData);

WDYT?


CommitIt works

Yay

Hi @sandorfalot~
Not sure if these are meant to be submitted to here or in your own fork of the project?
Let me know a bit more about what you're trying to do and I'll advise.
Cheers!


[question] FGS223 Double Switch: Key held down and Key released

Hello,
I´m not sure if this is a Bug or just my misunderstanding.
I have this Fibaro FGS223 Double Switch 2 (https://devices.zwave-js.io/?jumpTo=0x010f:0x0203:0x1000:3.2)
The Parameters for this Device has 4 different Options:
S1 switch - Send Scenes: Key pressed 1 time
S1 switch - Send Scenes: Key pressed 2 times
S1 switch - Send Scenes: Key pressed 3 times
S1 switch - Send Scenes: Key held down and Key released
Regardless of what i do 1,2,3 or Hold MQTT Value from node14/37/1/currentValue changes from "value": false to "value": true and back.
am I missing somenthing?
I did a Rediscover of the whole node.
I´m running zwavejs2mqtt in a docker container on a rasp3:
zwavejs2mqtt: 3.2.1 zwave-js: 7.2.2 home id: 4031*  home hex:0xf0*

Could you try with version 3.3.0 ?

Same behavior on 3.3.0
Key held down -> True Realeasing -> back to False

Please attach logs file of both zwavejs and zwavejs2mqtt
/cc @AlCalzone

You're looking at the wrong value (Binary Switch). The parameter with "Scenes" in the name configure what gets sent with the Central Scene CC.

I´m fairly new to this whole zwaveJS2MQTT topic. I used the nativ zwave Integration from HA.
From The Logs: (If you need the whole one i would need to truncate it first it´s 170mb)
where is the zwavejs located?
S1 Key Held down for 3 Seconds (Lights switches on until i release the key)
2021-04-15 14:20:35.926 INFO ZWAVE: Node 14: value updated: 37-1-currentValue false => true
2021-04-15 14:20:35.937 INFO ZWAVE: Node 14: value added: 37-1-targetValue => undefined
2021-04-15 14:20:35.940 INFO ZWAVE: Node 14: value added 14-37-1-targetValue => undefined
2021-04-15 14:20:38.674 INFO ZWAVE: Node 14: value updated: 50-1-value-66049 0 => 26.5
2021-04-15 14:20:38.925 INFO ZWAVE: Node 14: value updated: 37-1-currentValue true => false
2021-04-15 14:20:39.686 INFO ZWAVE: Node 14: value updated: 50-1-value-66049 26.5 => 0

S2 Key Hold down for  3 Seconds (Lights switches on until i release the key)
2021-04-15 14:20:40.624 INFO ZWAVE: Node 14: value updated: 37-2-currentValue false => true
2021-04-15 14:20:40.630 INFO ZWAVE: Node 14: value added: 37-2-targetValue => undefined
2021-04-15 14:20:40.634 INFO ZWAVE: Node 14: value added 14-37-2-targetValue => undefined
2021-04-15 14:20:42.800 INFO ZWAVE: Node 14: value updated: 50-2-value-66049 0 => 26.6
2021-04-15 14:20:43.425 INFO ZWAVE: Node 14: value updated: 37-2-currentValue true => false
2021-04-15 14:20:43.809 INFO ZWAVE: Node 14: value updated: 50-2-value-66049 26.6 => 0

S1 Key pressed 3x (Lights switches on)
2021-04-15 14:20:46.494 INFO ZWAVE: Node 14: value updated: 37-1-currentValue false => true

S2 Key pressed 3x (Lights switches on)
2021-04-15 14:20:48.092 INFO ZWAVE: Node 14: value updated: 37-2-currentValue false => true

S1 + S2 Key pressed 1x (Lights switches off)
2021-04-15 14:20:48.762 INFO ZWAVE: Node 14: value updated: 37-2-currentValue true => false
2021-04-15 14:20:49.103 INFO ZWAVE: Node 14: value updated: 50-1-value-66049 0 => 26.5
2021-04-15 14:20:49.383 INFO ZWAVE: Node 14: value updated: 50-2-value-66049 0 => 0
2021-04-15 14:20:50.075 INFO ZWAVE: Node 14: value updated: 37-1-currentValue true => false

MQTT Topic node14/91/0/scene/001 or 002 has no changes.
I did observe the Messages in homeassistant/_EVENTS/ZWAVE_GATEWAY-zwavejs2mqtt-eg/node but there is also no values pointing on scenes.

Please post a whole logfile of zwave-js so I can figure out if the commands are even sent.
https://zwave-js.github.io/zwavejs2mqtt/#/troubleshooting/bug_report?id=export-logs -> point 1.

zwavejs2mqtt-store.zip
Node 14
I tested the Switch at 17:47

Looks like your test was happening while the driver was waiting for a callback from the stick that never came. Not sure if some of the dropped secure messages in the meantime contained the Central Scene messages. Can you try again?

zwavejs2mqtt-store (1).zip
Did stop the container removed the logfiles and restartet the container.
Tested around 19:45 in the logfiles

There aren't any Central Scene commands sent. Maybe you need to add Node 1 to one of the additional association groups. Can you try that?

I could try it but i don´t know how i have to do this :/

tl;dr - This switch does not need any associations of controller for scenes to work. Had the same issue on one of the switches, factory resetting helped.
Long story:
I've 3 such switches and had the very same issue. The scenes were being sent correctly on the one migrated with scenes from OZW, but did not work on the other one. Notifications where working, but scenes were not. After performing factory reset of the switch and re-configuring the switch to allow scenes (remember to check button type), finally the scenes were being send to the controller. It seems this might be an issue with your switch.
I was able to check with PC Controller app, and the switch itself was not sending scene events to the controller (even when configuration values were correctly set by the zwavejs). I don't know if this is related, but it finally started working when I've used '15' as value to enable scenes for the single click on given button (just for fun, logs indicated that correct bits are always set, and the switch itself did report correct value - 0x0F in my case for enabling all the scenes).

I did exclude -> Factory reset -> Include the module.
The Scences still don´t work.
Latest Logs
The switch is now Node_39
zwavejs2mqtt-store (2).zip

@Drynael did you configure the device again after factory reset? The log doesn't contain everything after the inclusion, so I can't tell.

I did a restart in between Inclusion and Test.
This is my current config:

node_39(JSON).zip

You didn't enable the scenes:

I have set them to 1. Which components do I have to reload/restart to take effect?

None. These are set on the device and should have an effect immediately once they are accepted.

I did some more testing.
Press and Hold and Press 2x does nothing. But when i hit it Once i get a Scene Value of 3. But Value 3 should be
    {
      "text": "KeyPressed2x",
      "value": 3
    },

Config:

Logs:
zwavejs2mqtt-store (4).zip

Take a look at the parameter 20 - Switch type. Only with 0 (monostable) all actions are send. With default value of 2, hold/release are not send. With value 1 neither hold/release nor the double click are being sent.
If you are getting double press on one click and no hold, this would be consistent with monostable button being interpreted as bistable - default value of parameter 20 being in use.

I have now played around with alle the parameters.
Paramater 20: 0 - momentary switch
Scenes are still configured as above
Central Scene slowRefresh can´t be switched off:

2021-04-19 17:29:29.221 INFO ZWAVE: Writing false to 39-91-0-slowRefresh
2021-04-19 17:29:29.231 ERROR ZWAVE: Error while writing false on 39-91-0-slowRefresh: This virtual node does not support the command ConfigurationSet!
2021-04-19 17:29:29.234 ERROR ZWAVE: Unable to write false on 39-91-0-slowRefresh
2021-04-19 17:29:29.236 INFO ZWAVE: Success zwave api call writeValue { success: true, message: 'Success zwave api call', result: undefined }

If i press and Hold i get first Scene 2 (and lights turn on) and by releasing scene 1 (lights turn off) Should be only Scene ID 8
If i press 2x i get Scene 3 (Lights toggle) Should only be Scene ID 2

Ok help me out here. What are you expecting to happen and what is actually happening? I'm seeing both Hold->Release and Pressed 2x notifications for scenes 1 and 2 in your latest log.

I´m expecting that if i hit the Button once my Lights turn on and Off.
and if I hit 2x or Hold it sends only the scene so i can use them to turn on/off other devices.
What i get is Regardless of what combination of key Presses is use. The lights turn on and off or do nothing at all.
For Example i try to Turn on Ambient Lights with PressAndHold. I get now the input KeyHold (and release). I can use the Scene information to Toggle the Ambient Lights. What irritates me is that the ceiling lights turns on when I activate one of the scenes. Maybe I am making the wrong assumption that the module can send scenes without switching.

@Drynael Unfortunately the switch will always toogle the output when pressing the button (1, 2, 3 presses and the hold), this is a limitation of this hardware (see: https://forum.fibaro.com/topic/26631-fgs-223-turn-on-associated-device-by-double-click/) . There is nothing you can do about it on this particular device type.
You could workaround it by automating that the load will be toggled after the scene is received on ZwaveJS/Mqtt/HA side - but due to delays, the change will still be visible to the operator.

Yup, that sounds like a hardware limitation.

Thank you all for figuring out all.
I can't find any switch with the capability to just send a scene and not triggering the lights.
I just use some regular Scene managers or Remotes.

Same here, I've moved crucial switches to Shelly 2.5 - with HA the delay between synchronizing zwave devices is negligible and it works like a charm with Tasmota and MQTT.


Set default verbosity to Trace

closes https://github.com/microsoft/testfx/issues/2134
cc: @Evangelink

@MarcoRossignoli it would be good if you could also submit a PR on docs website.


Program crashes when using InputManager

I have built and linked gainput.
As soon as I add line:
gainput::InputManager input;
I get no warnings/errors, but program crashed right after start. Even a minimal example crashed.
Any ideas would be appreciated!
EDIT: I am using msvc 2013 64 bit

Could you post a call stack and check if there is possibly anything interesting in the log output?

Hi! I wanted to give gainput another try and downloaded your recent version from github. Sorry I can't reproduce my issue from above. Instead I recompiled with cmake and visual studio 2013 x64 (Release. static) with no issues. Now when I init InputManager I get the following errors:
gainputstatic.lib(GainputInputDevicePad.obj):-1: error: LNK2019: Verweis auf nicht aufgelöstes externes Symbol "XInputGetState" in Funktion ""public: virtual void __cdecl gainput::InputDevicePadImplWin::Update(class gainput::InputDeltaState *)" (?Update@InputDevicePadImplWin@gainput@@UEAAXPEAVInputDeltaState@2@@Z)".
gainputstatic.lib(GainputInputDevicePad.obj):-1: error: LNK2019: Verweis auf nicht aufgelöstes externes Symbol "XInputSetState" in Funktion ""public: virtual bool __cdecl gainput::InputDevicePadImplWin::Vibrate(float,float)" (?Vibrate@InputDevicePadImplWin@gainput@@UEAA_NMM@Z)".
gainputstatic.lib(GainputInputRecording.obj):-1: error: LNK2019: Verweis auf nicht aufgelöstes externes Symbol "__imp_htonl" in Funktion ""public: unsigned __int64 __cdecl gainput::Stream::Write(unsigned int const &)" (??$Write@I@Stream@gainput@@QEAA_KAEBI@Z)".
gainputstatic.lib(GainputInputRecording.obj):-1: error: LNK2019: Verweis auf nicht aufgelöstes externes Symbol "__imp_ntohl" in Funktion ""public: unsigned __int64 __cdecl gainput::Stream::Read(unsigned int &)" (??$Read@I@Stream@gainput@@QEAA_KAEAI@Z)".
Is something missing in the library or am I missing something? Thank you in advance.

Well,

Please translate all error messages to English
First search all other issues; I had the same problem at some point and the issue is already resolved
You need to include xinput.lib and Ws2_32.lib

See Issue https://github.com/jkuhlmann/gainput/issues/6

Ok I installed DirectX SDK and linked xinput.lib and cut my errors in half:
gainputstatic.lib(GainputInputRecording.obj):-1: error: LNK2019: Reference to not found external symbol "__imp_htonl" in Funktion ""public: unsigned __int64 __cdecl gainput::Stream::Write(unsigned int const &)" (??$Write@I@Stream@gainput@@QEAA_KAEBI@Z)".
gainputstatic.lib(GainputInputRecording.obj):-1: error: LNK2019: Reference to not found external symbol "__imp_ntohl" in Funktion ""public: unsigned __int64 __cdecl gainput::Stream::Read(unsigned int &)" (??$Read@I@Stream@gainput@@QEAA_KAEAI@Z)".
I am compiling the program in 64bit. Linking to WS2_32.lib brought up tons of erros. I linked to this path: C:\Program Files (x86)\Microsoft SDKs\Windows\v7.1A\lib.
It seems to cause conflicts with other libraries I use...


Intellij IDEA-Ignore misc.xml file ?

I think that .idea/misc.xml should be ignored, but it is not in the generated gitignore file.

👍  I agree.  It seems like *.iml / *.ipr are also not ignored

@raj4dev This topic was discussed in a previous issue: #186 and there are a few things to consider.

The IntelliJ template is actually maintained by GitHub's official repository.  This proposal would be better off floated there.
If you read the Intellij's official documentation, also referenced in #186 it specifically states:

All the files under .idea directory in the project root except the workspace.xml and tasks.xml files which store user specific settings

@dotCipher the documentation also says

Share the project .ipr file and all the .iml module files, don't share the .iws file as it stores user specific settings

I can add them to the IntelliJ.patch file commented out. Each user would still be responsible for uncommented them on their own after creating a local .gitignore template.


Update links to Sony's flash-tool "Emma"

Because the old links have become broken by Sony.
Additionally soften the langauge, because Emma is not "required" to flash an Xperia phone, other flash tools exist, which also run under MacOS and Linux: XperiFirm, Flashtool by Androxyde, Newflasher.

Please not that the link for unlocking an Xperia's bootloader also was altered, it is now at https://developer.sony.com/open-source/aosp-on-xperia-open-devices/get-started/unlock-bootloader#jss-server-side
You might want to change this bootloader link (and maybe the one for "Emma", too) at other locations, e.g., https://jolla.com/sailfishxinstall/


api(ticdc): setup open api v2

What problem does this PR solve?

Issue Number: close #5584
What is changed and how it works?
setup open api v2 files
Check List
Tests

Unit test
Integration test

Release note
`None`.

Codecov Report

Merging #5585 (581ff40) into master (fcea4d5) will increase coverage by 0.2777%.
The diff coverage is 60.3619%.

Flag
Coverage Δ

cdc
61.5276% <62.1186%> (+0.3795%)
:arrow_up:

dm
51.9908% <56.4728%> (-0.0519%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.
@@               Coverage Diff                @@
##             master      #5585        +/-   ##
================================================
+ Coverage   56.0768%   56.3546%   +0.2777%
================================================
  Files           535        673       +138
  Lines         70143      78604      +8461
================================================
+ Hits          39334      44297      +4963
- Misses        27078      30139      +3061
- Partials       3731       4168       +437

/run-all-tests

/merge


Errors launching and connecting to databases

Azure Data Studio Version:

Version: 1.40.0-insider (user setup)
Commit: 533e1ec1b921d2d246695f6edc441a8231790e9a
Date: 2022-10-21T16:25:06.751Z
VS Code: undefined
Electron: 17.4.5
Chromium: 98.0.4758.141
Node.js: 16.13.0
V8: <IP_ADDRESS>-electron.0
OS: Windows_NT x64 10.0.22621

Steps to Reproduce:

Launch ADS-Insiders
See error message in notification:

Does this issue occur when all extensions are disabled?: Yes/No
Yes

There is no Report Issue menu item.

Dupe of https://github.com/microsoft/azuredatastudio/issues/20916 - we have a fix out and this will be resolved with the next build. Thanks and sorry for the inconvenience!

To the error is different:

[2022-10-21 18:02:19.939] [renderer1] [warning] [Microsoft.azure-cosmosdb-ads-extension]: No description specified to show.
[2022-10-21 18:02:23.560] [renderer1] [error] [/c:/Users/raphc/.azuredatastudio-insiders/extensions/microsoft.azuredatastudio-mysql-0.2.3-alpha.1]: Version specified in `engines.vscode` (*) is not specific enough. For vscode versions before 1.0.0, please define at a minimum the major and minor desired version. E.g. ^0.10.0, 0.10.x, 0.11.0, etc.
[2022-10-21 18:02:23.562] [renderer1] [error] [/c:/Users/raphc/.azuredatastudio-insiders/extensions/microsoft.import-1.5.0]: Version specified in `engines.vscode` (*) is not specific enough. For vscode versions before 1.0.0, please define at a minimum the major and minor desired version. E.g. ^0.10.0, 0.10.x, 0.11.0, etc.
[2022-10-21 18:02:23.564] [renderer1] [error] [/c:/Users/raphc/.azuredatastudio-insiders/extensions/microsoft.query-history-0.5.1]: Version specified in `engines.vscode` (*) is not specific enough. For vscode versions before 1.0.0, please define at a minimum the major and minor desired version. E.g. ^0.10.0, 0.10.x, 0.11.0, etc.
[2022-10-21 18:02:23.566] [renderer1] [error] [/c:/Users/raphc/.azuredatastudio-insiders/extensions/microsoft.sql-migration-1.1.1]: Version specified in `engines.vscode` (*) is not specific enough. For vscode versions before 1.0.0, please define at a minimum the major and minor desired version. E.g. ^0.10.0, 0.10.x, 0.11.0, etc.
[2022-10-21 18:02:23.570] [renderer1] [error] [/c:/Users/raphc/.azuredatastudio-insiders/extensions/microsoft.kusto-0.5.7]: Version specified in `engines.vscode` (*) is not specific enough. For vscode versions before 1.0.0, please define at a minimum the major and minor desired version. E.g. ^0.10.0, 0.10.x, 0.11.0, etc.


Enhanced Error Handling - SweetAlert Integration and Automatic Redirect 🍬🔗

Related Issue

Closes: #284
Description of Changes
This PR replaces the standard error message with a more visually appealing and user-friendly SweetAlert popup for security vulnerabilities. It also includes an automatic redirect to the user panel page upon clicking "OK" on the SweetAlert. These changes significantly enhance the user experience and improve security measures.
Your review and feedback are appreciated as we strive to deliver a more polished and secure application. 🌟🚀
Checklist:

[x] My code adheres to the established style guidelines of this project.
[x] I have conducted a self-review of my code.
[x] I have included comments in areas that may be difficult to understand.
[] I have made corresponding updates to the project documentation.
[x] My changes have not introduced any new warnings.

Screenshots
https://github.com/apoorvaron/Shorty/assets/85815172/3a97e724-7357-47f1-8684-9581d324a01e
Please provide any necessary screenshots to illustrate the changes made.

@apoorvaron Please Review this PR

@Nishitbaria

For this test case, like when user remove the link number from url
Solution : Don't show below error message , just redirect user to user panel (/user/index.php)

For the error, that "link does not exist" , just show unauthorised access error msz because we don't have to tell user that this link is not existing.

Don't show below error message , just redirect user to user panel (/user/index.php)

for this point , removing the link number from url was just a example. This error is for any other error from sql database errors like cant connect or any error from database side

make your call ?

For the error, that "link does not exist" , just show unauthorised access error msz because we don't have to tell user that this link is not existing.
for this i will remove extra layer which check link exists or not

moving the link number from url was just a example. This error is for any other er

Ok Cool...
Noted

Don't show below error message , just redirect user to user panel (/user/index.php)

for this point , removing the link number from url was just a example. This error is for any other error from sql database errors like cant connect or any error from database side

make your call ?

Can we show the error text as?
"Internal Server Error : 500"

Ok Cool!! Noted

Sure, here's the updated code with the condition removed:
<?php

$database = new Database();
$link = $database->connect();

$checkValidity =  // Check if the uniqueNo and linkID combination is valid
if ($CheckResult = mysqli_query($link, $checkValidity)) {
    if (mysqli_num_rows($CheckResult) > 0) {
        $sql = //Get Data
        if ($result = mysqli_query($link, $sql)) {
            if (mysqli_num_rows($result) > 0) {
                $row = mysqli_fetch_array($result);

                // Output the form with the fetched data
                echo "

                ";

                mysqli_free_result($result);
            } else {
                echo "
No Record Found.
";
            }
        } else {
            echo "";
        }
    } else {
        echo "";
    }
} else {
    echo "";
}
?>

I removed the $LinkIDExist condition as requested. The code will now directly check for the validity of the uniqueNo and linkID combination. If the combination is valid, it will proceed to fetch and display the form. Otherwise, it will display an error message and redirect the user back to the index page.

@apoorvaron Check man


[New Feature] Entropy-to-mnemonic CLI utility

Makes our existing mnemonic_generation.oy accessible as an interactive CLI utility for converting dice rolls or coin flips into 12- or 24-word mnemonics.
Also provides a UI for final word calculation.
Reduces python dependencies in mnemonic_generation.py
Removes need to always specify wordlist_language_code.
Adds flexibility for calculate_checksum to accept mnemonic as list or string w/various delimiters.
python3.10 updates to typing.
Adds constants for number of dice rolls for each mnemonic phrase length (since 99 may become 100 soon).
Generates test dice rolls, coin flips, or word selections via its "rand12" and "rand24" option.
Adds support for coin flips, even though the SeedSigner UI does not support coin flips yet (and might not ever).
Updates dice_verification.md accordingly.
New test cases / streamlined test case.

I've had no problems duplicating seedwords while doing so w/ dice labeled 1-6.

However for coins, when running for a 24w seed:
python3 mnemonic_generation.py coins<PHONE_NUMBER>010011000101110110000111101100011110100111001110001001010001101110000010111001111101000110101110110001000100110010000010100110100101010100100101010100001100001110001101000101110000010100111100000001101011011000101100111011100010011000101001101101

I get:
welcome occur core ride below sock convince start song car alcohol question scorpion smart gloom doctor champion acoustic universe camera endorse goddess oyster prefer

while I was expecting:
eyebrow obvious such suggest poet seven breeze blame virtual frown dynamic donor harsh pigeon express broccoli easy apology scatter force recipe shadow claim radio

and similarly for a 12w made from coins:
python3 mnemonic_generation.py coins<PHONE_NUMBER>1100001001101011111000010101010000010100001101110011011110011011111110001010101101110000110001100000011100001001010000

I get:
wise forget cinnamon clump news shadow loan power portion insect lobster radar

while I was expecting:
hole luggage safe present express tragic orbit shed switch metal identify path

I'm also having a problem with the --zero-indexed-dice option
python3 mnemonic_generation.py dice --zero-indexed-dice<PHONE_NUMBER>0541021050022043333012505355332001042330

I get:
jealous inhale song chaos finger adult mutual tourist cash error broccoli lock

While I was expecting to get the same as above... because, I'm not sure, I was thinking that each roll would just be reduced by 1 and then they'd all be hashed at the end.
Ian Coleman gives me two different mnemonics depeding on interpretation; when I select "Base 10" I get:
link rack captain doctor drama replace apple beyond strategy lens bachelor raise

and when I select "Hex" I get:
doctor ancient letter appear awake amused divorce dune drip office afraid pass crystal office length calm case love

@jdlcdl:
For your first example, to reproduce the same coin flips in iancoleman.io, you have to change "Mnemonic length" from "Use Raw Entropy (3 words per 32 bits)" to "24 Words".

I'm also having a problem with the --zero-indexed-dice option

For zero-indexed dice rolls, you can use Base6, Base10, or Hex and, again, specify "Mnemonic Length" as "12 Words".
I've updated the documentation with this info.

ACK tested

In the meeting this morning, I shared the thought of waiting to merge this until after the next release.
It's about "Let's not over-feed the concern-trolls with code changes that include lots of refactoring just before release on a code file named 'mnemonic_generation.py'".
Also, after looking at the code, while I'm not concerned, I wonder... "Does import random belong anywhere in our codebase?".  and I'm not sure that it really does... if for nothing other than to avoid the "concern trolling".

@jdlcdl this is a great point about the random import. At a minimum it should be moved to the CLI-only section.
But for the CLI's stated use case (interactive testing, confirmation, etc) I think some way to generate new test seeds is useful. And note that the usage does include:
Entropy data. Enter "{ RAND_12 }" or "{ RAND_24 }" to create a random (not-secure) example seed.

Now that Release 0.7.0 is out, so that peers will have plenty of time to review this otherwise sensitive code:
As of fe55ccd
ACK tested.

@kdmukai can you resolve the conflict in this PR? Thanks!

This PR is pending some slight refactoring to move the cli utility out of src and into tools.

Updated! Moved CLI functionality into tools/ and updated the docs and related impacted files.

@newtonick the "needs revision" tag can be removed.
PR has been updated to what I consider a "final" form (pending further feedback).

Tested and LGTM