Closed pun-private closed 4 years ago
Hello again !
I have narrowed the problem. It seems that the problem comes from HTML::Pipeline::SyntaxHighlightFilter
that doesn't like triple backquote ```.
To trigger the error manually, I have updated the method parsed with the following code:
def parsed(source = self.source)
@parsed ||= html_pipeline.call("```python\nfoo = 'bar'\n```")
#@parsed ||= html_pipeline.call(source)
end
And if I comment HTML::Pipeline::SyntaxHighlightFilter
, no more errors...
def html_pipeline
@pipeline ||= HTML::Pipeline.new [
HTML::Pipeline::MarkdownFilter,
TaskList::Filter,
HTML::Pipeline::SanitizationFilter,
DocumentUp::Filters::TableOfContents,
HTML::Pipeline::ImageMaxWidthFilter,
#HTML::Pipeline::SyntaxHighlightFilter,
HTML::Pipeline::EmojiFilter,
HTML::Pipeline::AbsoluteSourceFilter,
DocumentUp::Filters::AbsoluteLinks,
HTML::Pipeline::MentionFilter,
HTML::Pipeline::AutolinkFilter
], {
base_url: "https://github.com/",
asset_root: "https://assets-cdn.github.com/images/icons",
image_base_url: "https://cdn.rawgit.com/#{repository.full_name}/#{repository.branch}/",
image_subpage_url: "https://cdn.rawgit.com/#{repository.full_name}/#{repository.branch}/",
link_subpage_url: "https://github.com/#{repository.full_name}/blob/#{repository.branch}/"
}
end
That is odd, that syntax filter should handle triple backticks fine. It handles other ways of "specifying" code?
The gem that handles that was built by Github themselves. I'm surprised it would break.
Could it be due to a more recent Ruby version? What are you running this on (OS, Ruby version, etc.)?
Thanks!
Hi !
Here are my specs:
root@documentup:/home/documentup/DocumentUp# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.1 LTS
Release: 14.04
Codename: trustyroot@documentup:/home/documentup/DocumentUp# ruby -v
ruby 2.1.6p336 (2015-04-13 revision 50298) [x86_64-linux]
Thx
Hi !
I tried installing documentup on my own server so I can modify the source code to handle custom README.md from other services than github.
So far, I just installed documentup without any modification to the source code. I created the database and disabled newrelic. But when I try to generate a documentation, I have the following error:
Any idea why ?
Thanks