When I try to run an excel workbook in office 2016, i get the following error message:
sh: /usr/local/bin/python3.4/python: Not a directory
It work's in 2011 - what is wrong? Please see details below:
xlwings: 0.7,
Office: 2016,
OS: Mac,
PYTHON_MAC = "/usr/local/bin/python3.4"
That's currently a bug really, as PYTHON_MAC should accept the path including the interpreter instead of the path only, see here.
Update: This has been fixed with the release of v0.7.1
Related
I am using Django 11.4 on Windows 10 and I am having problems when I try and migrate my models. I receive this error:
django.core.exceptions.ImproperlyConfigured: Could not find the GDAL library (tried "gdal201", "gdal20", "gdal111", "gdal110", "gdal19")
I followed GeoDjango's installation instructions (https://docs.djangoproject.com/en/1.11/ref/contrib/gis/install/), but I am still having trouble. Everything I have found on this error says to change the system environment variables.
I installed OSGe4W and added GDAL_DATA = C:\OSGeo4W\share\gdal as well as PROJ_LIB= C:\OSGeo4W\share\proj.
I am not sure what else to try and I would appreciate any more insight.
I fixed this by editing the libgdal.py file in %PYTHONPATH%\Lib\site-packages\django\contrib\gis\gdal and adding str('gdal202') to line 26 so it reads:
lib_names = [str('gdal201'), str('gdal202'), str('gdal111'), str('gdal110'), str('gdal19')]
Depending on what version of GDAL you are using, you may need to add a different version number.
I had the same problem, and for me the issue was I had started my cmd shell before updating the PATH environment variable used to search for the GDAL library. I just had to restart my shell and everything worked.
After trying many solutions, including reinstalling, adding to paths etc, I found this relatively simple solution which worked for me.
https://stackoverflow.com/a/49159195/3768552
This solution works 100%. Try this if you haven't yet.
First, download the GDAL wheel from Christoph Gohlke's Unofficial Windows Binaries for Python Extension Packages.
Make sure to check your python version by opening python in terminal.
You will see an output like this :
Python 3.8.5 (tags/v3.8.5:580fbb0, Jul 20 2020, 15:43:08) [MSC v.1926 32 bit (Intel)] on win32
Type "help", "copyright", "credits" or "license" for more information.
In the above lines the python version is 3.8.5 and its on 32 bit. So the package that I will have to choose from the link will be 'GDAL-3.3.3-cp38-cp38-win32.whl'. You should choose yours similarly.
After you do that just run
pip install whl/GDAL-3.3.3-cp38-cp38-win32.whl
After installling GDAL. Paste the following code into your settings.py file
import os
if os.name == 'nt':
VENV_BASE = os.environ['VIRTUAL_ENV']
os.environ['PATH'] = os.path.join(VENV_BASE, 'Lib\\site-packages\\osgeo') + ';' + os.environ['PATH']
os.environ['PROJ_LIB'] = os.path.join(VENV_BASE, 'Lib\\site-packages\\osgeo\\data\\proj') + ';' + os.environ['PATH']
AND you are good to go.
I have been trying to connect with a MySql database using Wt::Dbo::backend::MySQL latest version Wt-3.3.5 but I keep getting the error:
"MySQL error performing query: 'SET storage_engine=INNODB;': Unknown system variable 'storage_engine'"
MySql is running on windows 7, with latest version MySql Server 5.7.10.
I have tried to execute:
SET storage_engine=INNODB;
in the MySql command line and of course get the same Unknown system variable 'storage_engine'". The command that does work is:
SET default_storage_engine=INNODB;
Does this means Wt::Dbo::backend::MySQL does not support this version of MySql? I could not find anything on their documentation nor the internet.
Thanks,
I have found in the following links that indeed the variable "storage_engine" has been renamed to "default_storage_engine", which has caused some software to start getting issues with recent versions of MySql.
https://dba.stackexchange.com/questions/101908/migrate-jira-to-mysql-unknown-system-variable-storage-engine
https://confluence.atlassian.com/display/CONFKB/Confluence+fails+to+start+with+error+'Unknown+system+variable+'storage_engine''+using+MySQL+5.7.x
There are to possible solutions:
1) Change Wt::Dbo source by modifying the file "MySQL.C" around line 980 in function :
void MySQL::init()
{
executeSql("SET sql_mode='ANSI_QUOTES,REAL_AS_FLOAT'");
executeSql("SET storage_engine=INNODB;");
executeSql("SET NAMES 'utf8';");
}
By first somehow testing first which MySql version the server has and then SET the "default_storage_engine" variable instead "storage_engine". And then recompile the full Wt::Dbo library.
OR
2) Go back to the most recent version of MySql in which the variable "storage_engine" has not yet been renamed.
I opted for solution 2 and uninstalled MySql 5.7 and installed MySql 5.4 and now everything works just fine.
Hope this helps somebody out there... cheers!
I am about to begin a project with Shiny (by RStudio). When I try to install the shiny package using the console install.packages("shiny"), I get the following error message:
trying URL 'http://cran.rstudio.com/bin/macosx/mavericks/contrib/3.1/shiny_0.10.1.tgz'
Warning in install.packages :
cannot open: HTTP status was '404 Not Found'
Error in download.file(url, destfile, method, mode = "wb", ...) :
cannot open URL'http://cran.rstudio.com/bin/macosx/mavericks/contrib/3.1/shiny_0.10.1.tgz'
Warning in install.packages :
download of package ‘shiny’ failed
I have tried to install it from the drop down menu in RStudio but have encountered the same problem. Any thoughts as to what is going on?
I am working on Mac, with the latest version of Mavericks (R version is 3.1.1).
Thanks,
Brian
Try a different CRAN mirror. The error indicates that the file was not found on the CRAN server
chooseCRANmirror()
shiny has just been updated 2014-10-01 so the changes may not have propagated down to all mirrors yet.
I am trying to learn winpdb to debug django scripts. I have a very simply django web site that runs find if I start it from the command line, but when I try to launch it from winpdb it gives me this error message:
RPDB2 - The Remote Python Debugger, version RPDB_2_4_6,
Copyright (C) 2005-2009 Nir Aides.
Type "help", "copyright", "license", "credits" for more information.
*** NEW: Use CTRL-N for auto completion in the following commands: launch,
*** eval and exec.
*** Password has been set to a random password.
*** Starting debuggee...
*** Command returned the following error:
*** <type 'exceptions.AttributeError'>, CTimeoutHTTP instance has no
*** attribute 'getresponse'.
*** Please check stderr for stack trace and report to support.
*** Failed to find script.
I don't even know where to start fixing this. It CTimeoutHTTP looks like an MFC thing. I installed wxpython with the ANSI version, then when it complained, I installed the unicode version (without removing the ANSI version.) That is the only unusual thing I can think of. Any help would be appreciated.
I should say, running on Windows XP.
Fixed in Winpdb 1.4.8
This seems to be a bug with rpdb2 in Python 2.7. Try downloading Python 2.6 and running winpdb against that. You'll need the appropriate wxPython library and you'll need to re-run:
python setup.py install -f
to install winpdb.
I also had this exact same error. I upgraded from Winpdb 1.4.6 to 1.4.8 as suggested by nir above and no longer see it (can't vote his answer up as I'm a new user).
I'm new to Macs (and quite new to Django) and I'm setting up an existing Django/MySQL site that uses Mercurial as a site package, on a new Macbook Pro.
All was going well during installation - no error messages. I installed the default versions of most packages from macports.
However when I try runserver, localhost shows the following error message:
ImportError at /
.../lib/python2.6/site-packages/mercurial/osutil.so: no appropriate 64-bit architecture (see "man python" for running in 32-bit mode)
Please could anyone advise? I've tried typing the following at the terminal:
defaults write com.apple.versioner.python Prefer-32-Bit -bool yes
but it didn't help.
I've gotten a similar error and a combination of two things helped me install Mercurial for OS X Lion. I'm running OS X 10.7.3.
First, there is a bug on line 455 of the setup.py script (at least for Mercurial 2.2.1, the version I tried). The line
version = runcmd(['/usr/bin/xcodebuild', '-version'], {})[0].splitlines()
should be replaced with
version = runcmd(['/usr/bin/xcodebuild', '-version'], {})[0]
Second, after I installed Mercurial (either by easy_install, Mac OS X binary installer, and compilation), I kept getting the following error message:
ImportError: dlopen(/Library/Python/2.7/site-packages/mercurial/osutil.so, 2): no suitable image found. Did find: /Library/Python/2.7/site-packages/mercurial/osutil.so: mach-o, but wrong architecture
However, after seeing this post, I noticed that
defaults read com.apple.versioner.python Prefer-32-Bit
outputs 1 on my system. However, running this command
defaults write com.apple.versioner.python Prefer-32-Bit -bool no
and then recompiling / installing mercurial resulted in a working executable for me at the end.
If everything from my comment checks out, try setting that Prefer-32-bit in an user environment variable instead of at the command line.
Edit this file: ~/.MacOSX/environment.plist
See:
http://developer.apple.com/mac/library/documentation/MacOSX/Conceptual/BPRuntimeConfig/Articles/EnvironmentVars.html#//apple_ref/doc/uid/20002093-113982