--
You received this message because you are subscribed to the Google Groups "praxis-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to praxis-developm...@googlegroups.com.
To post to this group, send email to praxis-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/praxis-development/799f61fc-d3cf-4bc7-af2f-3e6b673fab21%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Praxis::ApiDefinition.define do
trait :versioned do version '1', using: [:path] end
...
end
module V1 module Resources class AuthReset include Praxis::ResourceDefinition media_type MediaTypes::AuthReset use :versioned
...
end
end
end
/home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/trait.rb:108:in `block in apply!': undefined method `version' for #<Praxis::ActionDefinition:0x00000001f33b70> (NoMethodError) from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/trait.rb:104:in `each' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/trait.rb:104:in `apply!' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/action_definition.rb:72:in `trait' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/action_definition.rb:58:in `block in initialize' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/action_definition.rb:57:in `each' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/action_definition.rb:57:in `initialize' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/resource_definition.rb:158:in `new' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/resource_definition.rb:158:in `action' from /home/ashish/codebase/coef/coef-open-api/design/v1/resources/auth_reset.rb:8:in `<class:AuthReset>' from /home/ashish/codebase/coef/coef-open-api/design/v1/resources/auth_reset.rb:3:in `<module:Resources>' from /home/ashish/codebase/coef/coef-open-api/design/v1/resources/auth_reset.rb:2:in `<module:V1>' from /home/ashish/codebase/coef/coef-open-api/design/v1/resources/auth_reset.rb:1:in `<top (required)>' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader_stages/file_loader.rb:19:in `require' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader_stages/file_loader.rb:19:in `block in execute' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader_stages/file_loader.rb:16:in `each' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader_stages/file_loader.rb:16:in `execute' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/stage.rb:28:in `run' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/stage.rb:51:in `block in execute' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/stage.rb:50:in `each' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/stage.rb:50:in `execute' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/stage.rb:28:in `run' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader.rb:118:in `block in run' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader.rb:116:in `each' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader.rb:116:in `run' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/bootloader.rb:112:in `setup!' from /home/ashish/pet_pro/praxis-kit/praxis/lib/praxis/application.rb:62:in `setup' from /home/ashish/codebase/coef/coef-open-api/config.ru:7:in `block in <main>' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/builder.rb:55:in `instance_eval' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/builder.rb:55:in `initialize' from /home/ashish/codebase/coef/coef-open-api/config.ru:in `new' from /home/ashish/codebase/coef/coef-open-api/config.ru:in `<main>' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/builder.rb:49:in `eval' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/builder.rb:49:in `new_from_string' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/builder.rb:40:in `parse_file' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/server.rb:318:in `build_app_and_options_from_config' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/server.rb:218:in `app' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/server.rb:353:in `wrapped_app' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/server.rb:282:in `start' from /home/ashish/pet_pro/praxis-kit/rack/lib/rack/server.rb:147:in `start' from /home/ashish/pet_pro/praxis-kit/rack/bin/rackup:4:in `<top (required)>' from /home/ashish/.rvm/gems/ruby-2.2.1@coef/bin/rackup:23:in `load' from /home/ashish/.rvm/gems/ruby-2.2.1@coef/bin/rackup:23:in `<main>' from /home/ashish/.rvm/gems/ruby-2.2.1@coef/bin/ruby_executable_hooks:15:in `eval' from /home/ashish/.rvm/gems/ruby-2.2.1@coef/bin/ruby_executable_hooks:15:in `<main>'
Ashish,I believe there aren't many breaking changes around traits (one that I know is that if you used bound variables inside a trait definition, that would need to be changed), but other than that, I'm not sure there aren't many/others.Can you post what error you're getting when upgrading? I can help you out if I see it.Cheers,Josep M.
On Sun, May 17, 2015 at 8:32 AM, Ashish Gaur <thecuriou...@gmail.com> wrote:
Hey guys,We have been using praxis 0.15 since now and would like to upgrade to 0.16.x. I have gone through the changelog which states quite breaking changes around traits. We want to update our code to conform with 0.16 standards but there are no examples to be found. The documentation seems to show the examples for 0.15 version. Is there any other source I can refer to use praxis 0.16 which will help me resolve problem I'll face while upgrading ?Thanks
--
You received this message because you are subscribed to the Google Groups "praxis-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to praxis-development+unsub...@googlegroups.com.
module V1
module Resources
module Base
extend ActiveSupport::Concern
# Common concerns for all resources of this version
included do
# Add all the DSL stanzas you want to be executed in the context of the included Resource here
version '3.0'
end
end
end
end
To unsubscribe from this group and stop receiving emails from it, send an email to praxis-developm...@googlegroups.com.
To post to this group, send email to praxis-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/praxis-development/799f61fc-d3cf-4bc7-af2f-3e6b673fab21%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "praxis-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to praxis-developm...@googlegroups.com.
To post to this group, send email to praxis-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/praxis-development/735bc022-894b-45c3-a42d-514ef5d83d79%40googlegroups.com.
ResourceDefinition.routing
. Use ResourceDefinition.prefix
to define resource-level route prefixes instead". I assumed that this would imply that if I create a resource named AuthReset then the string 'auth_reset' which was by default appended is no longer being done and I had to explicitly specify it in prefix. But when I upgraded to 0.16.1 my routes still had 'auth_reset' appended to it. How does this deprecation affect anything ?Thanks a lot Josep :).I have few more doubts:# As per CHANGELOG for 0.16 "DeprecatedResourceDefinition.routing
. UseResourceDefinition.prefix
to define resource-level route prefixes instead". I assumed that this would imply that if I create a resource named AuthReset then the string 'auth_reset' which was by default appended is no longer being done and I had to explicitly specify it in prefix. But when I upgraded to 0.16.1 my routes still had 'auth_reset' appended to it. How does this deprecation affect anything ?
# I checked the introduction of MediaTypeIdentifier in 0.15 which I thought was an internal change and won't affect anything in using identifier in media type. But then I stumbled upon this line, I am little bit confused(and scared :P) of whether this is really deprecated or not. It seems identifier still returns a string and not an MediaTypeIdentifier. If I upgrade to 0.16.1 do I have to use MediaTypeIdentifier externally in my code instead of using identifier ? Is this a possible use case for future ?
Ashish
--
You received this message because you are subscribed to the Google Groups "praxis-development" group.
To unsubscribe from this group and stop receiving emails from it, send an email to praxis-developm...@googlegroups.com.
To post to this group, send email to praxis-de...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/praxis-development/6b74ee62-1151-4233-88e9-946f8bc58cb6%40googlegroups.com.