()
| 161 | |
| 162 | |
| 163 | def get_install_requires(): |
| 164 | try: |
| 165 | import flit_core.buildapi |
| 166 | except ImportError: |
| 167 | flit_core_exception = get_flit_core_unmet_exception() |
| 168 | raise flit_core_exception |
| 169 | |
| 170 | with cd(ROOT_DIR): |
| 171 | requires = flit_core.buildapi.get_requires_for_build_wheel() |
| 172 | # Generation of the auto-complete index requires importing from the |
| 173 | # awscli package and iterating over the commands from the clidriver. In |
| 174 | # order to be able to do this, it requires all of the CLI's runtime |
| 175 | # dependencies to be present to avoid import errors. |
| 176 | dependency_block_re = re.compile( |
| 177 | r"dependencies = \[([\s\S]+?)\]", re.MULTILINE |
| 178 | ) |
| 179 | extract_dependencies_re = re.compile(r'"(.+)"') |
| 180 | with open(ROOT_DIR / "pyproject.toml") as f: |
| 181 | data = f.read() |
| 182 | raw_dependencies = dependency_block_re.findall(data)[0] |
| 183 | dependencies = extract_dependencies_re.findall(raw_dependencies) |
| 184 | return dependencies |
| 185 | |
| 186 | |
| 187 | def get_flit_core_unmet_exception(): |
no test coverage detected