--------------------调试bug C:\Python34\Lib\pdb.py里加上encoding="utf-8" with open(os.path.join(envHome, ".pdbrc"),encoding="utf-8") as rcFile: with open(".pdbrc",encoding="utf-8") as rcFile: --------------------install reaynas: apt-get install python3-pip{ python3 --version pip3 --version } apt-get install -y firefox-esr{ make_geckodriver.js } CentOS6 python3 install{ # yum install https://centos6.iuscommunity.org/ius-release.rpm # vi /etc/yum.repos.d/ius.repo ---- enabled=1 となっている箇所を変更 enabled=0 に変更 ---- # yum install --enablerepo=ius python35u python35u-libs python35u-devel python35u-pip # python --version <--元から入ってたやつ # python3.5 --version <--新規インストールしたやつ } windows install lib{ python -m pip install --upgrade pip python -m pip install requests python -m pip install selenium python -m pip install python-dateutil } build phantomjs{ CentOs6{ yum install gcc gcc-c++ make flex bison gperf ruby \ openssl-devel freetype-devel fontconfig-devel libicu-devel sqlite-devel \ libpng-devel libjpeg-devel git clone git://github.com/ariya/phantomjs.git cd phantomjs git checkout 2.1.1 git submodule init git submodule update python build.py & python build.py -c --git-clean-qtbase --git-clean-qtwebkit & } raspberrypi{ ----------------------------- uname -a lsb_release -a # ラズパイの仮想メモリの SWAP領域を 2GBに広げる sudo sed -i -e "s/^CONF_SWAPSIZE=.*/CONF_SWAPSIZE=2048/g" /etc/dphys-swapfile cat /etc/dphys-swapfile | grep CONF_SWAPSIZE sudo service dphys-swapfile restart # VRAMのサイズを 64MBから 16MBに減らす sudo bash -c "echo gpu_mem=16>> /boot/config.txt" sudo sed -i -e "s/^gpu_mem=.*/gpu_mem=16/g" /boot/config.txt # ラズパイの X Window Systemを無効化してメモリ使用量を減らす sudo systemctl set-default multi-user.target systemctl list-units | grep lightdm sudo systemctl disable lightdm # 緑色の ACT LEDの動作がハートビート(心臓の鼓動)になり一定間隔で点滅する。 # ハングした場合は点滅しなくなるので考えているのかハングしているのかの区別がつく。 sudo bash -c "echo dtparam=act_led_trigger=heartbeat >> /boot/config.txt" # 再起動で設定を反映させる sudo reboot ----------------------------- sudo apt-get update sudo apt-get -y install wget git build-essential g++ flex bison gperf ruby perl libsqlite3-dev libfontconfig1-dev libicu-dev libfreetype6 libssl1.0-dev libssl1.0.2 libpng-dev libjpeg-dev ----------------------------- cd git clone git://github.com/ariya/phantomjs.git -b 2.1.1 --single-branch --depth=1 cd phantomjs ----------------------------- git checkout 2.1.1 git fetch git submodule init git submodule update ----------------------------- date >BUILD_START time python ./build.py -c --jobs 2 date >BUILD_END cat BUILD_START cat BUILD_END } raspberrypi 4{ mount -v nas-27-59-FD:/data/tmp /media/netdir mount -v nas-27-59-FD:/data/tmp/raspbrreyPi/mnt_runimg /mnt/runimg sudo /home/pi/vdesktop/vdesktop /mnt/runimg/2019-04-08-raspbian-stretch.img mkdir /media/netdir/source/raspberrypi/4-3 mount --bind /media/netdir/source/raspberrypi/4-3 /mnt/virtualdesktop/mnt/compile cd /mnt/compile git clone git://github.com/ariya/phantomjs.git cd phantomjs git checkout 2.1.1 git submodule init git submodule update vi ./make_cmd.sh{ date > BUILD_START python ./build.py -c --release ##--git-clean-qtbase --git-clean-qtwebkit --jobs 2 date > BUILD_END } } apt-get update apt-get install -y python wget git build-essential fontconfig-config libfontconfig1 libfontconfig1-dev libicu-dev libssl-dev ruby gperf bison flex libsqlite3-dev libpng-dev libjpeg-dev root@nas-27-5A-1D:~# cat /usr/bin/gcc #!/bin/bash gcc-4.9 $* -mcpu=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard root@nas-27-5A-1D:~# root@nas-27-5A-1D:~# cat /usr/bin/g++ #!/bin/bash g++-4.9 $* -mcpu=cortex-a7 -mfpu=neon-vfpv4 -mfloat-abi=hard root@nas-27-5A-1D:~# phantomjs/src/qt/qtbase/mkspecs/common# vim gcc-base.conf --- QMAKE_CFLAGS += -pipe -mcpu=cortex-a7 --- python build.py } raspberrypi{ pip3 install requests selenium python-dateutil } error python3 mufg2.py{ -------------------------- root@nas-27-59-FD:/data/tmp/source/MUFJ# python3 mufg2.py /usr/local/lib/python3.4/dist-packages/selenium/webdriver/phantomjs/webdriver.py:49: UserWarning: Selenium support for PhantomJS has been deprecated, please use headless versions of Chrome or Firefox instead warnings.warn('Selenium support for PhantomJS has been deprecated, please use headless ' Traceback (most recent call last): File "mufg2.py", line 24, in driver = webdriver.PhantomJS( executable_path='./phantomjs' ) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/phantomjs/webdriver.py", line 62, in __init__ desired_capabilities=desired_capabilities) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/remote/webdriver.py", line 157, in __init__ self.start_session(capabilities, browser_profile) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/remote/webdriver.py", line 252, in start_session response = self.execute(Command.NEW_SESSION, parameters) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/remote/webdriver.py", line 319, in execute response = self.command_executor.execute(driver_command, params) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/remote/remote_connection.py", line 374, in execute return self._request(command_info[0], url, body=data) File "/usr/local/lib/python3.4/dist-packages/selenium/webdriver/remote/remote_connection.py", line 402, in _request resp = http.request(method, url, body=body, headers=headers) File "/usr/lib/python3/dist-packages/urllib3/request.py", line 72, in request **urlopen_kw) File "/usr/lib/python3/dist-packages/urllib3/request.py", line 135, in request_encode_body **urlopen_kw) TypeError: urlopen() got multiple values for keyword argument 'body' -----------------------------解决 pip3 install --upgrade --ignore-installed urllib3 } run in msys{ export ACCOUNT_ID=3593750555 export IB_PASSWORD=jin_129921 export BKLIST_PATH=/d/svn/nas-48-71-3b/Python/MUFJ export BKLIST_NAME=bank_list.txt export BKBOOK_NAME=bank_book.txt export BKLIST_PATH=D:\\svn\\nas-48-71-3b\\Python\\MUFJ TMP_PATH=${PATH} export PATH=/mingw32/bin:/d/svn/nas-48-71-3b/teraterm-4_86_vc2008/installer/make_js:/d/svn/nas-48-71-3b/Python/MUFJ:${TMP_PATH} winpty python3 mufg2.py }