sg-wireless / pymakr-vsc Goto Github PK
View Code? Open in Web Editor NEWLicense: GNU General Public License v3.0
License: GNU General Public License v3.0
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
I am receiving the errors that There was an error with your serial port module, paymakr will likely not work properly. ....
(If it’s long, please paste to https://gist.github.com and insert the link here)
Operating system: Ubuntu 18.10
Pymakr version: 1.4.17
Add a file explorer t show the files on the devboard
Based on : \vscode-extension-samples\tree-view-sample
Under the listed folder
• / root fs , may be empty)
• /flash
• /sd (if mounted)
Primitives
- ListDir -recursive
- Upload single File
- Download Single File
- Delete file
- Rename file
- Copy file (on MCU )
- Run file on board (exec( foo.py )
- Import file on board (import foo
- View File (download & view )
Actions / use cases :
this would also allow a lot of rather complex code flows to list / traverse folders to be replaced by a much simpler approach.
to only downside that I can see is that the script and generating the JSON will have somewhat larger memory requirements than the current approach.
https://gist.github.com/Josverl/a6f6be74e5193a8145e351ff9439ae3e
C:\develop\repro\pymakr-vsc>npm install --save-dev babel-core
npm ERR! code ETARGET
npm ERR! notarget No matching version found for parser-regex@^1.0.5
npm ERR! notarget In most cases you or one of your dependencies are requesting
npm ERR! notarget a package version that doesn't exist.
npm ERR! notarget
npm ERR! notarget It was specified as a dependency of 'serialport'
npm ERR! notarget
An indeed there is no 1.0.5 version on NPM
npm view parser-regex
shows that the latest: 1.0.2
A similar error is shown in my regular environment.
environment to work
This may have to do with different version of the serial library, as I tried to experiment with multiple version of that a while ago. I assumed I cleaned that all up , but there may be stray libraries.
Operating system:
VSCode version:
n/a
Pymakr version:
https://github.com/pycom/pymakr-vsc.git
Hi :),
I'm using the Pymakr Plugin on Visual Code, I saw some changes were applied on pymakr.
However, I'm unavailable to upload the code to the ESP32 device, the terminal shows the following trouble.
I made some tries, but none of those were successful.
Note: using Atom editor, works fine!
Thanks in advance!
Console shows:
Activating extension pycom.Pymakr
failed: %1 is not a valid Win32 application.
\?\C:\Users\myuser.vscode\extensions\pycom.pymakr-0.1.1\precompiles\serialport-win32\build\Release\serialport.node
However it is working on VSCode x32.
I have still same error :command pymakr.connect not found
Im using VSCODE on Opensuse Tumbleweed
Can you help for this issue ?
Im interested to why pycom isnt more open to helping micropython generally ? As it gets better so does pycom ? Maybe im missing an article about this? Thanks
After installing all above I tried to use "Pymakr > Global settings" to setup my connection to the LoPy4 but I just get the error message "command 'pymakr.globalSettings' not found".
I also tried to use other pymakr commands from the Command Palette and with all commands I get this kind of error. Also in the left down corner there is no pymakr related gui elements which should be there.
Getting the gui elements and that the commands are working.
(If it’s long, please paste to https://gist.github.com and insert the link here)
Not yet but I am willing to help and to provide logs if needed.
Installed Software:
VSC (output of "Help" -> "About"):
Version: 1.33.1
Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8
Date: 2019-04-11T08:20:22.771Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Linux x64 4.19.0-4-amd64
node.js LTS version:
https://packages.debian.org/de/buster/nodejs
npm (just in case):
https://packages.debian.org/de/buster/npm
Operating system: Debian Buster all updates installed
VSCode version:1.33.1
Pymakr version: 1.1.0
Before update it can work normally after install update, When i start VSC it auto connect to board from address in file pymakr.json warnning show
(Running the contributed command:'pymakr.connect' failed.) i can't command in pymakr.
VS Code version: Code 1.27.2 (f46c4c4, 2018-09-12T16:17:45.060Z)
OS version: Windows_NT x64 10.0.17134
Pymakr version: 1.0.3
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
/ROOT/subdir/file.py
)/ROOT
download, while any under a sub dir report as failed.# Actual Path: /stubs/esp32_1_10_0/gc.py
[18/66] Reading stubsesp32_1_10_0/gc.py
Failed to download stubsesp32_1_10_0/gc.py
(If it’s long, please paste to https://gist.github.com and insert the link here)
\0x00
were populating the list of supposed files, therefore all going through the callback.Operating system:
VSCode version:
Version: 1.33.1
Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8
Date: 2019-04-11T08:20:22.771Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Linux x64 5.0.9-arch1-1-vfio
Pymakr version:
Hi,
I'm trying to update a project I had previously running on a LoPy board and am currently unable to sync the project from Visual Studio Code.
I have updated my version of node.js to the current LTS (8.9.4), and am running Visual Studio Code 1.19.2, Date 2018-01-10 Shell 1.7.9 Renderer 58.0.3029.110, Node 7.9 Architecture x64 with Pymakr 0.1.7. I have also run the firmware updater on the LoPy device and it is running the latest firmware. I am running Visual Studio code under 64bit Windows 10.
Before performing all the updates today I could not connect to a LoPy at all. Getting the error "command 'pymakr.connect' not found". Having performed the updates to the above version I can now connect to a LoPy device sucessfully, however, I am currently unable to synchronise the project and get the error "command 'pymakr.sync' not found.
Do you have any suggested solutions to this problem? Many thanks.
I expect to be able to disconnect and reconnect
(If it’s long, please paste to https://gist.github.com and insert the link here)
VSCode shows an error and is unable to connect any more
X Running the contributed command:'pymakr.toggleConnect' failed.
a rough workaround is to reload the VSCode window using >Reload Window
there appears to be a bug in the connect function; it references _this. while is should reference this.
disconnect(cb){
this.logger.info("Disconnecting...")
if(this.pyboard.isConnecting()){
this.terminal.writeln("Connection attempt canceled")
}
// else{
// this.terminal.writeln("Disconnected. Click here to reconnect.")
// }
clearInterval(this.connection_timer)
this.api.setConnectionState(_this.pyboard.address,false) // <-- _this does not exists ….
this.pyboard.disconnect(function(){
if(cb) cb()
})
this.synchronizing = false
this.runner.stop()
this.setButtonState()
}
Operating system:
Windows 10 [Version 10.0.17134.285]
VSCode version:
Version: 1.27.2 (system setup)
Commit: f46c4c469d6e6d8c46f268d1553c5dc4b475840f
Date: 2018-09-12T16:17:45.060Z
Electron: 2.0.7
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
Architecture: x64
Pymakr version:
1.0.3
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
What happens is the upload gets stuck and it doesn't continue. Reconnecting and rebooting the device doesn't help either.
I was expecting the upload to finish and then the weather station device(M5 Stack)
to work
https://gist.github.com/prateekchikara/037203fb42c6201bfc07a7f4fa0e53f1
Operating system:
Windows 10
VSCode version:
1.32.1
Pymakr version:
1.0.7
Hi how is life...
Working on win 10 and VS Code 1.38
Did install PyMakr through the extention market place
No command is found... seem like it doesn't see the installation
But seem to be install in the good place with the other extension
C:\Users\blablabla.vscode\extensions
If any can help, would be very welcome...
It make a few evening searching... and nothing
Best Regards,
Steph
in other cases ( mostly when pymakr has not been able to sucesfully connect on the first attempt) the connect state always shows as disconnected [ X Pycom console ]
at best :
at least :
Operating system:
Microsoft Windows [Version 10.0.17763.195]
VSCode version:
Version: 1.30.2 (user setup)
Commit: 61122f88f0bf01e2ac16bdb9e1bc4571755f5bd8
Date: 2019-01-07T22:54:13.295Z
Electron: 2.0.12
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
OS: Windows_NT x64 10.0.17763
Pymakr version:
1.0.4
My VS Code auto-updated to the July 2018 release, Version 1.26.0 (1.26.0). Since then, the pymakr extension has stopped working. My system is running MacOS High Sierra 10.13.6 and my installed node-js is v6.11.2.
I've tried reinstalling the pymakr extension, then restarting VS Code. I've tried disabling, restarting, reloading, and even restarting my Macbook, etc etc. but continue to errors when trying to use any of the pymakr commands. These all worked just fine previous to the vs code update. For instance, when selecting typical commands, I get an an saying "command 'pymakr.projectSettings' not found" or "command 'pymakr.help' not found".
I've tested the issue by downgrading to the June 2018 VS Code release and pymakr works fine again, but stops working as soon as I update to July 2018.
I'd like to be able to update VS Code going forward while still using your extension -- if there is something I can do to help debug let me know?
File project.pymakr gets synced even if it is marked as to be ignored via "py_ignore" setting in pymakr.conf and pymakr.json. Also that file is not included in the project folder, so I do not know where it is taken from.
It seems to include SHA256sums of boot.py and main.py.
Either the file should be synced to verify that the files where transmitted/uploaded correctly via the serial/wifi connection, then it should be removed from "py_ignore" setting in pymakr.conf and pymakr.json. Or it should not be synced and the "py_ignore" setting in pymakr.conf and pymakr.json is correct, then the upload is a bug because it should not be uploaded as defined in this two files.
But after reading the terminal output, the file seems to be needed to check the project status so it should be removed from "py_ignore" setting in pymakr.conf and pymakr.json. Maybe a leftover from earlier days.
If deleting the file before uploading the project I get a
Reading file status
Failed to read project status, uploading all files
in the terminal.
If NOT deleting the file before uploading the project I get a
Reading file status
No files to upload
in the terminal.
Operating system: Debian Buster all updates installed
VSCode version: 1.33.1
Pymakr version: 1.1.2
Version: 1.41.1
Commit: 26076a4de974ead31f97692a0d32f90d735645c0
Date: 2019-12-18T15:04:31.999Z
Electron: 6.1.5
Chrome: 76.0.3809.146
Node.js: 12.4.0
V8: 7.6.303.31-electron.0
OS: Linux x64 4.15.0-72-generic snap
Welcome to Node.js v13.0.0-nightly20190802452b393c1f.
Type ".help" for more information.
see issues #4 #11 #28 #42 #53 #54
When vscode updates to an electron version that has a different ABI, the serialport module breaks
These updates seem to come unexpected for end-users.
during packaging add the native bindings for :
multiple platforms
multiple electron versions ( ABI versions more specifically)
this can be done by a script ( approx 200 lines of ps1 code)
test against the insiders build of vscode to pre-empt version changes , and publish updates containing updated native bindings, before they are rolled out to the general public
this would need to be done by an automated build/test system
the reference uses Azure Pipelines which is free for open source projects such as pymakr.
This is described in the reference implementation documented at :
https://github.com/Josverl/pymakr-vsc/blob/fix/SerialMultiPlatform/doc/multiplatform%20support.md#multiplatform-support
see the discussion on #53
im working on a PR , but as it is quite large, may need to work to bring it into shape.
vscode --uninstall-extension pycom.pymakr
vscode --install-extension pycom.pymakr --verbose
VSCode gets stuck in the "Installing" state. No verbose logs.
installing the extension
Nope
This might be related to #28
Operating system: Ubuntu bionic
VSCode version: 1.31.0
snap list
[snip]
vscode 1.31.0-1549443364 77 beta snapcrafters classic
Pymakr version: 1.0.6
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
Message is shown : All items overritten
Message to read : All items overwritten
Pymakr version:
1.1.3
ets Jun 8 2016 00:22:57
rst:0x1 (POWERON_RESET),boot:0x27 (DOWNLOAD_BOOT(UART0/UART1/SDIO_REI_REO_V2))
waiting for download
'
I have created a fix/workaround for this by setting rts to high in pyserial - sendPing() for windows
but I have not been able to test it on other platforms or with other devices
Operating system:
Microsoft Windows [Version 10.0.17134.285]
VSCode version:
Version: 1.27.2 (system setup)
Commit: f46c4c469d6e6d8c46f268d1553c5dc4b475840f
Date: 2018-09-12T16:17:45.060Z
Electron: 2.0.7
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
Architecture: x64
Pymakr version:
1.0.3
Pressing CTRL+E to enter paste mode on the REPL opens a text box field on VS Code, instead of enabling paste mode on the MicrPython REPL. It's possible that other shortcuts are affected by this same problem.
Plugin doesn't work, I cannot see the Pymakr console, and all shortcut fail:
CTRL + SHIFT + C = command 'pymakr.connect' not found
CTRL + SHIFT + G = command 'pymakr.globalSettings' not found
...
Things used to work with previous VS Code version installed (don't know exactly which version)
Nope (don't know where I can get some ?)
I tried to disable / enable the plugin, no chance
I tried to uninstall / install the plugin, no chance
Operating system:
Linux ubuntu 18.04.2 LTS
VSCode version:
1.36.1
Pymakr version:
1.1.3
Hi, first of all thanks for providing this extension. After using it a bit I would like to share some feedback. I'm using VSCode for different kinds of projects (Python, Go, JS, HTML, ...).
When working on non-Pycom (LoPy) related projects, I experience that this extension takes over VSCode a bit too much and gets in my way. My current flow is that I disable this extension completely, and only enable it manually when working on Pycom related code. This should not be needed.
What I would like is:
*.go
file, I don't want the Pycom terminal, I want a normal shell)I think it would be sufficient when the extension shows the available commands in the Command Palette when the editor is in the context of a *.py
file and that people are able to open a Pycom terminal through this Command Palette, instead of changing this default behavior.
How would I connect Pymakr to a generic ESP32 micropython device on the network? Does it work with webrepl?
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
A constant stream of error popups that are too fast to see what they say and render VS Code unusable
Fix is to install Node, but no obvious indication this should happen
VS Code should be usable, and maybe a single error telling you to install Node.
Ideally give the option for an auto install of Node
Operating system:
Windows 10
VSCode version:
1.33.1
Pymakr version:
1.0.7
More than one Pycom Console is created but they can not be closed. If trying to close them via the Kill Terminal button in VSC in the right down corner, they get recreated even if they do not have any use.
Just one Pycom Terminal should be created.
(If it’s long, please paste to https://gist.github.com and insert the link here)
Operating system: Debian Buster all updates installed
VSCode version: 1.33.1
Pymakr version: 1.1.0
Just moving this issue from the pymakr-atom repo as I created in the wrong repo.
History: sg-wireless/pymakr-atom#31
Still having the problem that I can only connect via WIFI. Has anybody been able to connect to the Pycom device (in my case a LoPy) via USB Serial ?
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
On restart, the pymakr extension won't load.
The extension should load, reporting an error in the conf file and ignoring its content.
Here are my global settings:
{
"address": "/dev/tty.wchusbserial640",
"username": "micro",
"password": "python",
"sync_folder": "",
"open_on_start": true,
"safe_boot_on_upload": false,
"py_ignore": [
"pymakr.conf",
".vscode",
".gitignore",
".git",
"project.pymakr",
"venv"
],
"fast_upload": false,
"sync_file_types": "py,txt,log,json,xml,html,js,css,mpy",
"ctrl_c_on_connect": false,
"sync_all_file_types": false,
"auto_connect": false,
"autoconnect_comport_manufacturers": [
"Pycom",
"Pycom Ltd.",
"FTDI",
"Microsoft",
"Microchip Technology, Inc."
]
}
The developer's tools console report the error (notice the trailing comma on the last line):
TypeError: Cannot use 'in' operator to search for 'address' in {
"address": "/dev/tty.wchusbserial640",
"username": "micro",
"password": "python",
"sync_folder": "",
"open_on_start": true,
"safe_boot_on_upload": false,
"py_ignore": [
"pymakr.conf",
".vscode",
".gitignore",
".git",
"project.pymakr",
"venv"
],
"fast_upload": false,
"sync_file_types": "py,txt,log,json,xml,html,js,css,mpy",
}
Operating system:
MacOS 10.13.6
VSCode version:
1.33.1
Pymakr version:
1.1.0
Hi all,
Pymakr plugin is simply not working. The Pycom Console button on the bottom line toggles by clicking on it between cross and hook, regardless if there is a device connected to the computer or not. The "List Serial Ports" command, does just nothing.
My box works on Windows 10 x64. My Pymakr plugin for Atom is also broken. Maybe I go back to something working, till the Pymakr tools work properly.
Cheers,
Thomas
I'm trying to connect to my Pycom while there's also another COM device connected. Following this tutorial I pasted 'COM20' into the address in pymakr.json, but when I run 'Pymakr > Connect' it tries to connect on 'COM24'
Connecting op COM20
//Pymakr > List serial ports:
Found 3 serialports
COM24 (Microsoft) (copied to clipboard)
COM20 (Microsoft)
COM1 ((Standaardpoorttypen))
// Pymakr > Connect
Connecting to COM24...
Failed to connect (Error: Port is not open). Click here to try again.
Connecting to COM24...
Failed to connect (Error: Port is not open). Click here to try again.
pymakr.json
{
"address": "COM20",
"username": "micro",
"password": "python",
"sync_folder": "",
"open_on_start": true,
"safe_boot_on_upload": false,
"py_ignore": [],
"fast_upload": false,
"sync_file_types": "py,txt,log,json,xml,html,js,css,mpy",
"ctrl_c_on_connect": false,
"sync_all_file_types": false,
"auto_connect": true,
"autoconnect_comport_manufacturers": [
"Pycom",
"Pycom Ltd.",
"FTDI",
"Microsoft",
"Microchip Technology, Inc."
]
}
Deleting "Microsoft" from autoconnect_comport_manufacturers makes it not connect to COM24 anymore, but doesn't let me connect to COM20 either. It seems that the address parameter doesn't work at all.
Operating system:
Windows 10
VSCode version:
Version: 1.32.3 (system setup)
Commit: a3db5be9b5c6ba46bb7555ec5d60178ecc2eaae4
Date: 2019-03-14T23:43:35.476Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17134
Pymakr version:
1.0.7
(Hi! 👋 Thanks for reporting an issue! Please make sure you click the link above to view the issue guidelines, then fill out the blanks below.)
An error pops up.
I was expecting no error to pop up.
There was an error with your serialport module, Pymakr will likely not work properly. Please try to install again or report an issue on our github (see developer console for details)
https://gist.github.com/MJtuks/6e16d397690be9a67418b5fec4e54e01
Operating system:
Windows 10
VSCode version:
Version: 1.39.2 (user setup)
Commit: 6ab598523be7a800d7f3eb4d92d7ab9a66069390
Date: 2019-10-15T15:35:18.241Z
Electron: 4.2.10
Chrome: 69.0.3497.128
Node.js: 10.11.0
V8: 6.9.427.31-electron.0
OS: Windows_NT x64 10.0.18362
Pymakr version:
1.1.3
Executing the code to let the led blink works fine ("Pymakr > Run Current File"). But I am not able to upload or download files via USB. Connecting via Wifi and then FTP works fine.
Uploading and downloading from the LoPy4 should work.
(If it’s long, please paste to https://gist.github.com and insert the link here)
See attached screenshot
Operating system: Debian Buster all updates installed
VSCode version: 1.33.1
Pymakr version: 1.1.0
import pycom ; pycom.wdt_on_boot(True) ; pycom.wdt_on_boot_timeout(15000)
)."safe_boot_on_upload": true
.The WDT resets the board while files are being uploaded.
When safe booting, I expect Pymakr to take control over the WDT and keep feeding it throughout the upload.
Is it possible to F5 debug (or even just stop and run with no debugger attached) in VSCode?
The REPL is fantastic, but hitting CTRL+SHIFT+C, CTRL+SHIFT+R
every time is a bit tedious. Or perhaps it's there and I don't know the proper launch.json config settings?
this is an extreme repro, but as i found the download to be unreliable I wanted to narrow down the issue or issues
pymakr is unable to download any files.
the reason for this is that import os
is missing from the code that is used to list the current files on the board
in addition the resulting error condition is not detected/handled properly
the download to work robustly
After additional additional errorhandling the following error messages become apparent :
[silly] Sync | Entered raw mode
[verbose] Pyboard | Executing code:import ubinascii,sys
list = ubinascii.hexlify(str(os.listdir('/flash/')))
sys.stdout.write(list)
[silly] Pyboard | Executed raw code, now resetting
[info] Pyboard | Soft reset
[silly] Pyboard | Received message: OK
[silly] Pyboard | Buffer length now 2
[silly] Pyboard | Waiting for >
[silly] Pyboard | Received message: �Traceback (most recent call last):
File "<stdin>", line 3, in <module>
NameError: name 'os' is not defined
�>
fixing this specific error is trivial by adding the import to import ubinascii,sys
--> 'import ubinascii,sys,os'
I would suggest that the download code should is by adding errorhandling and retries as there are additional cases in which errors are returned by the board , and not detected.
as a result the error messages are treaded as base64 encoded strings , and an attempt is made to decode these , and the resulting downloaded file is corrupted or contains garbled information at best.
also the download code does not close the files, which will/might consume/leak memory on the MCU leading to failed downloads once memory is exhausted.
I'm not quite sure if the raw repl + reset (Ctrl-A, , CTRL-D will be able to free the memory in this case, but I think its better to avoid the lead than assume that the RAW Repl will cleanup
Operating system:
Microsoft Windows [Version 10.0.17763.55]
VSCode version:
Version: 1.28.1 (system setup)
Commit: 3368db6750222d319c851f6d90eb619d886e08f5
Date: 2018-10-11T18:13:53.910Z
Electron: 2.0.9
Chrome: 61.0.3163.100
Node.js: 8.9.3
V8: 6.1.534.41
Architecture: x64
Pymakr version:
1.0.3
Hello all,
I want to ask you to take a look to video attached, where I connect ESP32 board to my PC and Flash it by micropython Firmware (not in video), but I want to upload my main.py into board but unfortunatelly with no access. VS Code fall every time.
but is it even possible to operate different ESP board?
Link: https://www.youtube.com/watch?v=gXn_wUPcgmw&feature=youtu.be
Thank you for help
Jan
OS: Ubuntu 16.04
Python 2.7
PyMakr VScode extension 0.1.7
Reason: there is no possible upload file to board.
Connecting on /dev/ttyUSB0...
>>> import esp
>>> esp.check_fw()
size: 600872
md5: 35e285a80516e70242ebf7d780d6c70f
True
>>>
Uploading project (main folder)...
Reading file status
Failed to read project status, uploading all files
[1/2] Writing file boot.py
Upload failed. Please reboot your device manually.
MicroPython v1.9.3-8-g63826ac5c on 2017-11-01; ESP module with ESP8266
Type "help()" for more information.
>>>
Seems this bug is very similar to sg-wireless/pymakr-atom#58
I made the critical mistake of shutting down Visual Studio Code earlier today and now I cannot get the Pymakr extension to load on Code startup. I have tried all 5 of the available versions for Windows (User 32 / 64 bit, System 32 / 64 bit, and the zip folder), performing a complete wipe of Code between each installation (instructions here)
I see in the console output (available under Developer Tools) that Pymakr is failing due to pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node is not a valid Win32 application
I'm not sure what (if anything) changed on my system earlier today. All I did was shut down Visual Studio Code so I could run the Pycom firmware updater on a GPy, and then Pymakr refused to load the next time I started Visual Studio Code.
Version: 1.33.1
Commit: 51b0b28134d51361cf996d2f0a1c698247aeabd8
Date: 2019-04-11T08:27:14.102Z
Electron: 3.1.6
Chrome: 66.0.3359.181
Node.js: 10.2.0
V8: 6.6.346.32
OS: Windows_NT x64 10.0.17134
Output from the Console window (available under Help-> Toggle Developer Tools):
extensionService.ts:800 Activating extension 'pycom.pymakr' failed: \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node is not a valid Win32 application. \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node. _logMessageInConsole @ extensionService.ts:800 console.ts:134 [Extension Host] Activating extension
pycom.pymakr failed: \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node is not a valid Win32 application. \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node t.log @ console.ts:134 console.ts:134 [Extension Host] Here is the error stack: Error: \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node is not a valid Win32 application. \\?\c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\build\Release\bindings.node at process.module.(anonymous function) [as dlopen] (ELECTRON_ASAR.js:166:20) at Object.Module._extensions..node (internal/modules/cjs/loader.js:740:18) at Object.module.(anonymous function) [as .node] (ELECTRON_ASAR.js:166:20) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at bindings (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\bindings\bindings.js:81:44) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\lib\win32.js:1:191) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\lib\win32.js:111:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\lib\index.js:6:22) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\@serialport\bindings\lib\index.js:17:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\serialport\lib\index.js:2:17) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\node_modules\serialport\lib\index.js:17:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\lib\connections\pyserial.js:20:18) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\lib\connections\pyserial.js:238:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\lib\pymakr.js:18:17) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\lib\pymakr.js:834:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at n (c:\VSCode\resources\app\out\vs\loader.js:15:874) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\pymakr.js:3:14) at Object.<anonymous> (c:\VSCode\data\extensions\pycom.pymakr-1.1.0\pymakr.js:137:3) at Module.t._initNodeRequire.r._compile (c:\VSCode\resources\app\out\vs\loader.js:16:90) at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10) at Module.load (internal/modules/cjs/loader.js:620:32) at tryModuleLoad (internal/modules/cjs/loader.js:559:12) at Function.Module._load (internal/modules/cjs/loader.js:551:3) at Function.t._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:729:537) at Function.t.getExtensionPathIndex.then.a._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:691:639) at Function.t.getExtensionPathIndex.then.r._load (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:655:197) at Module.require (internal/modules/cjs/loader.js:658:17) at require (internal/modules/cjs/helpers.js:20:18) at Function.i [as __$__nodeRequire] (c:\VSCode\resources\app\out\vs\loader.js:31:542) at c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:717:918 at E._doActivateExtension (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:718:2) at E._activateExtension (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:716:772) at E.<anonymous> (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:714:224) at Generator.next (<anonymous>) at n (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:11:176) at new Promise (<anonymous>) at n (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:10:975) at Object.actualActivateExtension (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:713:946) at p._activateExtension (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:457:765) at define._activateExtensions.i.length.Promise.all.o.map.e (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:457:449) at Array.map (<anonymous>) at p._activateExtensions (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:457:437) at p.activateById (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:455:604) at E._activateById (c:\VSCode\resources\app\out\vs\workbench\services\extensions\node\extensionHostProcess.js:715:497)
When the console connects to the board, you cannot type anything (such as help() )
Please advise
Could you change the version numbering from 1.0.7
to 1.7.0
please ?
ie use the <Major>.<Minor>.<Patch>
schema .
That would allow me and other co-authors to use increasing patch numbers ( ie 1.7.1 … 1.7.99
, and still automatically get updated when there is a pycom release of a next <Minor>
version i.e. 1.8.0
.
In addition it may help aligning the Major & Minor version numbers between VSCode and Atom Add-ins.
/jos
Issue Type: Bug
Start : working environment with pymakr
VSCode updates to 1.31.0
After update pymakr addin does not work anymore
any attempt to use results in an error such as:
command 'pymakr.listCommands' not found
Tried :
see also : microsoft/vscode#68230
Extension version: 1.0.5
VS Code version: Code 1.31.0 (7c66f58312b48ed8ca4e387ebd9ffe9605332caa, 2019-02-05T22:35:56.624Z)
OS version: Windows_NT x64 10.0.17763
Item | Value |
---|---|
CPUs | Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz (8 x 2112) |
GPU Status | 2d_canvas: enabled checker_imaging: disabled_off flash_3d: enabled flash_stage3d: enabled flash_stage3d_baseline: enabled gpu_compositing: enabled multiple_raster_threads: enabled_on native_gpu_memory_buffers: disabled_software rasterization: enabled surface_synchronization: enabled_on video_decode: enabled webgl: enabled webgl2: enabled |
Memory (System) | 15.93GB (6.54GB free) |
Process Argv | |
Screen Reader | no |
VM | 0% |
Store the global settings in a recommended location or settings file as recommended here.
https://code.visualstudio.com/updates/v1_31#_global-storage-path
Allow a lines of code , or a block of code to be set to the board for execution,
similar to the Ctrl-Enter shortcut in VSCode + Python
-Assign keybinding ( Ctrl-Enter / Ctrl-Shift-L or something)
if the cursor is on a line
send that line to the board
execute the code
put focus back in the editor
if a block is selected
send that block to the board ( must use paste-mode)
execute the code
put focus back in the editor
this would allow a developer to test single lines, or block of code ,
and effectively single-step though a piece of code by running it line by line
as a further enhancement, extraneous indentation could be removed to allow running if sub-sections of indented code
Copy and Paste from the editor to the terminal is possible , but error prone
this is not an effective workflow
If you can, explain how users will be able to use this and possibly write out a version the docs. Maybe a screenshot or design?
I have sample working code in master...Josverl:RunByLine
https://code.visualstudio.com/docs/editor/intellisense / https://code.visualstudio.com/docs/python/linting also for modules/classes from the MicroPython and Pycom libraries. Without code completion / linting everything has to be looked up in the docs and even simple mistakes are not highlighted by vsc as they normally would be via pylint.
Maybe this can be done with a venv where the pycom modules/classes are imported/installed so that they are found by the vsc Python extension. I also found https://github.com/Josverl/micropython-stubber which can be used/extended for this.
Each time I run Visual Studio Code I get the following error message now:
There was an error with your serialport module, Pymakr will likely not work properly. Please try to install again or report an issue on our github (see developer console for details)
Vs Code details are:
Version: 1.36.0 (user setup)
Commit: 0f3794b38477eea13fb47fbe15a42798e6129338
Date: 2019-07-03T13:25:46.372Z
Electron: 4.2.5
Chrome: 69.0.3497.128
Node.js: 10.11.0
V8: 6.9.427.31-electron.0
OS: Windows_NT x64 10.0.17134
Pymakr: 1.1.2
I've tried uninstalling and reinstalling previous versions but that just removes the error and pymakr doesn't load.
( observed on windows , not sure on other platforms)
The package has a lot of unneeded build , documentation and source files included.
There is a lot of room that can be won by not including these
I addition the installation and startup seem to go significantly quicker if the /src folder is not included.
I have not timed this , but anecdotally sometimes Pymakr install can take 10-15 minutes , and it is down to <30 seconds with a reduced package ( but then I had excluded too much , so need to find the optimum )
However it is not quite clear (to me) which files to include / exclude from the packaging process.
Include:
Exclude:
use .vscodeignore
to exclude the unneeded files and folders
.vscode/**
.vscode-test/**
test/**
src/**
.gitignore
jsconfig.json
vsc-extension-quickstart.md
.eslintrc.json
but I have not been able to find the optimum as I do not quite understand the loading strategy for the serial / terminal.
.vscodeignore
You can create a .vscodeignore file to exclude some files from being included in your extension's package. This file is a collection of glob patterns, one per line.
For example:
**/*.ts
**/tsconfig.json
!file.ts
You should ignore all files not needed at runtime. For example, if your extension is written in TypeScript, you should ignore all **/*.ts files, like in the previous example.
Note: Development dependencies listed in devDependencies will be automatically ignored, you don't need to add them to the .vscodeignore file.
just noticed that 'vsce package' also throws a warning :
C:\develop\pymakr-vsc>vsce package
This extension consists of 5923 separate files. For performance reasons, you should bundle your extension: https://aka.ms/vscode-bundle-extension
DONE Packaged: C:\develop\pymakr-vsc\pymakr-1.0.7.vsix (5923 files, 18.89MB)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.