micropython-stubber 1.23.3__py3-none-any.whl → 1.24.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (69) hide show
  1. {micropython_stubber-1.23.3.dist-info → micropython_stubber-1.24.1.dist-info}/METADATA +29 -11
  2. {micropython_stubber-1.23.3.dist-info → micropython_stubber-1.24.1.dist-info}/RECORD +68 -65
  3. {micropython_stubber-1.23.3.dist-info → micropython_stubber-1.24.1.dist-info}/WHEEL +1 -1
  4. mpflash/README.md +2 -2
  5. mpflash/mpflash/basicgit.py +22 -2
  6. mpflash/mpflash/common.py +23 -13
  7. mpflash/mpflash/downloaded.py +10 -2
  8. mpflash/mpflash/flash/esp.py +1 -1
  9. mpflash/mpflash/mpboard_id/__init__.py +9 -4
  10. mpflash/mpflash/mpboard_id/add_boards.py +25 -14
  11. mpflash/mpflash/mpboard_id/board.py +2 -2
  12. mpflash/mpflash/mpboard_id/board_id.py +10 -6
  13. mpflash/mpflash/mpboard_id/board_info.zip +0 -0
  14. mpflash/mpflash/mpremoteboard/__init__.py +13 -8
  15. mpflash/mpflash/vendor/board_database.py +185 -0
  16. mpflash/mpflash/vendor/readme.md +10 -1
  17. mpflash/mpflash/versions.py +28 -40
  18. mpflash/poetry.lock +1147 -231
  19. mpflash/pyproject.toml +4 -3
  20. stubber/__init__.py +1 -1
  21. stubber/board/createstubs.py +76 -34
  22. stubber/board/createstubs_db.py +34 -25
  23. stubber/board/createstubs_db_min.py +90 -83
  24. stubber/board/createstubs_db_mpy.mpy +0 -0
  25. stubber/board/createstubs_mem.py +34 -25
  26. stubber/board/createstubs_mem_min.py +123 -116
  27. stubber/board/createstubs_mem_mpy.mpy +0 -0
  28. stubber/board/createstubs_min.py +154 -145
  29. stubber/board/createstubs_mpy.mpy +0 -0
  30. stubber/board/modulelist.txt +16 -0
  31. stubber/codemod/enrich.py +301 -86
  32. stubber/codemod/merge_docstub.py +251 -66
  33. stubber/codemod/test_enrich.py +87 -0
  34. stubber/codemod/visitors/type_helpers.py +182 -0
  35. stubber/commands/build_cmd.py +16 -3
  36. stubber/commands/clone_cmd.py +3 -3
  37. stubber/commands/config_cmd.py +4 -2
  38. stubber/commands/enrich_folder_cmd.py +33 -21
  39. stubber/commands/get_core_cmd.py +1 -2
  40. stubber/commands/get_docstubs_cmd.py +60 -6
  41. stubber/commands/get_frozen_cmd.py +15 -12
  42. stubber/commands/get_mcu_cmd.py +3 -3
  43. stubber/commands/merge_cmd.py +1 -2
  44. stubber/commands/publish_cmd.py +19 -4
  45. stubber/commands/stub_cmd.py +3 -3
  46. stubber/commands/switch_cmd.py +3 -5
  47. stubber/commands/variants_cmd.py +3 -3
  48. stubber/cst_transformer.py +52 -17
  49. stubber/freeze/common.py +27 -11
  50. stubber/freeze/freeze_manifest_2.py +8 -1
  51. stubber/freeze/get_frozen.py +4 -1
  52. stubber/merge_config.py +111 -0
  53. stubber/minify.py +1 -2
  54. stubber/publish/database.py +51 -10
  55. stubber/publish/merge_docstubs.py +38 -17
  56. stubber/publish/package.py +32 -18
  57. stubber/publish/publish.py +8 -8
  58. stubber/publish/stubpackage.py +117 -50
  59. stubber/rst/lookup.py +205 -41
  60. stubber/rst/reader.py +106 -59
  61. stubber/rst/rst_utils.py +24 -11
  62. stubber/stubber.py +1 -1
  63. stubber/stubs_from_docs.py +31 -13
  64. stubber/update_module_list.py +2 -2
  65. stubber/utils/config.py +33 -13
  66. stubber/utils/post.py +9 -6
  67. stubber/publish/missing_class_methods.py +0 -51
  68. {micropython_stubber-1.23.3.dist-info → micropython_stubber-1.24.1.dist-info}/LICENSE +0 -0
  69. {micropython_stubber-1.23.3.dist-info → micropython_stubber-1.24.1.dist-info}/entry_points.txt +0 -0
stubber/rst/lookup.py CHANGED
@@ -12,17 +12,20 @@ __all__ = [
12
12
  "NONE_VERBS",
13
13
  "CHILD_PARENT_CLASS",
14
14
  "PARAM_FIXES",
15
+ "PARAM_RE_FIXES",
15
16
  "MODULE_GLUE",
16
17
  "RST_DOC_FIXES",
17
18
  "DOCSTUB_SKIP",
18
19
  "U_MODULES",
19
20
  ]
20
21
 
21
- # all possible Types needed for the stubs - exxess types should be removed later , and otherwise won't do much harm
22
+ # all possible Types needed for the stubs - excess types should be removed later , and otherwise won't do much harm
22
23
  TYPING_IMPORT: List[str] = [
23
24
  "from __future__ import annotations",
24
- "from typing import IO, Any, Callable, Coroutine, Dict, Generator, Iterator, List, NoReturn, Optional, Tuple, Union, NamedTuple, TypeVar",
25
25
  "from _typeshed import Incomplete",
26
+ "from typing import IO, Any, Callable, Coroutine, Dict, Generator, Iterator, List, NoReturn, Optional, Tuple, Union, NamedTuple",
27
+ "from typing_extensions import TypeVar, TypeAlias, Awaitable",
28
+ # "# TYPING_IMPORT",
26
29
  ]
27
30
 
28
31
 
@@ -51,9 +54,11 @@ class Fix:
51
54
 
52
55
  U_MODULES = [
53
56
  "array",
57
+ "asyncio",
54
58
  "binascii",
55
59
  "io",
56
60
  "json",
61
+ "machine",
57
62
  "os",
58
63
  "select",
59
64
  "ssl",
@@ -73,8 +78,6 @@ but can also be imported with a `u` prefix
73
78
  # also applies correction for some classes are documented as functions
74
79
 
75
80
  RST_DOC_FIXES: List[Tuple[str, str]] = [
76
- # remove rst highlights from docstrings
77
- (":class: attention\n", ""),
78
81
  # ------------------------------------------------------------------------------------------------
79
82
  # re.rst - function and class with the same name
80
83
  # done: issue https://github.com/micropython/micropython/issues/8273
@@ -121,14 +124,14 @@ LOOKUP_LIST = {
121
124
  "builtins.from_bytes": ("int", 0.95),
122
125
  "builtins.to_bytes": ("bytes", 0.95),
123
126
  "bytearray_at": ("bytearray", 0.95),
124
- "collections.namedtuple": ("stdlib_namedtuple", 0.95),
127
+ "collections.namedtuple": ("type[Tuple[Any, ...]]", 0.95),
125
128
  "gc.collect": ("None", 0.95),
126
129
  "machine.deepsleep": ("NoReturn", 0.95),
127
130
  "machine.reset_cause": ("int", 0.95),
128
131
  "machine.reset": ("NoReturn", 0.95), # never returns
129
132
  "machine.Signal.value": ("int", 0.95),
130
133
  "machine.soft_reset": ("NoReturn", 0.95), # never returns
131
- "machine.UART.irq": ("Incomplete", 0.95), # no IRQ type defined
134
+ "machine.UART.irq": ("_IRQ", 0.95), # no IRQ type defined
132
135
  "machine.UART.write": ("Union[int,None]", 0.95),
133
136
  "machine.UART.readinto": ("Union[int,None]", 0.95),
134
137
  "machine.UART.readline": ("Union[str,None]", 0.95),
@@ -142,17 +145,20 @@ LOOKUP_LIST = {
142
145
  "pyb.hard_reset": ("NoReturn", 0.95), # never returns
143
146
  "pyb.I2C.recv": ("bytes", 0.95), # complex in docstring
144
147
  "pyb.SPI.recv": ("bytes", 0.95), # complex in docstring
145
- "ubluetooth.BLE.irq": ("Any", 0.95), # never returns
148
+ "pyb.hid_keyboard": ("HID_Tuple", 0.95), # ?
149
+ "pyb.hid_mouse": ("HID_Tuple", 0.95), # plain wrong
150
+ "bluetooth.BLE.irq": ("_IRQ", 0.95),
151
+ "ubluetooth.BLE.irq": ("_IRQ", 0.95),
146
152
  "uctypes.bytearray_at": ("bytearray", 0.95),
147
153
  "uctypes.bytes_at": ("bytes", 0.95),
148
154
  "uio.open": ("IO", 0.95), # Open a file.
149
155
  "uos.listdir": ("List[Incomplete]", 0.95),
150
156
  "os.uname": ("uname_result", 0.95),
151
- "ssl.ssl.wrap_socket": (
152
- "IO",
153
- 0.95,
154
- ), # undocumented class ssl.SSLSocket #TODO: or wrapped-socket object ?
155
- "ussl.ussl.wrap_socket": ("IO", 0.95), # undocumented class ssl.SSLSocket
157
+ # undocumented CPython class ssl.SSLSocket
158
+ # TODO: include ssl.SSLSocket from stdlib / mpy_typeshed, currently Incomplete
159
+ "ssl.wrap_socket": ("SSLSocket", 0.95),
160
+ "ussl.wrap_socket": ("SSLSocket", 0.95),
161
+ #
156
162
  "usys.exit": ("NoReturn", 0.95), # never returns
157
163
  "utime.sleep_ms": (
158
164
  "Coroutine[None, None, None]", # Micropython V1.15+ ?
@@ -171,6 +177,31 @@ LOOKUP_LIST = {
171
177
  "_onewire.crc8": ("int", 0.95),
172
178
  # espnow
173
179
  "espnow.ESPNow.recv": ("Union[List, Tuple[None,None]]", 0.95), # list / ? tuple of bytestrings
180
+ # esp32
181
+ "esp32.Partition.readblocks": ("None", 0.95),
182
+ "esp32.Partition.writeblocks": ("None", 0.95),
183
+ "_rp2.bootsel_button": ("int", 0.95),
184
+ "_rp2.DMA.active": ("bool", 0.95),
185
+ "_rp2.DMA.pack_ctrl": ("int", 0.95),
186
+ "_rp2.DMA.unpack_ctrl": ("dict", 0.95),
187
+ "_rp2.DMA.close": ("None", 0.95),
188
+ "_rp2.DMA.config": ("None", 0.95),
189
+ "_rp2.DMA.irq": ("_IRQ", 0.95),
190
+ "_rp2.PIO.state_machine": ("StateMachine", 0.95),
191
+ "_rp2.PIO.irq": ("_IRQ", 0.95),
192
+ "_rp2.PIO.remove_program": ("None", 0.95),
193
+ "_rp2.PIO.add_program": ("None", 0.95),
194
+ "rp2.bootsel_button": ("int", 0.95),
195
+ "rp2.DMA.active": ("bool", 0.95),
196
+ "rp2.DMA.pack_ctrl": ("int", 0.95),
197
+ "rp2.DMA.unpack_ctrl": ("dict", 0.95),
198
+ "rp2.DMA.close": ("None", 0.95),
199
+ "rp2.DMA.config": ("None", 0.95),
200
+ "rp2.DMA.irq": ("_IRQ", 0.95),
201
+ "rp2.PIO.state_machine": ("StateMachine", 0.95),
202
+ "rp2.PIO.irq": ("_IRQ", 0.95),
203
+ "rp2.PIO.remove_program": ("None", 0.95),
204
+ "rp2.PIO.add_program": ("None", 0.95),
174
205
  }
175
206
 
176
207
 
@@ -227,35 +258,152 @@ NONE_VERBS = [
227
258
  # - to allow one module te refer to another,
228
259
  # - to import other supporting modules
229
260
  # - to add missing abstract classes
261
+ # - to add TypeAliases and TypeVars
262
+
263
+ # avoid defining AnyReadableBuf and AnyWritableBuf in m modules
264
+ ANY_BUF = ["from _mpy_shed import AnyReadableBuf, AnyWritableBuf"]
230
265
 
231
266
  MODULE_GLUE = {
232
- "lcd160cr": ["from .machine import SPI"], # module returns SPI objects defined in machine
233
- "esp32": ["from __future__ import annotations"], # Class methods return Class
267
+ "array": ['_T = TypeVar("_T", int, float, str)'],
268
+ "asyncio": ANY_BUF,
269
+ "bluetooth": ANY_BUF
270
+ + [
271
+ "from _mpy_shed import _IRQ",
272
+ ],
234
273
  "collections": [
235
274
  "from queue import Queue",
236
- "from stdlib.collections import OrderedDict as stdlib_OrderedDict, deque as stdlib_deque, namedtuple as stdlib_namedtuple",
237
- ], # dequeu is a subclass
238
- "os": [
239
- # "from stdlib.os import uname_result", # uname returns uname_result
240
- "from stdlib.os import * # type: ignore", # integrate STDLIB
275
+ # "from _mpy_shed.collections import namedtuple as stdlib_namedtuple # type: ignore",
276
+ '_KT = TypeVar("_KT")',
277
+ '_VT = TypeVar("_VT")',
241
278
  ],
242
- "io": ["from stdlib.io import * # type: ignore"], # integrate STDLIB
243
- "socket": ["from stdlib.socket import * # type: ignore"], # integrate STDLIB
244
- "ssl": ["from stdlib.ssl import * # type: ignore"], # integrate STDLIB
245
- # const: 3 - paired with param and return typing
246
- "micropython": ["Const_T = TypeVar('Const_T',int, float, str, bytes, Tuple) # constant"],
247
- #
248
- # "builtins": ["from stdlib.builtins import *"], # integrate STDLIB
279
+ "cmath": [
280
+ "from typing_extensions import TypeAlias",
281
+ # "_C: TypeAlias = SupportsFloat | SupportsComplex | SupportsIndex | complex",
282
+ ],
283
+ "cryptolib": ANY_BUF,
284
+ "esp": ANY_BUF,
285
+ "espnow": [
286
+ "from _espnow import ESPNowBase # type: ignore",
287
+ ], # ESPNowBase is an undocumented base class
288
+ "framebuf": ANY_BUF,
289
+ "hashlib": ANY_BUF
290
+ + [
291
+ "from _mpy_shed import _Hash",
292
+ ],
293
+ "heapq": [
294
+ '_T = TypeVar("_T")',
295
+ ],
296
+ "io": ANY_BUF
297
+ + [
298
+ "from _mpy_shed import IOBase_mp",
299
+ ],
300
+ "lcd160cr": ANY_BUF + ["from pyb import SPI"], # uses SPI
249
301
  # "machine": ["from network import AbstractNIC"], # NIC is an abstract class, although not defined or used as such
250
- "espnow": ["from _espnow import ESPNowBase"], # ESPNowBase is an undocumented base class
302
+ "machine.ADC": [
303
+ "from .Pin import Pin",
304
+ "ATTN_0DB:int = ...",
305
+ ],
306
+ "machine.I2C": ANY_BUF + ["from .Pin import Pin"], # uses Pin
307
+ "machine.I2S": ANY_BUF + ["from .Pin import Pin"],
308
+ "machine.PWM": ANY_BUF + ["from .Pin import Pin"],
309
+ "machine.RTC": [
310
+ "from machine import IDLE",
311
+ ],
312
+ "machine.SD": ["from .Pin import Pin"], # uses Pin
313
+ "machine.SDCard": ["from .Pin import Pin"], # uses Pin
314
+ "machine.Signal": ["from .Pin import Pin"], # uses Pin
315
+ "machine.SPI": ANY_BUF + ["from .Pin import Pin"], # uses Pin
316
+ "machine.UART": ANY_BUF
317
+ + [
318
+ "from machine import IDLE",
319
+ "from .Pin import Pin",
320
+ "from _mpy_shed import _IRQ",
321
+ ], # uses Pin
322
+ "micropython": [
323
+ "from typing import Tuple, Final",
324
+ "from typing_extensions import TypeVar",
325
+ '_T = TypeVar("_T")',
326
+ '_F = TypeVar("_F", bound=Callable[..., Any])',
327
+ 'Const_T = TypeVar("Const_T", int, float, str, bytes, Tuple) # constant',
328
+ ],
329
+ "network": ["from typing import Protocol"], # for AbstractNIC
330
+ "neopixel": [
331
+ "from _mpy_shed import _NeoPixelBase",
332
+ ], # for AbstractNIC
333
+ "os": [
334
+ "from _mpy_shed import uname_result",
335
+ ],
336
+ "pyb": ANY_BUF
337
+ + [
338
+ "from .UART import UART",
339
+ "from _mpy_shed import _OldAbstractBlockDev, _OldAbstractReadOnlyBlockDev, HID_Tuple",
340
+ ],
341
+ "pyb.ADC": ANY_BUF + ["from .Pin import Pin", "from .Timer import Timer"],
342
+ "pyb.CAN": ANY_BUF,
343
+ "pyb.DAC": ANY_BUF
344
+ + [
345
+ "from .Pin import Pin",
346
+ "from .Timer import Timer",
347
+ ],
348
+ "pyb.ExtInt": ["from .Pin import Pin"],
349
+ "pyb.I2C": ANY_BUF,
350
+ "pyb.SPI": ANY_BUF,
351
+ "pyb.UART": ANY_BUF,
352
+ "pyb.USB_HID": ANY_BUF,
353
+ "pyb.USB_VCP": ANY_BUF,
354
+ "pyb.Switch": ["from .Pin import Pin"], # uses Pin
355
+ "pyb.Timer": [
356
+ "from abc import ABC, abstractmethod",
357
+ "from .Pin import Pin",
358
+ ], # uses Pin
359
+ "_rp2.DMA": ["from _mpy_shed import _IRQ"],
360
+ "_rp2.PIO": ["from _mpy_shed import _IRQ"],
361
+ "rp2.PIO": ["from _mpy_shed import _IRQ"],
362
+ "rp2.DMA": ["from _mpy_shed import _IRQ"],
363
+ "socket": [
364
+ "from typing_extensions import TypeAlias",
365
+ "from _mpy_shed import AnyReadableBuf, AnyWritableBuf",
366
+ ],
367
+ "ssl": [
368
+ "from typing_extensions import TypeAlias",
369
+ "from _mpy_shed import StrOrBytesPath",
370
+ "SSLSocket : TypeAlias = Incomplete",
371
+ ],
372
+ "struct": ANY_BUF,
373
+ "time": [
374
+ "from typing_extensions import TypeAlias, TypeVar",
375
+ "_TicksMs: TypeAlias = int",
376
+ "_TicksUs: TypeAlias = int",
377
+ "_TicksCPU: TypeAlias = int",
378
+ '_Ticks = TypeVar("_Ticks", _TicksMs, _TicksUs, _TicksCPU, int)',
379
+ ],
380
+ "uctypes": ANY_BUF
381
+ + [
382
+ # "from typing_extensions import TypeAlias",
383
+ # "_ScalarProperty: TypeAlias = int",
384
+ # "_RecursiveProperty: TypeAlias = tuple[int, _property]",
385
+ # "_ArrayProperty: TypeAlias = tuple[int, int]",
386
+ # "_ArrayOfAggregateProperty: TypeAlias = tuple[int, int, _property]",
387
+ # "_PointerToAPrimitiveProperty: TypeAlias = tuple[int, int]",
388
+ # "_PointerToAaAggregateProperty: TypeAlias = tuple[int, _property]",
389
+ # "_BitfieldProperty: TypeAlias = int",
390
+ # "_property: TypeAlias = _ScalarProperty | _RecursiveProperty | _ArrayProperty | _ArrayOfAggregateProperty | _PointerToAPrimitiveProperty | _PointerToAaAggregateProperty | _BitfieldProperty",
391
+ # "_descriptor: TypeAlias = tuple[str, _property]",
392
+ ],
251
393
  }
252
394
 
253
395
 
254
396
  PARAM_FIXES = [
255
397
  Fix("\\*", "*"), # change weirdly written wildcards \* --> *
256
398
  Fix(r"\**", "*"), # change weirdly written wildcards \* --> *
257
- Fix(r"/*", "*"), # change weirdly written wildcards \* --> *
258
- Fix(r"/)", ")"), # strange terminator in machine.USBDevice `USBDevice.active(self, [value] /)`
399
+ Fix(r"/*", "*"), # change weirdly written wildcards /* --> *
400
+ Fix(r"**", "*"), # change weirdly written wildcards ** --> *
401
+ # do not remove / , this indicates positional only notation before the ,/
402
+ # RE to insert missing , before /
403
+ Fix(from_=r"(\w+.*?[^,])\s*/", to=r"\1 ,/", is_re=True),
404
+ Fix(", ,/", ", /"), # remove double commas ( cause by the above fix) its a kludge
405
+ # Fix("]=None /)", "]=None, /)")
406
+ # ref: https://regex101.com/r/crVQfA/1
259
407
  Fix("'param'", "param"), # loose notation in documentation
260
408
  # illegal keywords
261
409
  Fix(
@@ -276,7 +424,7 @@ PARAM_FIXES = [
276
424
  # pyb.hid((buttons, x, y, z))
277
425
  Fix(
278
426
  "(buttons, x, y, z)",
279
- "hidtuple:Tuple",
427
+ "hid_tuple:HID_Tuple",
280
428
  ),
281
429
  # esp v1.15.2 .. function:: getaddrinfo((hostname, port, lambda))
282
430
  Fix(
@@ -338,10 +486,10 @@ PARAM_FIXES = [
338
486
  "pins:Optional[Tuple]",
339
487
  ), #
340
488
  ## rp2.PIO.irq
341
- Fix(
342
- "trigger=IRQ_SM0|IRQ_SM1|IRQ_SM2|IRQ_SM3",
343
- "trigger=IRQ_SM0",
344
- ),
489
+ # Fix( No longer needed with py 3.10 notation
490
+ # "trigger=IRQ_SM0|IRQ_SM1|IRQ_SM2|IRQ_SM3",
491
+ # "trigger=IRQ_SM0",
492
+ # ),
345
493
  # SPI.INIT - to fix error: Non-default argument follows default argument
346
494
  # ✅ fixed in doc v1.18+
347
495
  Fix(
@@ -482,25 +630,37 @@ PARAM_FIXES = [
482
630
  ),
483
631
  ]
484
632
 
633
+ # and some param fixes that require a regex
634
+ PARAM_RE_FIXES = [
635
+ Fix(
636
+ r"\[angle, time=0\]", "[angle], time=0", is_re=True
637
+ ), # fix: method:: Servo.angle([angle, time=0])
638
+ Fix(
639
+ r"\[speed, time=0\]", "[speed], time=0", is_re=True
640
+ ), # fix: .. method:: Servo.speed([speed, time=0])
641
+ Fix(
642
+ r"\[service_id, key=None, \*, \.\.\.\]", "[service_id], [key], *, ...", is_re=True
643
+ ), # fix: network - AbstractNIC.connect
644
+ ]
485
645
  # List of classes and their parent classes that should be added to the class definition
486
646
  CHILD_PARENT_CLASS = {
487
647
  # machine
488
- # SoftSPI is defined before SPI, so baseclass is not yet available - but in a .pyi that is OK
489
648
  "SoftSPI": "SPI",
490
649
  "SoftI2C": "I2C",
491
650
  "Switch": "Pin",
492
651
  "Signal": "Pin",
493
652
  # uio # unclear regarding deprecation in python 3.12
494
- # "IOBase": "IO", # DOCME not in documentation
653
+ # "IOBase": "IO", # DOC_ME not in documentation
495
654
  "TextIOWrapper": "IO", # "TextIOBase, TextIO", # based on Stdlib
496
655
  "FileIO": "IO", # "RawIOBase, BinaryIO", # based on Stdlib
497
656
  "StringIO": "IO", # "BufferedIOBase, BinaryIO", # based on Stdlib
657
+ "IOBase": "IOBase_mp", # "BufferedIOBase, BinaryIO", # based on Stdlib
498
658
  "BytesIO": "IO", # "BufferedIOBase, BinaryIO", # based on Stdlib
499
- "BufferedWriter": "IOBase", # DOCME: not in documentation # "BufferedWriter": "BufferedIOBase", # based on Stdlib
659
+ "BufferedWriter": "IOBase_mp", # DOC_ME: not in documentation # "BufferedWriter": "BufferedIOBase", # based on Stdlib
500
660
  # uzlib
501
661
  # "DecompIO": "IO", # https://docs.python.org/3/library/typing.html#other-concrete-types
502
662
  # -------------------------------------------------------------------------------------
503
- # network - AbstractNIC is definined in docstub network.pyi , but not actually used
663
+ # network - AbstractNIC is defined in docstub network.pyi , but not actually used
504
664
  # "WLAN": "AbstractNIC",
505
665
  # "WLANWiPy": "AbstractNIC",
506
666
  # "CC3K": "AbstractNIC",
@@ -515,17 +675,21 @@ CHILD_PARENT_CLASS = {
515
675
  "namedtuple": "tuple",
516
676
  "deque": "stdlib_deque",
517
677
  # ESPNow
518
- "ESPNow": "ESPNowBase,Iterator", # causes issue with mypy
678
+ "ESPNow": "ESPNowBase, Iterator", # causes issue with mypy
519
679
  "AIOESPNow": "ESPNow",
520
680
  # array
521
681
  "array": "List",
682
+ # network
683
+ "AbstractNIC": "Protocol",
684
+ # neopixel
685
+ "NeoPixel": "_NeoPixelBase",
522
686
  }
523
687
 
524
688
 
525
689
  # TODO : implement the execution of this list during merge
526
- # - this is a list of functions, classes methods and constantsn that are not detected at runtime, but are avaialble and documented
690
+ # - this is a list of functions, classes methods and constants that are not detected at runtime, but are available and documented
527
691
  # the standard merge only adds documentation to detected functions.
528
- FORCE_NON_DETECED = [
692
+ FORCE_NON_DETECTED = [
529
693
  ("btree", "Btree", ["esp32", "esp8266"]), # Is not detected runtime
530
694
  ("espnow", "ESPNow.peers_table", ["esp32"]), # Is not detected runtime
531
695
  ]