Skip to content

fixing error codes for msql 5.7 #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 15, 2016
Merged

Conversation

markshiz
Copy link
Contributor

@jamestryan jamestryan merged commit e155573 into python-oursql:master May 15, 2016
@earwig
Copy link

earwig commented Jun 29, 2016

@jamestryan Hi, can this fix be ported over to the oursql3 package?

@PaulFurtado
Copy link

FYI: #6

@hemna
Copy link

hemna commented Oct 16, 2019

I'm hitting this with issue with oursql3.

Collecting oursql3
  Downloading https://files.pythonhosted.org/packages/cf/cc/0852697514aff8397ab5e5a579a72c9c53cc39dc6012f9a3667c519a593d/oursql3-0.9.4.tar.gz (189kB)
     |████████████████████████████████| 194kB 1.5MB/s
Building wheels for collected packages: oursql3
  Building wheel for oursql3 (setup.py) ... error
  ERROR: Command errored out with exit status 1:
   command: /home/waboring/devel/wx.hemna.com/.venv/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"'; __file__='"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-z9zivpos --python-tag cp36
       cwd: /tmp/pip-install-uw2rdqvx/oursql3/
  Complete output (23 lines):
  running bdist_wheel
  running build
  running build_ext
  skipping 'oursqlx/oursql.c' Cython extension (up-to-date)
  building 'oursql' extension
  mysql_config --cflags
  creating build
  creating build/temp.linux-x86_64-3.6
  creating build/temp.linux-x86_64-3.6/oursqlx
  x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.6m -I/home/waboring/devel/wx.hemna.com/.venv/include/python3.6m -c oursqlx/oursql.c -o build/temp.linux-x86_64-3.6/oursqlx/oursql.o -I/usr/include/mysql
  x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.6m -I/home/waboring/devel/wx.hemna.com/.venv/include/python3.6m -c oursqlx/compat.c -o build/temp.linux-x86_64-3.6/oursqlx/compat.o -I/usr/include/mysql
  In file included from oursqlx/compat.c:51:0:
  oursqlx/_exceptions.c: In function ‘_oursqlx_exc_from_errno’:
  oursqlx/_exceptions.c:620:24: error: ‘ER_ERROR_FIRST’ undeclared (first use in this function); did you mean ‘CR_ERROR_FIRST’?
               if (err >= ER_ERROR_FIRST && err <= ER_ERROR_LAST)
                          ^~~~~~~~~~~~~~
                          CR_ERROR_FIRST
  oursqlx/_exceptions.c:620:24: note: each undeclared identifier is reported only once for each function it appears in
  oursqlx/_exceptions.c:620:49: error: ‘ER_ERROR_LAST’ undeclared (first use in this function); did you mean ‘CR_ERROR_LAST’?
               if (err >= ER_ERROR_FIRST && err <= ER_ERROR_LAST)
                                                   ^~~~~~~~~~~~~
                                                   CR_ERROR_LAST
  error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
  ----------------------------------------
  ERROR: Failed building wheel for oursql3
  Running setup.py clean for oursql3
Failed to build oursql3
Installing collected packages: oursql3
    Running setup.py install for oursql3 ... error
    ERROR: Command errored out with exit status 1:
     command: /home/waboring/devel/wx.hemna.com/.venv/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"'; __file__='"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-ukh_wa26/install-record.txt --single-version-externally-managed --compile --install-headers /home/waboring/devel/wx.hemna.com/.venv/include/site/python3.6/oursql3
         cwd: /tmp/pip-install-uw2rdqvx/oursql3/
    Complete output (23 lines):
    running install
    running build
    running build_ext
    skipping 'oursqlx/oursql.c' Cython extension (up-to-date)
    building 'oursql' extension
    mysql_config --cflags
    creating build
    creating build/temp.linux-x86_64-3.6
    creating build/temp.linux-x86_64-3.6/oursqlx
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.6m -I/home/waboring/devel/wx.hemna.com/.venv/include/python3.6m -c oursqlx/oursql.c -o build/temp.linux-x86_64-3.6/oursqlx/oursql.o -I/usr/include/mysql
    x86_64-linux-gnu-gcc -pthread -DNDEBUG -g -fwrapv -O2 -Wall -g -fstack-protector-strong -Wformat -Werror=format-security -Wdate-time -D_FORTIFY_SOURCE=2 -fPIC -I/usr/include/python3.6m -I/home/waboring/devel/wx.hemna.com/.venv/include/python3.6m -c oursqlx/compat.c -o build/temp.linux-x86_64-3.6/oursqlx/compat.o -I/usr/include/mysql
    In file included from oursqlx/compat.c:51:0:
    oursqlx/_exceptions.c: In function ‘_oursqlx_exc_from_errno’:
    oursqlx/_exceptions.c:620:24: error: ‘ER_ERROR_FIRST’ undeclared (first use in this function); did you mean ‘CR_ERROR_FIRST’?
                 if (err >= ER_ERROR_FIRST && err <= ER_ERROR_LAST)
                            ^~~~~~~~~~~~~~
                            CR_ERROR_FIRST
    oursqlx/_exceptions.c:620:24: note: each undeclared identifier is reported only once for each function it appears in
    oursqlx/_exceptions.c:620:49: error: ‘ER_ERROR_LAST’ undeclared (first use in this function); did you mean ‘CR_ERROR_LAST’?
                 if (err >= ER_ERROR_FIRST && err <= ER_ERROR_LAST)
                                                     ^~~~~~~~~~~~~
                                                     CR_ERROR_LAST
    error: command 'x86_64-linux-gnu-gcc' failed with exit status 1
    ----------------------------------------
ERROR: Command errored out with exit status 1: /home/waboring/devel/wx.hemna.com/.venv/bin/python3 -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"'; __file__='"'"'/tmp/pip-install-uw2rdqvx/oursql3/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' install --record /tmp/pip-record-ukh_wa26/install-record.txt --single-version-externally-managed --compile --install-headers /home/waboring/devel/wx.hemna.com/.venv/include/site/python3.6/oursql3 Check the logs for full command output.```

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants