SGA-A / c2c

Source code for the custom app exclusive to cc
MIT License
1 stars 0 forks source link

Create and raise Custom Exceptions for mismatches in input criteria #148

Closed SGA-A closed 1 month ago

SGA-A commented 3 months ago

Remaining instances of this issue to rectify

Describe alternatives you've considered Nothing yet

Additional context Relevant documentation: https://docs.python.org/3/tutorial/errors.html#exceptions https://docs.python.org/3/tutorial/errors.html#handling-exceptions https://docs.python.org/3/tutorial/errors.html#raising-exceptions https://docs.python.org/3/tutorial/errors.html#user-defined-exceptions

SGA-A commented 3 months ago

Was recently addressed in today's commit via item partial matching, but there are still more areas where this is needed.

SGA-A commented 3 months ago

For now, we had to place one of our transformers inside the cogs\economy file path in order to avoid a circular import. The transformer relies on classes that are also only available inside that file path.

Since this is starting to become a major problem, #124 will be receiving a lot of attention over the next couple of weeks/months moving forward.

Also, this is my first time creating custom transformers, so the practises I used to perform the changes in the resolving commit may not be right, in which case look into the documentation for this initial issue comment and also consider looking into the docs for transformers themselves.

SGA-A commented 3 months ago

There were more instances of this happening then we thought, so we'll begin working on it again.

SGA-A commented 2 months ago

Will be open indefinitley until I can firmly confirm that there are no more unnecessary instances of this happening.

SGA-A commented 2 months ago

Updated the original comment to include the known list of these instances occuring to make changes to accordingly.

SGA-A commented 1 month ago

Generally speaking this is only applicable to helper functions and objects that act as helpers (i.e., transformers).