Go to Post Don't like it? Then lets change the culture. - Barry Bonzack [more]
Home
Go Back   Chief Delphi > Technical > Programming > Python
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 10-01-2017, 00:07
acastagna acastagna is offline
Registered User
FRC #1493
 
Join Date: Jan 2012
Location: Albany High School
Posts: 38
acastagna is an unknown quantity at this point
error installing robotpy

My team has just started exploring the use of python and we are having some trouble installing robotpy on our PC (windows 10). We have installed python3.6 and pyfrc, and imaged the roborio without any issues. We downloaded the zipped robotpy file from GitHub, extracted the file, and used py -3 installer.py install-robotpy as specified in the robotpy documentation. That gives us the following error. An online search suggests an encoding issue. Does anyone have any suggestions on where to go from here?

Code:
C:\Users\falcons1493\robotpy\robotpy-2017.0.0>  py -3 installer.py install-robotpy
Traceback (most recent call last):
  File "installer.py", line 1010, in <module>
    retval = main()
  File "installer.py", line 991, in main
    retval = options.cmdobj(options)
  File "installer.py", line 751, in install_robotpy
    self.install_opkg(opkg_options)
  File "installer.py", line 798, in install_opkg
    opkg = self._get_opkg()
  File "installer.py", line 676, in _get_opkg
    opkg.add_feed("http://download.ni.com/ni-linux-rt/feeds/2016/arm/ipk/cortexa9-vfpv3")
  File "installer.py", line 93, in add_feed
    self.load_package_db(feed)
  File "installer.py", line 107, in load_package_db
    for line in fp.readlines():
  File "C:\Program Files\Python36\lib\encodings\cp1252.py", line 23, in decode
    return codecs.charmap_decode(input,self.errors,decoding_table)[0]
UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 7516: character maps to <undefined>
Reply With Quote
  #2   Spotlight this post!  
Unread 10-01-2017, 00:38
TimTheGreat's Avatar
TimTheGreat TimTheGreat is offline
ArchdukeTim
FRC #1418 (Vae Victis)
Team Role: Programmer
 
Join Date: Jan 2013
Rookie Year: 2011
Location: Falls Church
Posts: 238
TimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura aboutTimTheGreat has a spectacular aura about
Re: error installing robotpy

An update was just released for pyfrc. Update it. You may run into another error about python36. I believe an update for that is coming out tonight.
__________________
There are two ways of constructing a software design: One way is to make it so simple that there are obviously no deficiencies, and the other way is to make it so complicated that there are no obvious deficiencies. The first method is far more difficult.



2012 - Gracious Professionalism - Greater DC
2014 - Regional Finalist - Virginia | Industrial Design - Virginia | Regional Finalist - Greater DC
2015 - Innovation in Control - Greater DC
2016 - District Event Winner - VAHAY | Innovation in Control - VAHAY | District Event Winner - MDBET | Industrial Design - MDBET | District Champion - CHCMP | Innovation in Control - CHCMP
Reply With Quote
  #3   Spotlight this post!  
Unread 10-01-2017, 07:06
vScourge's Avatar
vScourge vScourge is offline
Videogame Developer
AKA: Adam Pletcher
FRC #4096 (Ctrl-Z)
Team Role: Coach
 
Join Date: Jan 2014
Rookie Year: 2012
Location: Champaign, IL
Posts: 42
vScourge will become famous soon enough
Re: error installing robotpy

https://github.com/robotpy/robotpy-wpilib/issues/246
Reply With Quote
  #4   Spotlight this post!  
Unread 10-01-2017, 10:28
virtuald's Avatar
virtuald virtuald is online now
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,102
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: error installing robotpy

The bug is fixed in RobotPy 2017.0.1, sorry for the inconvenience.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
Reply With Quote
  #5   Spotlight this post!  
Unread 10-01-2017, 10:35
acastagna acastagna is offline
Registered User
FRC #1493
 
Join Date: Jan 2012
Location: Albany High School
Posts: 38
acastagna is an unknown quantity at this point
Re: error installing robotpy

Thank you!
I'll trying update it tonight.
Reply With Quote
  #6   Spotlight this post!  
Unread 11-01-2017, 00:03
acastagna acastagna is offline
Registered User
FRC #1493
 
Join Date: Jan 2012
Location: Albany High School
Posts: 38
acastagna is an unknown quantity at this point
Re: error installing robotpy

I can now run python code on the roborio using the command line to deploy.

If I use eclipse as my IDE can I deploy directly from there? When I try a "Run As/Python Deploy" the following error occurs:

Unexpected error
Illegal character in path at index 16: file:/C:/Program Files/eclipse-java-neon-1a-win32-x86_64/eclipse/configuration/org.eclipse.osgi/494/0/.cp/resources/py/preexec.py

Am I missing something in the setup for eclipse?
Reply With Quote
  #7   Spotlight this post!  
Unread 11-01-2017, 00:18
virtuald's Avatar
virtuald virtuald is online now
RobotPy Guy
AKA: Dustin Spicuzza
FRC #1418 (), FRC #1973, FRC #4796, FRC #6367 ()
Team Role: Mentor
 
Join Date: Dec 2008
Rookie Year: 2003
Location: Boston, MA
Posts: 1,102
virtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant futurevirtuald has a brilliant future
Re: error installing robotpy

Quote:
Originally Posted by acastagna View Post
I can now run python code on the roborio using the command line to deploy.

If I use eclipse as my IDE can I deploy directly from there? When I try a "Run As/Python Deploy" the following error occurs:

Unexpected error
Illegal character in path at index 16: file:/C:/Program Files/eclipse-java-neon-1a-win32-x86_64/eclipse/configuration/org.eclipse.osgi/494/0/.cp/resources/py/preexec.py

Am I missing something in the setup for eclipse?
Are you using the RobotPy plugins for Eclipse? I should probably unpublish those... nobody really used them as far as I could tell, so I stopped updating them.

But yes, you can use Eclipse + Pydev + RobotPy. There's some documentation about using RobotPy with Eclipse + Pydev: http://robotpy.readthedocs.io/en/sta....html?#eclipse . I've been meaning to update the documentation, but been busy.
__________________
Maintainer of RobotPy - Python for FRC
Creator of pyfrc (Robot Simulator + utilities for Python) and pynetworktables/pynetworktables2js (NetworkTables for Python & Javascript)

2017 Season: Teams #1973, #4796, #6369
Team #1418 (remote mentor): Newton Quarterfinalists, 2016 Chesapeake District Champion, 2x Innovation in Control award, 2x district event winner
Team #1418: 2015 DC Regional Innovation In Control Award, #2 seed; 2014 VA Industrial Design Award; 2014 Finalists in DC & VA
Team #2423: 2012 & 2013 Boston Regional Innovation in Control Award


Resources: FIRSTWiki (relaunched!) | My Software Stuff
Reply With Quote
  #8   Spotlight this post!  
Unread 12-01-2017, 06:03
acastagna acastagna is offline
Registered User
FRC #1493
 
Join Date: Jan 2012
Location: Albany High School
Posts: 38
acastagna is an unknown quantity at this point
Re: error installing robotpy

Thank you - I was using the plug-ins and had missed the part in the documentation about the adding the deploy argument in the run configuration.

I guess I shouldn't be using the plug-ins if they are not updated. I had also installed pyfrc and robotpy on two other laptops which are running Window 8, and I found that I don't get the illegal character error on those machines.

What do teams using python use when programming - Eclipse, Idle, something else?
Reply With Quote
  #9   Spotlight this post!  
Unread 12-01-2017, 09:06
vScourge's Avatar
vScourge vScourge is offline
Videogame Developer
AKA: Adam Pletcher
FRC #4096 (Ctrl-Z)
Team Role: Coach
 
Join Date: Jan 2014
Rookie Year: 2012
Location: Champaign, IL
Posts: 42
vScourge will become famous soon enough
Re: error installing robotpy

We use Wing IDE. I'm a big fan of it, use it on my day job. It also has a nice scripting API and we were able to make a simple command to deploy code to the RoboRio, copy GRIP config files over SFTP, etc.
Reply With Quote
Reply


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 11:25.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi