Code Monkey home page Code Monkey logo

Comments (1)

jspeed-meyers avatar jspeed-meyers commented on September 25, 2024

I am also supportive of removing a dependency that provides little benefit. I tried to replace uritools functions with urllib equivalents and hit some issues though.

While debugging I noticed this:

(
creation_info_fixture(document_namespace="some_namespace"),
DOCUMENT_SPDX_ID,
"document_namespace must be a valid URI specified in RFC-3986 and must contain no fragment (#), "
"but is: some_namespace",
),

And then further noticed that the Python standard libary urllib module says:

RFC 3986 is considered the current standard and any future changes to
urlparse module should conform with it.  The urlparse module is
currently not entirely compliant with this RFC due to defacto
scenarios for parsing, and for backward compatibility purposes, some
parsing quirks from older RFCs are retained. The testcases in
test_urlparse.py provides a good indicator of parsing behavior.

I wonder if urllib not being compliant with RFC 3986 is why uritools is used instead of urllib? Maybe the need for compliance with RFC 3986 is strong enough to merit adding a dependency on uritools? I personally don't know. But when I tried some simple replacements, it didn't go well :)

from tools-python.

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.