def write_requirements(cmd, basename, filename):
    dist = cmd.distribution
    data = ['\n'.join(yield_lines(dist.install_requires or ()))]
    for extra,reqs in (dist.extras_require or {}).items():
        data.append((extra, '\n'.join(yield_lines(reqs))) % '\n\n[%s]\n%s')
    cmd.write_or_delete_file("requirements", filename, ''.join(data))
dataset/ETHPy150Open AppScale/appscale/AppServer/lib/setuptools-0.6c11/setuptools/command/egg_info.py/write_requirements/swapped operands of `%`