def render_compressed_sources(self, package, package_name, package_type):
        """Render HTML for using the package's list of source files.

        Each source file will first be collected, if
        ``PIPELINE_COLLECTOR_ENABLED`` is ``True``.

        If there are any errors compiling any of the source files, an
        ``SHOW_ERRORS_INLINE`` is ``True``, those errors will be shown at
        the top of the page.

        Subclasses can override this method to provide custom behavior for
        rendering the source files.
        """
        if settings.PIPELINE_COLLECTOR_ENABLED:
            default_collector.collect(self.request)

        packager = Packager()
        method = getattr(self, 'render_individual_{0}'.format(package_type))

        try:
            paths = packager.compile(package.paths)
        except CompilerError as e:
            if settings.SHOW_ERRORS_INLINE:
                method = getattr(self, 'render_error_{0}'.format(
                    package_type))

                return method(package_name, e)
            else:
                raise

        templates = packager.pack_templates(package)

        return method(package, paths, templates=templates)
def render_compressed_sources ( self , package , package_name , package_type ) : if settings . PIPELINE_COLLECTOR_ENABLED : default_collector . collect ( self . request ) packager = Packager ( ) method = getattr ( self , 'render_individual_{0}' . format ( package_type ) ) try : paths = packager . compile ( package . paths ) except CompilerError as e : if settings . SHOW_ERRORS_INLINE : method = getattr ( self , 'render_error_{0}' . format ( package_type ) ) return method ( package_name , e ) else : raise templates = packager . pack_templates ( package ) return method ( package , paths , templates = templates )
Render HTML for using the package's list of source files.

        Each source file will first be collected, if
        ``PIPELINE_COLLECTOR_ENABLED`` is ``True``.

        If there are any errors compiling any of the source files, an
        ``SHOW_ERRORS_INLINE`` is ``True``, those errors will be shown at
        the top of the page.

        Subclasses can override this method to provide custom behavior for
        rendering the source files.