1

I am getting several warnings when generating my project documentation because YARD cannot parse some external class extensions

[warn]: in YARD::Handlers::Ruby::MixinHandler: Undocumentable mixin: YARD::Parser::UndocumentableError for class MyClass
[warn]:     in file 'lib/Project/myclass.rb':7:

    7: include Virtus.model

The root of the problem is one class extension that cannot be parsed. I know I could just run yard -q to suppress all warnings, but I would rather supress individual extensions than everything.

As far as I can see in the help, I could --exclude but right now, the offending class is part of an external gem. I also tried @!parse without success

class MyClass

  # @!parse Virtus.model
  include Virtus.model
end
David Grayson
  • 84,103
  • 24
  • 152
  • 189
SystematicFrank
  • 16,555
  • 7
  • 56
  • 102

1 Answers1

0

I had the same problem, and I was able to hide the warning by obfuscating the inclusion so YARD cannot detect it:

class MyClass
  send :include, Virtus.model
end

There is more discussion of this issue on github:

https://github.com/lsegal/yard/issues/546

David Grayson
  • 84,103
  • 24
  • 152
  • 189