Comments (20)
I've submitted a PR to the teardrops plugin repo NilujePerchut/kicad_scripts#34
That will fix the problem.
If you don't want to wait, simple remove this line https://github.com/NilujePerchut/kicad_scripts/blob/master/teardrops/td.py#L107
from kicad-jlcpcb-tools.
@NilujePerchut merged my PR so i concider this issue resolved. Please reopen if not!
from kicad-jlcpcb-tools.
@HaydenHu How did you install the Plugin?
Please open the terminal in KiCad before you start the plugin:
This will give you a stdout/stderr windows if something unusual happens.
Please post another picture after you've done that, maybe I can see from that whats wrong.
from kicad-jlcpcb-tools.
I just deleted the plugin here and installed it via git clone
and again via downloading the zip file and both times it worked right out of the box!?
Maybe the URl is blocked? Can you open https://jlcpcb.com/componentSearch/uploadComponentInfo in a browser and see if a CSV gets downloaded?
from kicad-jlcpcb-tools.
I just deleted the plugin here and installed it via
git clone
and again via downloading the zip file and both times it worked right out of the box!?Maybe the URl is blocked? Can you open https://jlcpcb.com/componentSearch/uploadComponentInfo in a browser and see if a CSV gets downloaded?
I did what you said, opened the console and ran the plugin, and everything worked.
Do I need to open the console every time I launch a plug-in?
from kicad-jlcpcb-tools.
No, that was not my intention, normally you can see errors in that windows that do not show up in the plugin.
So everythin works now even without the console open?
from kicad-jlcpcb-tools.
No, that was not my intention, normally you can see errors in that windows that do not show up in the plugin. So everythin works now even without the console open?
If I don't open the console before running the plug-in, it won't work as I described
from kicad-jlcpcb-tools.
Thats very strange! Do you get a second window besides the console like this:
from kicad-jlcpcb-tools.
Thats very strange! Do you get a second window besides the console like this:
22-43-01.mp4
from kicad-jlcpcb-tools.
Thats wild, You don't see the 3 messages that usually come up first 🤔
I know that I hat trouble when using the plugin together with the KiBuzzard plugin.
Maybe its some kind of interference with one of the many plugins you've installed.
Can you provide a list of you plugin so that I can try to reproduce it?
from kicad-jlcpcb-tools.
太疯狂了,您看不到通常最先出现的 3 条消息 🤔 我知道将插件与 KiBuzzard 插件一起使用时会遇到麻烦。 也许它对您安装的众多插件之一造成了某种干扰。 您能否提供您的插件列表,以便我可以尝试重现它?
https://www.lanzouw.com/inkNDvmj20j
Application: KiCad (64-bit)
Version: (5.99.0-12889-g70df3822b5), release build
Libraries:
wxWidgets 3.1.5
libcurl/7.78.0-DEV Schannel zlib/1.2.11
Platform: Windows 10 (build 19043), 64-bit edition, 64 bit, Little endian, wxMSW
Build Info:
Date: Oct 20 2021 12:00:27
wxWidgets: 3.1.5 (wchar_t,wx containers)
Boost: 1.76.0
OCC: 7.5.0
Curl: 7.78.0-DEV
ngspice: 35
Compiler: Visual C++ 1929 without C++ ABI
Build settings:
KICAD_USE_OCC=ON
KICAD_SPICE=ON
from kicad-jlcpcb-tools.
Ok, here's what I have installed:
Application: KiCad (64-bit)
Version: (5.99.0-12896-g1860893d63), release build
Libraries:
wxWidgets 3.1.5
libcurl/7.78.0-DEV Schannel zlib/1.2.11
Platform: Windows 10 (build 19043), 64-bit edition, 64 bit, Little endian, wxMSW
Build Info:
Date: Oct 21 2021 12:00:08
wxWidgets: 3.1.5 (wchar_t,wx containers)
Boost: 1.76.0
OCC: 7.5.0
Curl: 7.78.0-DEV
ngspice: 35
Compiler: Visual C++ 1929 without C++ ABI
Build settings:
KICAD_USE_OCC=ON
KICAD_SPICE=ON
Ok, I figured out that it is some sort of collision between KiBuzzard and this plugin!
If I delete KiBuzzard from the plugin folder, kicad-jlcpcb-tools works as expected.
I think its the way how both plugins try to redirect stdout/stderr that causes this problem.
from kicad-jlcpcb-tools.
Ok, its defenitely caused by some sort of issue between the way kicad-jlcpcb-tools and KiBuzzard setup their loggers.
Maybe I can figure out whats going on here and provide a fix!
from kicad-jlcpcb-tools.
Ok, its defenitely the way logging is handled by KiBuzzard that prevents kicad-jlcpcb-tools from working properly!
I filed an issue over there gregdavill/KiBuzzard#57 in order to find a way both plugins can work side by side.
In the meantime you can replace the logging in KiBuzzard-main\KiBuzzard\plugin.py
(https://github.com/gregdavill/KiBuzzard/blob/main/KiBuzzard/plugin.py#L105-L142) with this:
def InitLogger(self):
root = logging.getLogger()
root.setLevel(logging.DEBUG)
# Log to stderr
handler1 = logging.StreamHandler(sys.stderr)
handler1.setLevel(logging.DEBUG)
log_file = os.path.join(os.path.dirname(__file__), "..", "kibuzzard.log")
# and to our error file
handler2 = logging.FileHandler(log_file)
handler2.setLevel(logging.DEBUG)
formatter = logging.Formatter(
"%(asctime)s %(name)s %(lineno)d:%(message)s", datefmt="%m-%d %H:%M:%S"
)
handler1.setFormatter(formatter)
handler2.setFormatter(formatter)
root.addHandler(handler1)
root.addHandler(handler2)
That way both plugins seem to work properly
from kicad-jlcpcb-tools.
@HaydenHu The author of KiBuzzard updated his plugin with a fix for this issue. Please update and test if the issue is solved with this!
from kicad-jlcpcb-tools.
Ok, its defenitely the way logging is handled by KiBuzzard that prevents kicad-jlcpcb-tools from working properly! I filed an issue over there gregdavill/KiBuzzard#57 in order to find a way both plugins can work side by side. In the meantime you can replace the logging in
KiBuzzard-main\KiBuzzard\plugin.py
(https://github.com/gregdavill/KiBuzzard/blob/main/KiBuzzard/plugin.py#L105-L142) with this:def InitLogger(self): root = logging.getLogger() root.setLevel(logging.DEBUG) # Log to stderr handler1 = logging.StreamHandler(sys.stderr) handler1.setLevel(logging.DEBUG) log_file = os.path.join(os.path.dirname(__file__), "..", "kibuzzard.log") # and to our error file handler2 = logging.FileHandler(log_file) handler2.setLevel(logging.DEBUG) formatter = logging.Formatter( "%(asctime)s %(name)s %(lineno)d:%(message)s", datefmt="%m-%d %H:%M:%S" ) handler1.setFormatter(formatter) handler2.setFormatter(formatter) root.addHandler(handler1) root.addHandler(handler2)That way both plugins seem to work properly
The Teardrop plugin won't work after using your code
from kicad-jlcpcb-tools.
Ok, I'll dig into that as well 😬
from kicad-jlcpcb-tools.
Ok, If I start the python shell before the teardrops plugin and the try to use it I get this:
\plugins\kicad_scripts-master\teardrops\td.py", line 116, in __Zone
sys.stdout.write("+")
AttributeError: 'NoneType' object has no attribute 'write'
If I remove kicad-jlcpcb-tools from my plugins folder, the issue stays the same, if I remove KiBuzzard as well, still the same issue.
But If I add the old version of KiBuzzard (before @gregdavill refactored the logging) it works again.
I guess that the author of the teardrops plugin had KiBuzzard installed during the development of the teardrops plugin and therefore sys.stdout.write("+")
worked.
The reson is that Greg redirected stderr / stdout to his logger
The call to sys.stdout.write
ends up in kibuzzard.log
10-25 09:18:25 STDOUT 153:Starting plugin ViaStitching
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:+
10-25 09:18:32 STDOUT 153:47 teardrops inserted
from kicad-jlcpcb-tools.
@HaydenHu I would highly appreciate if you could verify that this solves your problem so that I can cloase this issue.
from kicad-jlcpcb-tools.
Everything is back to normal. Perfect!
from kicad-jlcpcb-tools.
Related Issues (20)
- Center finding not accurate due to silk screen HOT 4
- Price column is a mess HOT 6
- Error downloading database HOT 3
- Ability to download and link LCSC datasheet HOT 8
- Instructions, Required Fields on Schematic, Example Projects HOT 3
- How can you search JLCPCB from EESchema? HOT 2
- Schematic doesn't get updated HOT 2
- The price list issue is NOT closed ro solved HOT 1
- Occasional components shift / FP anchor not honored? HOT 3
- Selecting a part in the footprint list should select the part in the pcbnew window HOT 1
- plugin crashes on KiCAD 7 HOT 2
- Announcement: KiCAD version support
- TypeError: 'FOOTPRINT' object is not iterable HOT 1
- Filename containing "." is not correctly processed HOT 7
- Assign LCSC number not working HOT 3
- Placement offsets for parts HOT 1
- Rotation override by component property HOT 4
- Mass export part details to schematic/external file HOT 1
- KiCAD 8.0 Failed to download JLCPCB DB HOT 5
- Unknown Image Data Format Error when opening Part Details HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from kicad-jlcpcb-tools.