Releases: marian13/convenient_service
Releases · marian13/convenient_service
v0.19.1
v0.19.0
0.19.0 (2024-06-08)
Features
- can_have_steps: introduce StepCollection#size (6360e2e)
- configs: introduce AmazingPrintInspect config (3035523)
- docker: add Ruby 3.4.0-preview1 (a115459)
- fallback: introduce fallback_result that is called for both failure and error, but has lower priority when specific method is defined (498bde0)
- fallbacks: do not allow fallbacks for method steps (f90abdd)
- middleware_stack: introduce alias #prepend for #unshift, #remove for #delete (527bb34)
- plugins: introduce ForbidsConvenientServiceEntitiesAsConstructorArguments (088505d)
- result: introduce Result#from_exception? (a47838a)
- result: introduce Result#from_step? (66cdf2a)
- rollback: introduce initial version of HasRollbacks (306960d)
- service: introduce ConvenientService::Service::Plugins::CanHaveSteps.step? (340d327)
- service: introduce ConvenientService.service? and ConvenientService.service_class? (c4caf14)
- step: cache Step#service_result (2fd0cd9)
- step: introduce Step#printable_container (9a555bd)
- support: introduce Ruby#mri? (a336874)
- utils: introduce Object.own_method (39e3c08)
- utils: introduce Object.safe_send (c66a551)
- utils: introduce String.enclose (10971c5)
- utils: rescue all standard error exceptions from Object.safe_send (2470a62)
Bug Fixes
- awesome/amazing_print: use message key as nested (86e41bf)
- BACKLOG: remove typo (3fcae2b)
- can_have_connected_steps: do not evaluate right expression when it can be avoided (131f911)
- can_have_connected_steps: use ConvenientService.raise (a19ce55)
- can_have_fallbacks: use ConvenientService.raise (148317d)
- forbids_convenient_service_entities_as_constructor_arguments: use ConvenientService.raise (1e5a260)
- forbids_convenient_service_entities_as_constructor_arguments: use ConvenientService.raise (ca89de8)
- ruby_engine_version: remove wrong memoization (addbd54)
- step: respect aliases for last(all) steps (b8285e3)
- Taskfile: remove typo (a577fbd)
Performance Improvements
- method_middleware: inline env normalization (2dfe210)
Miscellaneous Chores
- release 0.19.0 (4df0c8b)
v0.18.0
0.18.0 (2024-03-07)
⚠ BREAKING CHANGES
- can_have_steps: make step not fully compatible with result since it is an independent entity
Features
- backtrace_cleaner: do not clean specs (11f8f0c)
- can_be_negated: introduce Result#negated? (1362b9b)
- can_connected_steps: add inspect (d1318bd)
- can_connected_steps: introduce group, not_group, and_group, and_not_group, or_group, or_not_group (c517ef5)
- can_have_connected_steps: add inspect for empty expression (40496c1)
- can_have_connected_steps: add StepCollection#inspect (0523136)
- can_have_connected_steps: define exceptions (f481b33)
- can_have_connected_steps: introduce #scalar? (6ff4b38)
- can_have_connected_steps: introduce and expression (c654351)
- can_have_connected_steps: introduce base expression (d5243a3)
- can_have_connected_steps: introduce empty expression (222c053)
- can_have_connected_steps: introduce expression#steps (7644a44)
- can_have_connected_steps: introduce group expression (7f0ceff)
- can_have_connected_steps: introduce middleware (4d5f409)
- can_have_connected_steps: introduce not expression (583ddc4)
- can_have_connected_steps: introduce not_step (1336cb1)
- can_have_connected_steps: introduce or expression (b4d72a5)
- can_have_connected_steps: introduce scaalar (20bee82)
- can_have_connected_steps: start to use can_have_connected_steps by default (16fb5e2)
- can_have_negated_steps: introduce and_step, not_step, and_not_step (fab351c)
- can_have_sequential_steps: add StepCollection#inspect (8ba096f)
- can_have_steps: allow to override inputs in method steps (9d5e129)
- delegate_to: add failure message for and_return (eebfcb4)
- delegate_to: introduce not reaady for public usage and_return { ... } (30b1757)
- has_have_steps: introduce Step#to_s (19b1958)
- has_j_send_result: raise exception when to_bool called on error (5cfcefa)
- has_j_send_status_and_attributes: introduce #to_bool, #to_object, #to_a, #to_h, #to_s for learning purposes (a3c1782)
- has_negated_result: introduce #negated_result (6890cef)
- has_negated_result: introduce initial HasNegatedResult plugin (8c8fd70)
- has_negated_result: use HasNegatedResult plugin (6cb4e48)
- has_result_steps: introduce unsafe nott statuses (fe845b0)
- internals: add cache to class (b1363c7)
- support: introduce never reach here (c974f6b)
- support: introduce value (987455b)
- utils: allow to pass custom enumerablesto .find_last (85892da)
Bug Fixes
- can_have_sequential_steps: do not rely on automation plugin inside essential plugin (d9fe475)
- can_have_steps: use extra kwargs while comparing steps (82fb2b6)
- gemspec: use README.md (299e1cd)
- has_callbacks: state explicitly that callbacks for class methods are not supported yet (5f03829)
- has_instance_proxy: reraise rescued exception (fc3f8ee)
- has_jsend_result: remove outdated exception (a92fa15)
- has_negated_result: use copy to not lose original result extra kwargs (80d5f10)
- has_negated_result: use HasNegatedResult only for Standard config, not for minimal or v1 (b28453c)
- support: compare value by hash in eql? (a68ee68)
- vscode: bring back cache_its_value (e73ad88)
Miscellaneous Chores
- release 0.18.0 (343176f)
Code Refactoring
- can_have_steps: make step not fully compatible with result since it is an independent entity (5cea95d)
v0.17.0
0.17.0 (2024-01-14)
Features
- backtrace_cleaner: introduce add_convenient_service_silencer (07ce10f)
- backtrace_cleaner: upgrade to Rails 7.1.2 Backtrace Cleaner (6416691)
- core: clean backtrace in method_missing (0642198)
- core: clean backtrace in method_missing (81d0531)
- core: clean backtrace in method_missing (f07c354)
- entry: allow to define multiple entries at once (a9bca88)
- exception: allow to pass message or kwargs or no arguments (a92a040)
- exceptions: use backtrace_cleaner (7bc566e)
- exceptions: use backtrace_cleaner (b8d87a5)
- feature: allow to use middlewares for all entries at once (a2025dc)
- has_instance_proxy: delegate to target missing proxy methods (6be8d3b)
- has_instance_proxy: introduce #inspect (078d219)
- has_j_send_result: expose result? (f4d5f7f)
- has_j_send_status_and_attributes: introduce #to_bool (ec5ee1e)
- root: introduce ConvenientService.raise and ConvenientService.reraise (65f0148)
- root: introduce ConvenientService.root (dc5af36)
- support: add initial backtrace cleaner (14733f3)
Bug Fixes
v0.16.0
v0.15.0
0.15.0 (2023-11-10)
⚠ BREAKING CHANGES
- feature: allow to use plugins for features
Features
- can_have_steps: do not allow to modify steps from callbacks (b90b7f7)
- feature: allow to use plugins for features (17645f8)
Bug Fixes
- can_have_steps: introduce raises_on_not_result_return_value for steps (bb27527)
Miscellaneous Chores
- release 0.15.0 (7f6a6a7)
v0.14.0
0.14.0 (2023-09-20)
⚠ BREAKING CHANGES
- has_j_send_result_params_validations: return errors on validation issues
- has_j_send_result_params_validations: return errors on validation issues
- can_have_fallbacks: fallback only failures by default
- be_result: update got part
- has_j_send_result_short: update constants
- fallbacks: create separate fallbacks failures and errors, run only error fallback when true
Features
- be_result: introduce be_result (f8fc85b)
- can_have_fallbacks: allow to pass fallback_true_status (584dabe)
- can_have_fallbacks: fallback only failures by default (58650a7)
- configs: create copy of v1 (bb039c8)
- examples: create copy of v1 (70bd3fe)
- has_awesome_print_inspect: add message and data keys (14e0a3f)
- has_inspect: add message and data keys (8f30b7a)
- has_j_send_result_params_validations: return errors on validation issues (e25e1a4)
- has_j_send_result_params_validations: return errors on validation issues (09a9b94)
- has_j_send_result_short_syntax: allow to pass data, message, code to all results (aabf2f9)
- has_j_send_result_short_syntax: allow to pass message and code to short form of error (1af3153)
- has_j_send_result_short_syntax: allow to pass message and code to short form of failure (7390630)
- has_j_send_result_short_syntax: allow to pass message and code to short form of success (fdf2ab2)
- has_j_send_status_and_attributes: introduce Data#keys (27f43e1)
- has_j_send_status_and_attributes: introduce Message#empty? (6c1452d)
- rescues_result_unhandled_exceptions: allow to pass status (2ef85f2)
- using_active_model_validations: allow to pass status to middleware (bc5bb70)
- using_dry_validation: allow to pass status to middleware (3a5ef12)
Miscellaneous Chores
- release 0.14.0 (c7cef07)
Code Refactoring
v0.13.0
0.13.0 (2023-08-27)
⚠ BREAKING CHANGES
- has_j_send_result: rename HasResult to HasJSendResult
- has_result_short_syntax: allow to pass message to failures
- core: disallow config commitment by missing private method
- can_have_stubbed_result: state explicitly cache backend
- has_j_send_status_and_attributes: use Jsend to JSend
Features
- alias: introduce CS alias (14652d7)
- array-based-cache: add array-based cache implementation (795888a)
- be_result: add trigger for BE_RESULT (d7a416e)
- be_result: introduce comparing_by (c304fa7)
- cache: introduce thread safe array (b592853)
- call_chain_next: introduce with_any_arguments (17316d1)
- can_be_own_result: introduce new plugin (ba7111c)
- can_be_tried: inroduce CanBeTried for result (9e68538)
- can_be_tried: introduce step try option (9c1f493)
- can_have_checked_status: refactor marks_result_status_as_checked to have an ability of a pure status check (86750dd)
- can_have_steps: allow to pass extra kwargs to step definition (bd867e3)
- can_have_steps: introduce Step#resolved_result (68ee612)
- can_have_stubbed_results: use thread safe array backend (45b9e24)
- can_have_try_result: introduce middleware (da24051)
- can_have_try_result: introduce Service.try_result (92914dc)
- can_have_try_result: introduce Service#try_result (521e80f)
- can_have_try_result: use in minimal config (bf1135d)
- can_utilize_finite_loop: introduce new plugin (b161ecf)
- collects_services_in_exception: add initial version of plugin (720267a)
- configs: add ok? and not_ok? aliases for success? and not_success? (5dfb378)
- core: add trigger for RESOLVE_METHOD_MIDDLEWARES_SUPER_METHOD (d419985)
- core: commit config from .new (9e252a0)
- core: introduce has_committed_config? (ae01495)
- core: introduce middleware arguments (5ca7868)
- core: introduce Middleware.with (4272262)
- core: introduce MiddlewareCreator (d1b6ce8)
- core: introduce observable middleware (f767a13)
- core: introduce observe and use_and_observe (c19f624)
- core: MiddlewareCreator#new (e36cee9)
- core: track method_missing commit triggers (f3a7264)
- debug: add Step#output_values without specs (b7e4712)
- delegate_to: add with_any_arguments (f296e53)
- depencency_container: introduce entry (a905b6e)
- feature: introduce initial feature (7413273)
- has_awesome_print_inspect: add initial has_awesome_print_inspect for result (8437efe)
- has_awesome_print_inspect: add initial has_awesome_print_inspect for service (0e5d3c0)
- has_awesome_print_inspect: add initial has_awesome_print_inspect for step (d192327)
- has_awesome_print_inspect: add initial HasAwesomePrintInspect for Data (b5a9b7b)
- has_inspect: show anonymous class (87cc634)
- has_inspect: show anonymous class (5dc7779)
- has_j_send_status_and_attributes: add public creators (a954ef2)
- has_j_send_status_and_attributes: allow to compare code by #=== (54b5025)
- has_j_send_status_and_attributes: allow to compare data by #=== (a5ce835)
- has_j_send_status_and_attributes: allow to compare message by #=== (ddd5ffd)
- has_j_send_status_and_attributes: introduce Code.=== (c2414cc)
- has_j_send_status_and_attributes: introduce Data.=== (d47202d)
- has_j_send_status_and_attributes: introduce Message.=== (f936fae)
- has_j_send_status_and_attributes: introduce Status.=== (494a9b3)
- has_j_send_status_and_attributes: link result to status, data, message, code (dd87723)
- has_j_send_status_and_attributes: respect RSpec argument matchers via #=== (c163b32)
- has_j_send_status_and_attributes: support partial data matching (154a4fd)
- has_jsend_status_and_attributes: allow user to provide Code, Data, Message and Status classes (ff9703e)
- has_mermaid_flowchart: introduce experimental flowchart (73475e6)
- has_result_status_check_short_syntax: Add two more short bool result checks (a8a8a8b)
- has_result: export commands.is_result? (17e6bb6)
- has_result: introduce Commands::IsResult (94e337a)
- logger: add version class (2e5b236)
- logger: provide fallback for older loggers (6bbefdc)
- method_middlewares: introduce #next_arguments ([a87...
v0.12.0
0.12.0 (2023-04-01)
⚠ BREAKING CHANGES
- has_j_send_status_and_attributes: use Jsend to JSend
- can_have_method_steps: bring back CanHaveMethodSteps since it is thread-safe
Features
- be_result: add trigger for BE_RESULT (d7a416e)
- can_have_method_steps: bring back CanHaveMethodSteps since it is thread-safe (cbd4f35)
- core: add config constants (7438742)
- core: add method_missing_commits_counter (9f143a0)
- core: add trigger for config commitment in class method missing (97a4acf)
- core: add trigger for config commitment in instance method missing (e1ebfc0)
- core: add trigger for RESOLVE_METHOD_MIDDLEWARES_SUPER_METHOD (d419985)
- core: add trigger option commit_config! (2c7c041)
- core: default commit trigger to user (127822a)
- core: introduce config commitment triggers (b92ee50)
- core: introduce middleware arguments (5ca7868)
- core: introduce Middleware.with (4272262)
- core: introduce MiddlewareCreator (d1b6ce8)
- core: MiddlewareCreator#new (e36cee9)
- core: track method_missing commit triggers (f3a7264)
- depencency_container: introduce entry (a905b6e)
- feature: introduce initial feature (7413273)
- finite_loop: introduce FiniteLoop.finite_loop (ae363c1)
- has_jsend_status_and_attributes: allow user to provide Code, Data, Message and Status classes (ff9703e)
- has_result_status_check_short_syntax: Add two more short bool result checks (a8a8a8b)
- in_threads: introduce in_threads RSpec helper (dbd54ac)
- rescues_result_unhandled_exceptions: read max_backtrace_size from middleware arguments (6d7de5e)
- ruby_middleware: add support of middleware creators (06bcc15)
- ruby: check if jruby (fba70da)
- ruby: check if truffleruby (341ced1)
- stub_service: add trigger for STUB_SERVICE (047c835)
- support ruby 3.2 in CI and Docker (4dc26b9)
- support: introduce thread_safe_counter (ea25f15)
- support: introduce UniqueValue (b007123)
- support: safe_method (b37d735)
- support: ThreadSafeCounter#current_value= (bf703bb)
- thread_safe_counter: introduce bincrement and bdecrement (a0ef972)
- unique_value: add == consistency (26c8686)
- unique_value: add comparisons (cf02a50)
- utils: introduce Object.resolve_class (94f6ca2)
Bug Fixes
- can_have_steps: set correct error namaspace (1f6d647)
- can_have_stubbed_result: add thread-safety (ef77058)
- core: remove typo in description (a34323f)
- dependency_container: remove typo (fbcfd28)
- has_result_status_check_short_syntax: Correct implementation of two methods (5cf6004)
- logger: update ENV variable (86301ce)
- support: group examples (97549e9)
Miscellaneous Chores
- release 0.12.0 (da182b6)
Code Refactoring
- has_j_send_status_and_attributes: use Jsend to JSend (ffb2642)
v0.11.0
0.11.0 (2023-03-04)
⚠ BREAKING CHANGES
- can_have_method_steps: rename has_result_method_steps to can_have_method_steps
- can_have_steps: rename has_result_steps to can_have_steps
Bug Fixes
- can_have_method_steps: disable CanHaveMethodSteps in Standard config (af0b039)
Code Refactoring
- can_have_method_steps: rename has_result_method_steps to can_have_method_steps (39901a3)
- can_have_steps: rename has_result_steps to can_have_steps (691d8e1)
Miscellaneous Chores
- release 0.11.0 (dc6282a)