tox fails when run - ValueError: No closing quotation

Bug #1527562 reported by Vladyslav Drok
20
This bug affects 3 people
Affects Status Importance Assigned to Milestone
Designate
Fix Released
Undecided
Unassigned
Ironic
Fix Released
High
Lucas Alvares Gomes
devstack
Fix Released
Undecided
Unassigned
devstack-plugin-ceph
Fix Released
Undecided
Andreas Jaeger
devstack-plugin-glusterfs
In Progress
Undecided
Ramana Raja
devstack-plugin-hdfs
Fix Released
Undecided
Ramana Raja
devstack-plugin-sheepdog
Fix Released
High
YAMADA Hideki

Bug Description

On fedora 23, on master (commit 2a5f6ded69d5c5b78671611150b20eb2d429fdc5), I get the following:

[vlad@vladpc ironic]$ tox -evenv --notest
Traceback (most recent call last):
  File "/usr/bin/tox", line 11, in <module>
    sys.exit(cmdline())
  File "/usr/lib/python2.7/site-packages/tox/session.py", line 38, in main
    config = prepare(args)
  File "/usr/lib/python2.7/site-packages/tox/session.py", line 26, in prepare
    config = parseconfig(args)
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 229, in parseconfig
    parseini(config, inipath)
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 729, in __init__
    self.make_envconfig(name, section, reader._subs, config)
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 760, in make_envconfig
    res = meth(env_attr.name, env_attr.default)
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 929, in getargvlist
    return _ArgvlistReader.getargvlist(self, s)
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 1093, in getargvlist
    commands.append(cls.processcommand(reader, current_command))
  File "/usr/lib/python2.7/site-packages/tox/config.py", line 1133, in processcommand
    argv = list(shlexer)
  File "/usr/lib64/python2.7/shlex.py", line 269, in next
    token = self.get_token()
  File "/usr/lib64/python2.7/shlex.py", line 96, in get_token
    raw = self.read_token()
  File "/usr/lib64/python2.7/shlex.py", line 172, in read_token
    raise ValueError, "No closing quotation"
ValueError: No closing quotation

When I checkout the commit before "Add bashate tox command", everything works fine:

[vlad@vladpc ironic]$ git checkout a0d2d7d13d4f0
Note: checking out 'a0d2d7d13d4f0'.

You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.

If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:

  git checkout -b <new-branch-name>

HEAD сейчас на a0d2d7d... Updated from global requirements
[vlad@vladpc ironic]$ tox -evenv --notest
venv develop-inst-noop: /home/vlad/ironic
venv installed: aioeventlet==0.4,alembic==0.8.3,amqp==1.4.8,anyjson==0.3.3,appdirs==1.4.0,automaton==1.0.0,Babel==2.1.1,beautifulsoup4==4.4.1,blockdiag==1.5.3,cachetools==1.1.5,cliff==1.15.0,cmd2==0.6.8,contextlib2==0.4.0,coverage==4.0.3,debtcollector==1.1.0,decorator==4.0.6,docutils==0.12,dogpile.cache==0.5.7,dogpile.core==0.4.1,ecdsa==0.13,enum34==1.1.1,eventlet==0.17.4,extras==0.0.3,fasteners==0.14.1,fixtures==1.4.0,flake8==2.2.4,funcparserlib==0.3.6,funcsigs==0.4,functools32==3.2.3.post2,futures==3.0.3,futurist==0.8.0,greenlet==0.4.9,hacking==0.10.2,httplib2==0.9.2,-e git+https://github.com/openstack/ironic@a0d2d7d13d4f08573c16e5263638d2a8b0570115#egg=ironic-dev,iso8601==0.1.11,Jinja2==2.8,jsonpatch==1.12,jsonpointer==1.10,jsonschema==2.5.1,keystoneauth1==2.1.0,keystonemiddleware==4.0.0,kombu==3.0.30,linecache2==1.0.0,logutils==0.3.3,Mako==1.0.3,MarkupSafe==0.23,mccabe==0.2.1,mock==1.3.0,monotonic==0.4,mox3==0.12.0,msgpack-python==0.4.6,netaddr==0.7.18,netifaces==0.10.4,numpy==1.10.1,ordereddict==1.1,os-client-config==1.12.0,os-testr==0.4.2,oslo.concurrency==3.1.0,oslo.config==3.1.0,oslo.context==1.0.0,oslo.db==4.1.0,oslo.i18n==3.1.0,oslo.log==2.1.0,oslo.messaging==3.1.0,oslo.middleware==3.2.0,oslo.policy==1.1.0,oslo.rootwrap==3.1.0,oslo.serialization==2.1.0,oslo.service==1.1.0,oslo.utils==3.2.0,oslo.versionedobjects==1.1.0,oslosphinx==4.1.0,oslotest==2.0.0,paramiko==1.16.0,Paste==2.0.2,PasteDeploy==1.5.2,pbr==1.8.1,pecan==1.0.3,pep8==1.5.7,Pillow==3.0.0,prettytable==0.7.2,psutil==1.2.1,psycopg2==2.6.1,pycadf==2.0.1,pycrypto==2.6.1,pyflakes==0.8.1,Pygments==2.0.2,pyinotify==0.9.6,PyMySQL==0.6.7,pyparsing==2.0.6,pysendfile==2.0.1,python-cinderclient==1.5.0,python-editor==0.5,python-glanceclient==1.2.0,python-ironicclient==1.0.0,python-keystoneclient==2.0.0,python-mimeparse==0.1.4,python-neutronclient==3.1.0,python-novaclient==2.35.0,python-openstackclient==2.0.0,python-subunit==1.2.0,python-swiftclient==2.7.0,pytz==2015.7,PyYAML==3.11,reno==1.2.0,repoze.lru==0.6,requests==2.8.1,requestsexceptions==1.1.1,retrying==1.3.3,Routes==2.2,seqdiag==0.9.5,simplegeneric==0.8.1,simplejson==3.8.1,singledispatch==3.4.0.3,six==1.10.0,Sphinx==1.2.3,sphinxcontrib-httpdomain==1.4.0,sphinxcontrib-pecanwsme==0.8.0,sphinxcontrib-seqdiag==0.8.5,SQLAlchemy==1.0.10,sqlalchemy-migrate==0.10.0,sqlparse==0.1.18,stevedore==1.10.0,Tempita==0.5.2,testrepository==0.0.20,testresources==1.0.0,testscenarios==0.5.0,testtools==1.8.1,traceback2==1.4.0,trollius==2.0,unicodecsv==0.14.1,unittest2==1.1.0,waitress==0.8.10,warlock==1.2.0,webcolors==1.5,WebOb==1.5.1,websockify==0.7.0,WebTest==2.0.20,wheel==0.24.0,wrapt==1.10.6,WSME==0.8.0
_____________________________________________________________ summary ______________________________________________________________
  venv: skipped tests
  congratulations :)

Vladyslav Drok (vdrok)
description: updated
Revision history for this message
Vladyslav Drok (vdrok) wrote :

tox version is 2.3.1

Revision history for this message
Lucas Alvares Gomes (lucasagomes) wrote :

I was able to reproduce it on a F23 VM

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to ironic (master)

Fix proposed to branch: master
Review: https://review.openstack.org/259445

Changed in ironic:
assignee: nobody → Lucas Alvares Gomes (lucasagomes)
status: New → In Progress
Changed in ironic:
assignee: Lucas Alvares Gomes (lucasagomes) → Zhenguo Niu (niu-zglinux)
Changed in ironic:
assignee: Zhenguo Niu (niu-zglinux) → Lucas Alvares Gomes (lucasagomes)
Dmitry Tantsur (divius)
Changed in ironic:
importance: Undecided → High
Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote : Re: tox fails when run

FYI, underlying issue is a backwards incompat change in tox:

https://bitbucket.org/hpk42/tox/issues/181

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to ironic (master)

Reviewed: https://review.openstack.org/259445
Committed: https://git.openstack.org/cgit/openstack/ironic/commit/?id=d7c41ebf9bc07f253fe08f77fde62a5a7ffef776
Submitter: Jenkins
Branch: master

commit d7c41ebf9bc07f253fe08f77fde62a5a7ffef776
Author: Lucas Alvares Gomes <email address hidden>
Date: Mon Dec 21 16:22:00 2015 +0800

    Fix "No closing quotation" error when building with tox

    Apparently # is treated as a comment inside the string and as
    consequence the rest of the command gets stripped. This patch drops
    those comments from the bashate command.

    This patch also moves the bashate command to its own script under
    tools/.

    Change-Id: Ic44bb64419ca1465f69c91fd579e8c84d69f84b8
    Closes-Bug: #1527562

Changed in ironic:
status: In Progress → Fix Released
Revision history for this message
Matt Riedemann (mriedem) wrote :
summary: - tox fails when run
+ tox fails when run - ValueError: No closing quotation
Changed in designate:
status: New → Fix Released
Changed in devstack-plugin-ceph:
assignee: nobody → Andreas Jaeger (jaegerandi)
status: New → In Progress
Revision history for this message
Matt Riedemann (mriedem) wrote :
Changed in devstack:
status: New → Fix Released
Revision history for this message
Matt Riedemann (mriedem) wrote :
Revision history for this message
Andreas Jaeger (jaegerandi) wrote :

Fix for devstack-plugin-ceph: https://review.openstack.org/#/c/260698/

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack-plugin-ceph (master)

Reviewed: https://review.openstack.org/260698
Committed: https://git.openstack.org/cgit/openstack/devstack-plugin-ceph/commit/?id=b0b7d37ee5e4e2d3c8e7b672b284bd4049c83116
Submitter: Jenkins
Branch: master

commit b0b7d37ee5e4e2d3c8e7b672b284bd4049c83116
Author: Andreas Jaeger <email address hidden>
Date: Tue Dec 22 21:19:15 2015 +0100

    Fix for tox 2.x

    Tox 2.x does not parse the current tox file as is, the comments cause
    "ValueError: No closing quotation". Remove the comments to make the file
    work with recent tox.

    This is caused by a backwards incompatible change in tox:
    https://bitbucket.org/hpk42/tox/issues/181

    Closes-Bug: #1527562
    Change-Id: I2a12093dcb3207be1a888445ec59e1b7da849852

Changed in devstack-plugin-ceph:
status: In Progress → Fix Released
Ramana Raja (rraja)
Changed in devstack-plugin-glusterfs:
assignee: nobody → Ramana Raja (rraja)
Changed in devstack-plugin-hdfs:
assignee: nobody → Ramana Raja (rraja)
Changed in devstack-plugin-glusterfs:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to devstack-plugin-glusterfs (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/261023

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix proposed to devstack-plugin-hdfs (master)

Related fix proposed to branch: master
Review: https://review.openstack.org/261028

Ramana Raja (rraja)
Changed in devstack-plugin-hdfs:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Related fix merged to devstack-plugin-glusterfs (master)

Reviewed: https://review.openstack.org/261023
Committed: https://git.openstack.org/cgit/openstack/devstack-plugin-glusterfs/commit/?id=7a0ff013db8ec629285ecf58b222d2a8762e92e4
Submitter: Jenkins
Branch: master

commit 7a0ff013db8ec629285ecf58b222d2a8762e92e4
Author: Ramana Raja <email address hidden>
Date: Wed Dec 23 20:26:43 2015 +0530

    Fix for tox 2.3.1 failure

    Remove inline comments after line escape that isn't understood by the
    tox's parser.

    This is due to the backward incompatible fix,
    https://bitbucket.org/hpk42/tox/issues/181

    Related Bug: #1527562

    Change-Id: Ib92b65b510fc3a6261e0e890c91af0718f24fc33

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack-plugin-hdfs (master)

Reviewed: https://review.openstack.org/261028
Committed: https://git.openstack.org/cgit/openstack/devstack-plugin-hdfs/commit/?id=c7e09efaa11f89d6291ab339cc6de6f4e980932a
Submitter: Jenkins
Branch: master

commit c7e09efaa11f89d6291ab339cc6de6f4e980932a
Author: Ramana Raja <email address hidden>
Date: Wed Dec 23 20:41:37 2015 +0530

    Fix bashate voting job

    The bashate job, a voting job, has been failing for a while due to
    two bugs. Fix the two bugs that require modifications to tox's
    configuration file, tox.ini.

    Bug #1527562
    Remove inline comments after line escape that isn't understood
    by tox's ini parser.
    This is due to the backward incompatible fix for,
    https://bitbucket.org/hpk42/tox/issues/181

    Bug #1554019
    Ignore .xml files that do not need to comply with bashate.

    Closes-Bug: #1527562
    Closes-Bug: #1554019

    Change-Id: Id11275d5d15e30d2558a475a4877e6d71bdc6726

Changed in devstack-plugin-hdfs:
status: In Progress → Fix Released
Revision history for this message
Doug Hellmann (doug-hellmann) wrote : Fix included in openstack/ironic 5.0.0

This issue was fixed in the openstack/ironic 5.0.0 release.

YAMADA Hideki (yamada-h)
Changed in devstack-plugin-sheepdog:
assignee: nobody → YAMADA Hideki (yamada-h)
importance: Undecided → Critical
status: New → In Progress
importance: Critical → High
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to devstack-plugin-sheepdog (master)

Reviewed: https://review.openstack.org/321964
Committed: https://git.openstack.org/cgit/openstack/devstack-plugin-sheepdog/commit/?id=96e6f9e39352a76f6ec77ce25de4f58f7c133a58
Submitter: Jenkins
Branch: master

commit 96e6f9e39352a76f6ec77ce25de4f58f7c133a58
Author: Andreas Jaeger <email address hidden>
Date: Tue Dec 22 21:19:15 2015 +0100

    Fix for tox 2.x

    Tox 2.x does not parse the current tox file as is, the comments cause
    "ValueError: No closing quotation". Remove the comments to make the file
    work with recent tox.

    This is caused by a backwards incompatible change in tox:
    https://bitbucket.org/hpk42/tox/issues/181

    Closes-Bug: #1527562
    Change-Id: I2a12093dcb3207be1a888445ec59e1b7da849852

Changed in devstack-plugin-sheepdog:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.