magnetis / caze Goto Github PK
View Code? Open in Web Editor NEWA DSL to define use cases
License: Apache License 2.0
A DSL to define use cases
License: Apache License 2.0
Dependabot can't resolve your Ruby dependency files.
As a result, Dependabot couldn't update your dependencies.
The error Dependabot encountered was:
Bundler::VersionConflict with message: Bundler could not find compatible versions for gem "bundler":
In Gemfile:
bundler (~> 1.6)
Current Bundler version:
bundler (2.2.15)
Your bundle requires a different version of Bundler than the one you're running.
Install the necessary version with `gem install bundler:1.17.3` and rerun bundler using `run.rb _1.17.3_`
If you think the above is an error on Dependabot's side please don't hesitate to get in touch - we'll do whatever we can to fix it.
The exception interceptor feature is intended to make clear which use case raised a given error, including the use case name in the exception. This is a good idea for general tracing of the error.
The issue here is that since the class is created dynamically, it is not referenceable by the caller and therefore not rescuable precisely. Further, since the new exception doesn't even inherit from the previous one, it is only rescuable if the rescue clause targets the StandardError
class.
One obvious solution would be to at least inherit from the previous class, but this won't work because case
has no way of figuring out how to construct the error it gets (since the error isn't required to follow any protocol).
Finally, I think the feature in itself doesn't add that much and it causes these problems, so it might be better removed.
class A
include Case
class E < StandardError
has_use_case :b, A::B # b throws the A::E error
end
begin
A.b
rescue A::B::E => e
# won't happen because this isn't even defined on this point
rescue A::E => e
# won't happen, because the re-thrown error doesn't inherit from this one
# it inherits from StandardError
rescue => e
# will happen and that's the only way to catch the error
end
The ideia is to be able to define an use case using a string.
This is needed in order to work with engine entry points.
Example:
module MyEngine
include Caze
has_use_case :calculate_the_answer, 'MyEngine::SuperComputer'
end
This string would be evaluated using Object.const_get/1
in order to execute the use case.
It's important to give information about what changed in the history of the project.
We can follow the Keep a CHANGELOG style that is very interesting.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.