prompt: We are currently solving the following issue within our repository. Here is the issue text:
  --- BEGIN ISSUE ---
  Split cirq packages into with/without contrib
  Otherwise there's no way to easily pip install the contrib-requirements
  
  --- END ISSUE ---
  
  Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
  --- BEGIN FILES ---
  Path: `setup.py`
  Content:
  ```
  1 # Copyright 2018 The Cirq Developers
  2 #
  3 # Licensed under the Apache License, Version 2.0 (the "License");
  4 # you may not use this file except in compliance with the License.
  5 # You may obtain a copy of the License at
  6 #
  7 #     https://www.apache.org/licenses/LICENSE-2.0
  8 #
  9 # Unless required by applicable law or agreed to in writing, software
  10 # distributed under the License is distributed on an "AS IS" BASIS,
  11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12 # See the License for the specific language governing permissions and
  13 # limitations under the License.
  14 
  15 import io
  16 from setuptools import find_packages, setup
  17 
  18 # This reads the __version__ variable from cirq/_version.py
  19 __version__ = ''
  20 exec(open('cirq/_version.py').read())
  21 
  22 description = ('A framework for creating, editing, and invoking '
  23                'Noisy Intermediate Scale Quantum (NISQ) circuits.')
  24 
  25 # README file as long_description.
  26 long_description = io.open('README.rst', encoding='utf-8').read()
  27 
  28 # Read in requirements
  29 requirements = open('requirements.txt').readlines()
  30 requirements = [r.strip() for r in requirements]
  31 
  32 cirq_packages = ['cirq'] + [
  33     'cirq.' + package for package in find_packages(where='cirq')
  34 ]
  35 
  36 setup(name='cirq',
  37       version=__version__,
  38       url='http://github.com/quantumlib/cirq',
  39       author='The Cirq Developers',
  40       author_email='cirq@googlegroups.com',
  41       python_requires=('>=3.6.0'),
  42       install_requires=requirements,
  43       license='Apache 2',
  44       description=description,
  45       long_description=long_description,
  46       packages=cirq_packages,
  47       package_data={
  48           'cirq.api.google.v1': ['*.proto'],
  49           'cirq.api.google.v2': ['*.proto'],
  50       })
  51
  ```
  --- END FILES ---
  
  Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.
  
  Here is an example:
  
  ```diff
  diff --git a/examples/server_async.py b/examples/server_async.py
  --- a/examples/server_async.py
  +++ b/examples/server_async.py
  @@ -313,4 +313,4 @@
   
   
   if __name__ == "__main__":
  -    asyncio.run(run_async_server("."), debug=True)
  +    asyncio.run(run_async_server(), debug=True)
  diff --git a/examples/server_sync.py b/examples/server_sync.py
  --- a/examples/server_sync.py
  +++ b/examples/server_sync.py
  @@ -313,5 +313,5 @@
   
   
   if __name__ == "__main__":
  -    server = run_sync_server(".")
  +    server = run_sync_server()
       server.shutdown()
  
  ```
  
golden_diff: diff --git a/setup.py b/setup.py
  --- a/setup.py
  +++ b/setup.py
  @@ -28,6 +28,10 @@
   # Read in requirements
   requirements = open('requirements.txt').readlines()
   requirements = [r.strip() for r in requirements]
  +contrib_requirements = open('cirq/contrib/contrib-requirements.txt').readlines()
  +contrib_requirements = [r.strip() for r in contrib_requirements]
  +dev_requirements = open('dev_tools/conf/pip-list-dev-tools.txt').readlines()
  +dev_requirements = [r.strip() for r in dev_requirements]
   
   cirq_packages = ['cirq'] + [
       'cirq.' + package for package in find_packages(where='cirq')
  @@ -40,6 +44,10 @@
         author_email='cirq@googlegroups.com',
         python_requires=('>=3.6.0'),
         install_requires=requirements,
  +      extras_require={
  +          'contrib': contrib_requirements,
  +          'dev': dev_requirements,
  +      },
         license='Apache 2',
         description=description,
         long_description=long_description,
  
verification_info: {"golden_diff": "diff --git a/setup.py b/setup.py\n--- a/setup.py\n+++ b/setup.py\n@@ -28,6 +28,10 @@\n # Read in requirements\n requirements = open('requirements.txt').readlines()\n requirements = [r.strip() for r in requirements]\n+contrib_requirements = open('cirq/contrib/contrib-requirements.txt').readlines()\n+contrib_requirements = [r.strip() for r in contrib_requirements]\n+dev_requirements = open('dev_tools/conf/pip-list-dev-tools.txt').readlines()\n+dev_requirements = [r.strip() for r in dev_requirements]\n \n cirq_packages = ['cirq'] + [\n     'cirq.' + package for package in find_packages(where='cirq')\n@@ -40,6 +44,10 @@\n       author_email='cirq@googlegroups.com',\n       python_requires=('>=3.6.0'),\n       install_requires=requirements,\n+      extras_require={\n+          'contrib': contrib_requirements,\n+          'dev': dev_requirements,\n+      },\n       license='Apache 2',\n       description=description,\n       long_description=long_description,\n", "issue": "Split cirq packages into with/without contrib\nOtherwise there's no way to easily pip install the contrib-requirements\n", "before_files": [{"content": "# Copyright 2018 The Cirq Developers\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\nimport io\nfrom setuptools import find_packages, setup\n\n# This reads the __version__ variable from cirq/_version.py\n__version__ = ''\nexec(open('cirq/_version.py').read())\n\ndescription = ('A framework for creating, editing, and invoking '\n               'Noisy Intermediate Scale Quantum (NISQ) circuits.')\n\n# README file as long_description.\nlong_description = io.open('README.rst', encoding='utf-8').read()\n\n# Read in requirements\nrequirements = open('requirements.txt').readlines()\nrequirements = [r.strip() for r in requirements]\n\ncirq_packages = ['cirq'] + [\n    'cirq.' + package for package in find_packages(where='cirq')\n]\n\nsetup(name='cirq',\n      version=__version__,\n      url='http://github.com/quantumlib/cirq',\n      author='The Cirq Developers',\n      author_email='cirq@googlegroups.com',\n      python_requires=('>=3.6.0'),\n      install_requires=requirements,\n      license='Apache 2',\n      description=description,\n      long_description=long_description,\n      packages=cirq_packages,\n      package_data={\n          'cirq.api.google.v1': ['*.proto'],\n          'cirq.api.google.v2': ['*.proto'],\n      })\n", "path": "setup.py"}], "after_files": [{"content": "# Copyright 2018 The Cirq Developers\n#\n# Licensed under the Apache License, Version 2.0 (the \"License\");\n# you may not use this file except in compliance with the License.\n# You may obtain a copy of the License at\n#\n#     https://www.apache.org/licenses/LICENSE-2.0\n#\n# Unless required by applicable law or agreed to in writing, software\n# distributed under the License is distributed on an \"AS IS\" BASIS,\n# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n# See the License for the specific language governing permissions and\n# limitations under the License.\n\nimport io\nfrom setuptools import find_packages, setup\n\n# This reads the __version__ variable from cirq/_version.py\n__version__ = ''\nexec(open('cirq/_version.py').read())\n\ndescription = ('A framework for creating, editing, and invoking '\n               'Noisy Intermediate Scale Quantum (NISQ) circuits.')\n\n# README file as long_description.\nlong_description = io.open('README.rst', encoding='utf-8').read()\n\n# Read in requirements\nrequirements = open('requirements.txt').readlines()\nrequirements = [r.strip() for r in requirements]\ncontrib_requirements = open('cirq/contrib/contrib-requirements.txt').readlines()\ncontrib_requirements = [r.strip() for r in contrib_requirements]\ndev_requirements = open('dev_tools/conf/pip-list-dev-tools.txt').readlines()\ndev_requirements = [r.strip() for r in dev_requirements]\n\ncirq_packages = ['cirq'] + [\n    'cirq.' + package for package in find_packages(where='cirq')\n]\n\nsetup(name='cirq',\n      version=__version__,\n      url='http://github.com/quantumlib/cirq',\n      author='The Cirq Developers',\n      author_email='cirq@googlegroups.com',\n      python_requires=('>=3.6.0'),\n      install_requires=requirements,\n      extras_require={\n          'contrib': contrib_requirements,\n          'dev': dev_requirements,\n      },\n      license='Apache 2',\n      description=description,\n      long_description=long_description,\n      packages=cirq_packages,\n      package_data={\n          'cirq.api.google.v1': ['*.proto'],\n          'cirq.api.google.v2': ['*.proto'],\n      })\n", "path": "setup.py"}]}