Coder Social home page Coder Social logo

Comments (4)

nickjj avatar nickjj commented on May 18, 2024

Hi,

Thanks for the report.

Are you running Windows in production? Just asking because under normal circumstances you wouldn't be running the digest command in development.

from flask-static-digest.

Shimada666 avatar Shimada666 commented on May 18, 2024

No, it's in development. And I mean, In windows, the function static_url_for doesn't work. The example you provided doesn't seem to work in Windows.

In the sample program:

127.0.0.1 - - [14/Nov/2019 23:10:35] "GET / HTTP/1.1" 500 -
Traceback (most recent call last):
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 2309, in call
return self.wsgi_app(environ, start_response)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 2295, in wsgi_app
response = self.handle_exception(e)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 1741, in handle_exception
reraise(exc_type, exc_value, tb)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask_compat.py", line 35, in reraise
raise value
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 2292, in wsgi_app
response = self.full_dispatch_request()
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 1815, in full_dispatch_request
rv = self.handle_user_exception(e)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 1718, in handle_user_exception
reraise(exc_type, exc_value, tb)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask_compat.py", line 35, in reraise
raise value
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 1813, in full_dispatch_request
rv = self.dispatch_request()
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 1799, in dispatch_request
return self.view_functionsrule.endpoint
File "F:\PycharmProjects\flask-static-digest\tests\example_app\example\app.py", line 16, in index
return render_template("index.html")
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\templating.py", line 135, in render_template
context, ctx.app)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\templating.py", line 117, in render
rv = template.render(context)
File "f:\redrock\py\pycharmprojects\lib\site-packages\jinja2\asyncsupport.py", line 76, in render
return original_render(self, *args, **kwargs)
File "f:\redrock\py\pycharmprojects\lib\site-packages\jinja2\environment.py", line 1008, in render
return self.environment.handle_exception(exc_info, True)
File "f:\redrock\py\pycharmprojects\lib\site-packages\jinja2\environment.py", line 780, in handle_exception
reraise(exc_type, exc_value, tb)
File "f:\redrock\py\pycharmprojects\lib\site-packages\jinja2_compat.py", line 37, in reraise
raise value.with_traceback(tb)
File "F:\PycharmProjects\flask-static-digest\tests\example_app\example\templates\index.html", line 1, in top-level template code
{% extends 'layout.html' %}
File "F:\PycharmProjects\flask-static-digest\tests\example_app\example\templates\layout.html", line 5, in top-level template code
href="{{ static_url_for('static', filename='css/app.css') }}">
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask_static_digest_init
.py", line 74, in static_url_for
return flask_url_for(endpoint, **merged_values)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\helpers.py", line 356, in url_for
return appctx.app.handle_url_build_error(error, endpoint, values)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\app.py", line 2061, in handle_url_build_error
reraise(exc_type, exc_value, tb)
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask_compat.py", line 35, in reraise
raise value
File "f:\redrock\py\pycharmprojects\lib\site-packages\flask\helpers.py", line 345, in url_for
force_external=external)
File "f:\redrock\py\pycharmprojects\lib\site-packages\werkzeug\routing.py", line 1776, in build
raise BuildError(endpoint, values, method, self)
werkzeug.routing.BuildError: Could not build url for endpoint 'static'. Did you forget to specify values ['filename']?

from flask-static-digest.

Shimada666 avatar Shimada666 commented on May 18, 2024

Hey, could you check my PR? I want to use this plugin in my project.

from flask-static-digest.

nickjj avatar nickjj commented on May 18, 2024

Windows support is available now in v0.1.3.

from flask-static-digest.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.