Skip to content

[BUG] Deprecated conda flag causes failures #1653

Description

@connorbrinton

Describe the bug
Running FOSSA on a Conda project attempts to use the deprecated and now-removed --force flag. Here's the Conda PR where the flag was deprecated:
conda/conda#12493

Here's the Conda PR where the flag was removed:
conda/conda#13634

Here's where FOSSA CLI hard-codes the --force flag:

To Reproduce
Steps to reproduce the behavior:

  1. Run fossa analyze ... on a conda project with a newer conda version installed
  2. See error

Error:

[ 0 Waiting / 1 Running / 72 Completed ]
Error:  An issue occurred
  *** Relevant Errors ***
      Error: Command execution failed
        Attempted to run the command 'conda env create --json --file /.../environment.yml --dry-run --force'
        inside the working directory '/.../',
        but failed, because the command exited with code '2'.
        Often, this kind of error is caused by the project not being ready to build;
        please ensure that the project at '/.../'
        builds successfully before running fossa.
        The logs for the command are listed below.
        They will likely provide guidance on how to resolve this error.
        Command did not write a standard log.
        Command error log:
          usage: conda [-h] [-v] [--no-plugins] [-V] COMMAND ...
          conda: error: unrecognized arguments: --force
      Support: If you believe this to be a defect, please report a bug to FOSSA support at https://support.fossa.com/
      Support: If you believe this to be a defect, please report a bug to FOSSA support at https://support.fossa.com,/ with a copy of: /.../environment.yml
      Error: parsing file: /.../environment.yml
        Aeson exception:
        Error in $: key "name" not found

Expected behavior
No error should occur, the new --yes flag should be used instead

Debug bundle
N/A

Additional context
N/A

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions