Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-14210] Module: Markdown error if image in documentation folder

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionWon't Fix
Resolution Date2013-07-29T17:29:20.000+0000
Affected Version/sn/a
Fix Version/sn/a
Componentsn/a
Labelsimage, markdown, module
ReporterMads Moller
AssigneeIngo Muschenetz
Created2013-03-31T10:49:15.000+0000
Updated2017-03-30T21:04:42.000+0000

Description

If I add any image into the documentation folder, the build.py will fail on iOS:
Traceback (most recent call last):
  File "./build.py", line 217, in <module>
    package_module(manifest,mf,config)
  File "./build.py", line 189, in package_module
    docs = generate_doc(config)
  File "./build.py", line 65, in generate_doc
    html = markdown.markdown(md)
  File "/Users/napp/Library/Application Support/Titanium/mobilesdk/osx/2.1.4.GA/common/markdown/__init__.py", line 598, in markdown
    return md.convert(text)
  File "/Users/napp/Library/Application Support/Titanium/mobilesdk/osx/2.1.4.GA/common/markdown/__init__.py", line 377, in convert
    message(CRITICAL, 'UnicodeDecodeError: Markdown only accepts unicode or ascii input.')
  File "/Users/napp/Library/Application Support/Titanium/mobilesdk/osx/2.1.4.GA/common/markdown/__init__.py", line 112, in message
    raise MarkdownException, text
markdown.MarkdownException: UnicodeDecodeError: Markdown only accepts unicode or ascii input.

Comments

  1. Jamie Buckley 2013-04-02

    Hi Mads, This bug does not occur in later versions of Titanium, from version 3.0.0 please try it.
  2. Mads Moller 2013-04-03

    So? Thats irrelevant. Most modules are still compiled with 2.x for compatibility reasons. Even your own open source modules are something compiled with 1.x. Can you provide a hotfix for this? Mads
  3. Jeff English 2013-06-17

    The problem is that 'markdown' is being called with a non-markdown file by the build script -- Try placing the image files into a 'documentation/images' folder rather than directly into the 'documentation' folder. You will need to update your image references in the documentation to include the 'images' path.
  4. Ingo Muschenetz 2013-07-29

    Given that this works in 3.X+ and there is a workaround for 2.1.X, we do not have the bandwidth to fix this at this time.
  5. Mads Moller 2013-07-29

    Hi Ingo, Huh, does 3.x have a module api yet? How do I compile a module with 3.x. I asked Chris Barber, but he said it was coming. Can you please show me how to use it? Its cool you dont wanna fix the old one.. Cheers, Mads
  6. Lee Morris 2017-03-30

    Closing ticket as "Won't Fix". There has been no update for quite a while. If there is any problem, please open a new ticket.

JSON Source