A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from http://mail.python.org/pipermail/python-list/2005-September/320806.html below:

error processing variables

error processing variables error processing variablesinfidel saint.infidel at gmail.com
Fri Sep 9 18:10:36 EDT 2005
> import shutil
>
> #variables
> s = shutil
>
> toHPU = "/etc/sysconfig/network/toHPU.wifi"
> wlan = "/etc/sysconfig/network/ifcfg-wlan-id-00:0e:38:88:ba:6d"
> toAnyWifi = "/etc/sysconfig/network/toAny.wifi"
> wired = "/etc/sysconfig/network/ifcfg-eth-id-00:0b:db:1b:e3:88"
>
>
> def toHPU():
>
>
>     s.copy2(toHPU,wlan)
>     s.copy2(toAnyWifi,wired)
>
> #end
>
> #execute function
> toHPU()

Your problem is that the def statement reassignes the name "toHPU" to a
function instead of a string.  So when the code runs, you're passing a
function object to s.copy2.


More information about the Python-list mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4