V Fri, 29 Mar 2019 13:20:24 +1000
William Brown <[email protected]> napsáno:

> > On 28 Mar 2019, at 19:05, Josef Reidinger <[email protected]> wrote:
> > 
> > V Thu, 28 Mar 2019 10:52:29 +1000
> > William Brown <[email protected]> napsáno:
> >   
> >>> On 27 Mar 2019, at 17:02, Josef Reidinger <[email protected]> wrote:
> >>> 
> >>> V Wed, 27 Mar 2019 10:04:01 +1000
> >>> William Brown <[email protected]> napsáno:
> >>>   
> >>>>> On 25 Mar 2019, at 16:52, Josef Reidinger <[email protected]> wrote:
> >>>>>   
> >>>>>> 
> >>>>>> 
> >>>>>> Is there something I’m missing in YaST to show ruby exceptions or 
> >>>>>> errors?       
> >>>>> 
> >>>>> Well, your problem is too generic exception catcher at 
> >>>>> https://github.com/Firstyear/yast-auth-server/blob/2019-03-19-update-ds-create/src/lib/authserver/ui/new_dir_inst.rb#L131
> >>>>> It catches all exceptions, which in general I do not recommend as it 
> >>>>> catches beside user errors also programmers ones. At least you can 
> >>>>> change it to `rescue RuntimeError`. And for sure always log what you 
> >>>>> catch unless you re-raise it, so it is not silent as now.
> >>>>> And because you catch exception, then global exception handler is not 
> >>>>> in reached.      
> >>>> 
> >>>> Errghh, I would never have found that. I’ve never seen a language that 
> >>>> uses rescue as an exception handler! Anyway, I now have the actual error 
> >>>> now (which is apperently that “log” IE log.debug() can’t be found in 
> >>>> authserver/dir/ds389.rb.).     
> >>> 
> >>> Welcome to ruby world. BTW ruby also have throw and catch, but for 
> >>> different purpose. See 
> >>> http://rubylearning.com/blog/2011/07/12/throw-catch-raise-rescue--im-so-confused/
> >>>     
> >> 
> >> https://github.com/yast/yast-auth-server/pull/49
> >> 
> >> Thanks for your help, finally at a stage for a PR and some better review. 
> >> Please remember I’m inheriting this code, so not all the design decisions 
> >> were mine.
> >> 
> >> Thanks! 
> >>   
> > 
> > Hi,
> > I did quick review. In general it looks good, just some tips. And one more 
> > here. Please consider using rubocop to have consistent style and ideally 
> > try to use yast style config, so it will be consistent with rest of yast 
> > modules.
> >   
> 
> I’m going to need some instructions and help on how to set this up (which 
> I’ll add to the README as well by the way :) )
> 
> Thanks for all your help and the reviews! 

Hi,
I try to point you to our documentation ( you can check also other interesting 
howtos there ). But we found that howto is only on our internal mailing list, 
so I take this oppurtinity and move it to our documentation[2].
So please be our guinea and check that new part of our documentation[1] :)

Thanks
Josef

[1] https://yastgithubio.readthedocs.io/en/latest/rubocop/
[2] https://github.com/yast/yast.github.io/pull/183

> 
> 
> > Josef
> > --
> > To unsubscribe, e-mail: [email protected]
> > To contact the owner, e-mail: [email protected]  
> 
> —
> Sincerely,
> 
> William Brown
> 
> Senior Software Engineer, 389 Directory Server
> SUSE Labs
> 

--
To unsubscribe, e-mail: [email protected]
To contact the owner, e-mail: [email protected]

Reply via email to