Recommended Python Atom feed generator? [closed] - python

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 1 year ago.
Improve this question
Which Python library is commonly used today to generate Atom feeds?
Note, there exists a very similar question from 2008, but its answers are mostly obsolete. The library atomxlib was recommended, but it apparently is obsolete (also the website does not exist anymore).

For future Googlers, the recommended library (WebHelpers) doesn't support Python 3, and it appears to be abandoned. There was a rewrite, WebHelpers2, but it doesn't include the feed generator, and it seems to be end-of-lifed. "Version 2.0 is the final release."
feedgen looks more up to date, it can generate both Atom and RSS feeds, and it supports Python 3 (as well as Python 2).

It's a surprisingly non trivial question.
Looking into what known projects are using, that generates rss, my two main options are:
python-feedgen is popular and documented, but (in 2021-05-01) don't have activity since the beginning of 2020.
feedgenerator with recent activity and used by 2.7k projects, but with minimal documentation (or you have to extrapolate from django rss docs)
rfeed, but have a strange PyPI publication method and (in 2021-05-01) don't have activity since the beginning of 2020.

I use webhelpers.feedgenerator. It supports Atom1 feeds.

How about rfeed?
Another one I found is the AtomFeed from Werkzeug (Atom Syndication), but the functionality is removed since the version 1.0. So I found a fork at feedwerk.

I would use one of the many templating systems out there (like Jinja2, Mako, ...)

Maybe you could reuse Django's syndication feed framework. Altough you should notice that it's usually best practice to write it by yourself because generating XML is rather simple and there's few value in using a generator as is, as mentioned by lazy1.

Related

Canonicalisation of usernames [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 1 year ago.
Improve this question
What is the best way to get a canonical representation of a username that is idempotent?
I want to avoid having the same issue as Spotify: http://labs.spotify.com/2013/06/18/creative-usernames/
I'm looking for a good library to do this in Python. I would prefer not to do what Spotify ended up doing (running the canonicalisation twice to test if it is idempotent), and importing Twisted into my project is a tad overkill, is there a stand-alone library for this?
Would using email addresses instead be preferred when it comes to usernames? How do major sites/companies deal with this?
First your should read Wikipedia's article on Unicode equivalence. It explains the caveats and which normalization methods there are to represent an Unicode string in its canonical form.
Then you can use Python's built-in module unicodedata to do the normalization of the Unicode string to your preferred normalization form.
A code example:
>>> import unicodedata
>>> unicodedata.normalize('NFKC', u'ffñⅨffi⁵KaÅéᴮᴵᴳᴮᴵᴿᴰ')
'ffñIXffi5KaÅéBIGBIRD'
>>> unicodedata.normalize('NFKC', u'ffñⅨffi⁵KaÅéᴮᴵᴳᴮᴵᴿᴰ').lower()
'ffñixffi5kaåébigbird'
For anyone reading this a few months later:
The module that Spotify uses isn't all that hard to pull out of Twisted without a whole bunch of dependencies (Twisted can be removed entirely with close to no effort, it's only imported for version check purposes). zope.interface is the only dependency left behind, though it should be removable with a decent bit of effort.
The heart of that module is unicodedata.normalize(), so if you want to roll your own implementation out, that's where you should be starting. But like others have said, be careful, this is an area that's open to easy exploits.
EDIT: I stripped out the zope and twisted dependencies: https://gist.github.com/repole/7548478

Python tools/libraries for Semantic Web: state of the art? [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
What are the best (more or less mature, supporting more advanced logic, having acceptable performance, scalable to some extent) open source Semantic Web libraries and tools (RDF storage, reasoning, rules, queries) for Python nowadays? Historically Python tools (cwm) were among the first to appear, but it still seems that everyone uses Java back-ends for performance and Python as mere client if at all. My purpose is to learn the technology and maybe some future use in production system if it proves itself up to the task. The task is not yet defined, but as I see it its building a knowledge base, linked with some external resources, and customized facet-navigable web front-end.
If some building blocks based on Python are not good enough, then what is the suitable piece from Java/C/C++/whatever world.
Typical stack is also of interest, if there are one or two clear winners.
Thanks.
A survey of of Python libraries and tools for Semantic Web programming is available here. It includes libraries for working with RDF as well as Python-friendly triple stores.
Toby Segaran's book Programming the Semantic Web also has a lot of programming examples in Python.
You could check out the pyswip. It could work with the SWI-Prolog. Wish it would fit for requirement. :)
To name some, check out RDFLib and CubicWeb.

List of Python Object Databases [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 4 years ago.
Improve this question
I am looking for an object database for Python (no handmade pickles :D).
What are my options (besides the obvious ZODB)?
Dobbin. Somewhat similar to ZODB, but much simpler. It looks nice but I haven't tried it myself. I haven't been able to find much information about it. It has been at version 0.2 for over a year. I don't know if it is still being actively maintained, if it is reliable enough for mission-critical applications.
From the description on the site, the main difference between Dobbin and other object databases is that persisted objects are read-only unless they are explicitly "checked out". This may make dealing with objects a little trickier, but it may make the database faster and more memory-efficient.
MongoDB perhaps comes close - not object oriented but document-oriented and coming close to object databases.
handmade shelves? ;-)
Durus?
SqlAlchemy? it's not an object database, but chances are that you could use it
Check PersistenceTools on the python.org wiki, which mentions a few that might count. (the DatabaseProgramming page also mentions Matisse under "Non-relational Databases", I don't know it, just mention it because for some reason, it's not included on that other page)
DyBASE by Konstantin Knizhnik who developed a lot of embedded databases for multiple programming languages. It has transactions and indices. There are tests in the distribution and I use it myself for persisting elements in a Python Queue. My example is also available at github as python-persistence-queue
Cog:
Seems not updating for a long time.
itamarst.org/software/cog
And this is a paper on 6th International Python conf. about object database.
https://legacy.python.org/workshops/1997-10/proceedings/shprentz.html

Looking for knowledge base integrated with bug tracker in python [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 5 years ago.
Improve this question
Ok, I am not sure I want to use Request Tracker and RTFM, which is a possible solution.
I'd like to have a knowledge base with my bug tracker/todo list , so that when
I solve a problem, I would have a record of its resolution for myself or others later.
What python based solutions are available?
A highly flexible issue tracker in Python I would recommend is "Roundup":
http://roundup.sourceforge.net/.
An example of its use can be seen online at http://bugs.python.org/.
Try Trac
I do have experience using probably 20-30 different bug trackers, installed or hosted and so far if you are up to deal with a big number of bugs and you want to spend less time coding-the-issues-tracker, to get Atlassian Jira, which is free for open-source projects.
Yes, it's not Python, it is Java, starts slowly and requires lots of resources. At the same time, RAM is far less expensive than your own time and if you want to extend the system you can do it in Python by using https://pypi.python.org/pypi/jira-python/
Do you think that Jira is the most used bug tracker for no reason? It wasn't the first on the market, in fact is quite new compared with others.
Once deployed you can focus on improving the workflows instead of patching the bug tracker.
One of the best features that it has is the ability to link to external issues and be able to see their status, without having to click on them. As an warning, for someone coming from another tracekr you may discover that there are some design limitations, like the fact that a bug can have a single assignee. Don't be scared about it, if you look further you will find that there are way to assign tickets to groups of peoples.

Python source code collection [closed]

Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
We don’t allow questions seeking recommendations for books, tools, software libraries, and more. You can edit the question so it can be answered with facts and citations.
Closed 7 years ago.
Improve this question
Does anyone know anywhere there's a wide collection of Python source code on the net with decent documentation? If so, can someone post it up here?
Perhaps the Python Standard Library? Or are you looking for something more specific?
I am not sure what you meant by "source code"? Source code of Python libraries or code examples and recipes?
Well the link to Python STL is great (#zenazn).
In addition to that if you are looking for specific issues and their solutions and recipes, I will suggest:
http://code.activestate.com/recipes/langs/python/
Stack overflow itself.
Though you won't find much documentation at these sources, but that is supplemented by great answers, comments and discussions.
you can find a huge number of python libraries at the cheese shop.
A great place covering several libraries with very clear examples is:
http://nullege.com/codes/
I like:
The Python Cookbook
Google Code Search
The cpython source code (the original python project) is at http://hg.python.org/cpython/file/default/
Not the Python itself but the 3rd party package source codes that you can even search within the source codes:
http://pydoc.net/

Categories

Resources