@devbisme, I think Kicost is a great tool for open source designers and I commend your efforts in creating it. I can’t wait to use it. But I seem to be running into some issues running it. I am not extremely savvy in Linux, but I can normally get by.
I have Kicost 0.21 installed in Ubuntu 14.04 and I have python 2.7.6 installed. I ran easy_install -U kicost to ensure there wasn’t any new code that has been pushed recently to fix any problems and it claims 0.21 is the latest version of Kicost.
I ran kicost -s -i schematic.xml and got the following error printout:
lance@ubuntu:~/Desktop$ kicost -s -i MotorDriverRev5.xml
No handlers could be found for logger "kicost"
Traceback (most recent call last):
File "/usr/local/bin/kicost", line 9, in <module>
load_entry_point('kicost==0.1.21', 'console_scripts', 'kicost')()
File "/usr/local/lib/python2.7/dist-packages/kicost-0.1.21-py2.7.egg/kicost/__main__.py", line 132, in main
num_processes=num_processes)
File "/usr/local/lib/python2.7/dist-packages/kicost-0.1.21-py2.7.egg/kicost/kicost.py", line 124, in kicost
id, url, part_num, price_tiers, qty_avail = scrape_part(args)
File "/usr/local/lib/python2.7/dist-packages/kicost-0.1.21-py2.7.egg/kicost/kicost.py", line 1779, in scrape_part
html_tree, url[d] = get_part_html_tree(part, d, distributor_dict, local_html)
File "/usr/local/lib/python2.7/dist-packages/kicost-0.1.21-py2.7.egg/kicost/kicost.py", line 1753, in get_part_html_tree
return get_dist_part_html_tree(dist, part.fields[key], extra_search_terms)
File "/usr/local/lib/python2.7/dist-packages/kicost-0.1.21-py2.7.egg/kicost/kicost.py", line 1666, in get_newark_part_html_tree
tree = BeautifulSoup(html, 'lxml')
File "build/bdist.linux-x86_64/egg/bs4/__init__.py", line 212, in __init__
File "build/bdist.linux-x86_64/egg/bs4/builder/_lxml.py", line 109, in prepare_markup
File "build/bdist.linux-x86_64/egg/bs4/dammit.py", line 263, in encodings
File "build/bdist.linux-x86_64/egg/bs4/dammit.py", line 33, in chardet_dammit
File "/usr/lib/python2.7/dist-packages/chardet/__init__.py", line 24, in detect
u.feed(aBuf)
File "/usr/lib/python2.7/dist-packages/chardet/universaldetector.py", line 115, in feed
if prober.feed(aBuf) == constants.eFoundIt:
File "/usr/lib/python2.7/dist-packages/chardet/charsetgroupprober.py", line 59, in feed
st = prober.feed(aBuf)
File "/usr/lib/python2.7/dist-packages/chardet/utf8prober.py", line 52, in feed
codingState = self._mCodingSM.next_state(c)
File "/usr/lib/python2.7/dist-packages/chardet/codingstatemachine.py", line 43, in next_state
byteCls = self._mModel['classTable'][ord(c)]
TypeError: ord() expected string of length 1, but int found
Any insight into what I am doing wrong here? Some of my parts don’t have manf# fields, I was just trying to test it out for a few parts to start with.
Thanks!
EDIT
I am also running Ubuntu inside a VM, I highly doubt that is an issue but figured it was worth noting.