(flags, flag)
| 253 | "contradiction error with " + incompatible_flag + ".") |
| 254 | |
| 255 | def remove_flags_after(flags, flag): |
| 256 | try: |
| 257 | pos = flags.index(normalize_flag(flag)) |
| 258 | except: |
| 259 | pass |
| 260 | else: |
| 261 | flags = flags[0:pos] |
| 262 | return flags |
| 263 | |
| 264 | # Flags can be ignored with respect to contradictions by passing |
| 265 | # --fuzzing or --no-abort-on-contradictory-flags, which ignores all |