プロジェクト

全般

プロフィール

Vote #69129

完了

Python multiline comments highlighting problem in Repository browser

Admin Redmine さんが約4年前に追加. 約4年前に更新.

ステータス:
Closed
優先度:
通常
担当者:
-
カテゴリ:
Third-party libraries_47
対象バージョン:
開始日:
2022/05/09
期日:
進捗率:

0%

予定工数:
category_id:
47
version_id:
40
issue_org_id:
7495
author_id:
26903
assigned_to_id:
0
comments:
8
status_id:
5
tracker_id:
1
plus1:
0
affected_version:
closed_on:
affected_version_id:
42
ステータス-->[Closed]

説明

When viewing Python code (from an SVN repo) in the repository viewer multiline PyDoc style comments aren't highlighted correctly.

For example, the multiline comment in this ticket will highlight correctly, but not in the source viewer.


#!/usr/bin/python

def foo(bar):
    """Takes a bar and converts to a foo.
    This is not a good idea."""
    return bar

In the repository source viewer only the first line is highlighted.

We're running Redmine trunk r4786. I'm using Chrome on Linux.

About your application's environment
Ruby version              1.8.7 (x86_64-linux)
RubyGems version          1.3.5
Rack version              1.0
Rails version             2.3.5
Active Record version     2.3.5
Active Resource version   2.3.5
Action Mailer version     2.3.5
Active Support version    2.3.5
Application root          /home/redmine/redmine
Environment               production
Database adapter          mysql
Database schema version   20101114115359

journals

This actually happens to me also. I was wondering why it wasn't highlighting the multiline strings correctly.
--------------------------------------------------------------------------------
It's a "CodeRay issue":http://redmine.rubychan.de/issues/190 which has already been fixed in trunk. Next release, due in 16 days, (1.0 RC1 !) should include the fix.

--------------------------------------------------------------------------------
Etienne Massip wrote:
> It's a "CodeRay issue":http://redmine.rubychan.de/issues/190 which has already been *fixed in trunk* [...]

I presume you are talking about the trunk in the SCM of CodeRay, thus not Redmine trunk?!

Etienne Massip wrote:
> Next release, due in 16 days, *(1.0 RC1 !)* should include the fix.

Since CodeRay 1.0 final might not make in into Redmine 1.3.0 I've created issue #8255 by copying issue #4264, changed issue-relations to reflect the "upstream roadmap":http://redmine.rubychan.de/projects/coderay/roadmap:

| - | related to Feature #4264: Update CodeRay to 1.0 final|
| + | related to Feature #8255: Consider updating CodeRay to 1.0 RC-x|

and changed to new - more appropriate - category...
--------------------------------------------------------------------------------
Mischa The Evil wrote:
> I presume you are talking about the trunk in the SCM of CodeRay, thus not Redmine trunk?!

Indeed, sorry.

> Since CodeRay 1.0 final might not make in into Redmine 1.3.0 I've created issue #8255 by copying issue #4264, changed issue-relations to reflect the "upstream roadmap":http://redmine.rubychan.de/projects/coderay/roadmap:
>
> | - | related to Feature #4264: Update CodeRay to 1.0 final|
> | + | related to Feature #8255: Consider updating CodeRay to 1.0 RC-x|
>
> and changed to new - more appropriate - category...

I just changed the relation to #8255 as a "blocked by", if it is ok for you ?
--------------------------------------------------------------------------------
Actually it is not a CodeRay issue, it's a Redmine issue which is not easy to fix since it is due to RM slicing the syntax highlighter's output to insert line numbering, breaking the HTML tree and thus the style inheritance.

And if we rely on CodeRay line numbering as suggested by #3382, then I guess this will definitely deny line wrapping, which may be annoying when viewing code attachments.

Any thoughts?
--------------------------------------------------------------------------------
Blocked by "CodeRay issue 222":http://redmine.rubychan.de/issues/222.
--------------------------------------------------------------------------------
Fixed with r9389 but not merged. Part of version:1.4.0?
--------------------------------------------------------------------------------
Merged, thanks.
--------------------------------------------------------------------------------


related_issues

relates,Closed,4264,Update CodeRay to 1.0 final

Admin Redmine さんが約4年前に更新

  • カテゴリThird-party libraries_47 にセット
  • 対象バージョン1.4.0_40 にセット

他の形式にエクスポート: Atom PDF

いいね!0
いいね!0