Skip to content

Live API docs (#4755) makes markdown dependency non-optional #4941

@carltongibson

Description

@carltongibson

rest_framework.templatetags.rest_framework is non-conditionally importing markdown.

from markdown.extensions.fenced_code import FencedBlockPreprocessor

from rest_framework.compat import (
    NoReverseMatch, markdown, reverse, template_render
)

https://github.com/tomchristie/django-rest-framework/blob/master/rest_framework/templatetags/rest_framework.py#L12-L16

As per the compat import markdown has previously been an optional dependency. It's still listed as an optional requirement

Without markdown installed, the template tags can no longer be imported. cf carltongibson/django-filter#658

Markdown either needs to be declared required or a work around is needed.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy