KiBoM icon indicating copy to clipboard operation
KiBoM copied to clipboard

No Output KiCad 5.1.8

Open BewilderedAgain opened this issue 4 years ago • 2 comments

Looks like it's running but no output files are generated.

Run command: python "C:\Program Files\KiBoM-master/KiBOM_CLI.py" "Z:\bmamps\Projects\MIDI_Clock\Pulse_Rx_TR330_#1C\Pulse_Rx_TR330.xml" "Z:/bmamps/Projects/MIDI_Clock/Pulse_Rx_TR330_#1C/Pulse_Rx_TR330.pdf"

Success Info messages: KiBOM version 1.8.0 Output directory: 'Z:\bmxmps\Projects\MIDI_Clock\Pulse_Rx_TR330_#1C' Input: Z:\bmxmps\Projects\MIDI_Clock\Pulse_Rx_TR330_#1C\Pulse_Rx_TR330.xml Configuration file: Z:\bmxmps\Projects\MIDI_Clock\Pulse_Rx_TR330_#1C\bom.ini PCB variant: [u'default'] Saving BOM File: Z:\bmxmps\Projects\MIDI_Clock\Pulse_Rx_TR330_#1C\Pulse_Rx_TR330_bom_A.csv

More testing suggests it doesn't support network drives using samba. Pity as that's central to my workflow.

BewilderedAgain avatar Dec 23 '20 22:12 BewilderedAgain

A bit more info...

I've made an attempt to find out what is happening with my very limited Python knowledge.

I made an edit to csv_writer to let me know if the csv file was opened without error, it was. A few lines later, writer.writerow() fails with a file closed error message. Is the problem that there needs to be some delay between opening and writing if it's to a file that's located on a drive using Samba?

My code at line 39 of csv_writer.py :

 if (sys.version_info[0] >= 3):
        with open(filename,"w", encoding='utf-8') as f:
            try:
                print("open() OK")                
            except:
                print("open() error")
    else:
        f = open(filename, "w")

    writer = csv.writer(f, delimiter=delimiter, lineterminator="\n")

    if not prefs.hideHeaders:
        if prefs.numberRows:
            writer.writerow(["Component"] + headings)
        else:
            writer.writerow(headings)

BewilderedAgain avatar Dec 24 '20 19:12 BewilderedAgain

I have a fix. This applies to Win 10 users. You need to enable NetBIOS. Instructions thanks to Ed Tittel

  1. Type “net” into the search box, then click on Network and Sharing Center.
  2. Click on the network interface you use to access the network (for this PC, it’s the Ethernet connection; on most laptops it will be a wireless interface of some kind).
  3. On Ethernet Status, click properties.
  4. In Ethernet Properties, click Internet Protocol Version 4 (TCP/IPv4), then Properties.
  5. In Internet Protocol Version 4 (TCP/IPv4) Properties, click the Advanced button.
  6. In Advanced TCP/IP Settings, click the WINS tab. This produces the window shown above, where you’ll want to click the “Enable NetBIOS over TCP/IP” radio button.

Hope this helps others.

BewilderedAgain avatar Dec 24 '20 22:12 BewilderedAgain