Proposed Changes for TOPSIS Configuration and Unit Tests #73
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request introduces significant updates to the TOPSIS analysis functionality in order to provide better configurability for users. The primary objective is to allow users to configure TOPSIS analysis using environment variables, making it easier to parameterize the analysis according to specific project requirements.
TOPSIS_CRITERIA
,TOPSIS_WEIGHTS
, andTOPSIS_ALTERNATIVES
.CriterionParser
andAlternativesParser
, to facilitate parsing criteria and alternatives with their respective weights and names.InvalidCriterionError
,MissingWeightError
, andNoCriteriaProvidedError
) to handle different validation scenarios when parsing criteria.topsis
command to utilize the newCriterionParser
andAlternativesParser
for parsing criteria and alternatives.topsis
command now also has a more detailed docstring explaining its purpose, input parameters, and possibleexceptions.
All changes have been thoroughly tested locally to ensure their correctness and maintain functionality with existing code. Unit tests have been included to validate the new parsing classes and verify the expected behavior of the TOPSIS analysis.
[How to Use the New Configuration Options]
With the new environment variables introduced, users can now easily configure the criteria and alternatives for TOPSIS analysis by setting the appropriate environment variables. Detailed documentation on how to use these environment variables has been added to the project's .env-example file.
Please review the proposed changes and provide feedback. These enhancements aim to make TOPSIS analysis more user-friendly and configurable, empowering users to fine-tune the analysis based on their specific project needs.