Commit de0fa93d by Serbaf

Merge branch 'develop'

Pretty stable release with the basic intended functionality
parents a8d5c543 90680e39
......@@ -6,3 +6,28 @@ History
------------------
* First release on PyPI.
0.2.0 (2019-03-20)
------------------
* Completed the Tweet class that allows the user to make usable instances of a
tweet model. Includes initialization of all the Tweet attributes indicated in
the Twitter documentation (default to None, unless the user provides a value)
and overriding of __getitem__ to provide a dictionary-like access to the
information.
0.3.0 (2019-03-20)
------------------
* Added method "get_tweets_from_csv()", which gets a CSV file as an argument
and returns a list containing as many Tweet objects as lines (minus the
header) in the CSV file. The header of the CSV is used to know which
attributes should be set.
* The method will raise an error and exit if any item in the header does not
match with the specification of the Tweet object (for example, the header
word "media.sizes.thumb.h" would be valid, but "user.lightsaber.color" would
not.
* At this point, the method took 1.75s aprox to read and return the contents of
a 5.7 MB as a list of 'Tweet's. This could be troublesome with very large
collections in a future if the progression of time was proportional with the
file size (estimation would be 25 minutes for a 5 GB file)
......@@ -3,11 +3,8 @@ Tweet Model
===========
.. image:: https://img.shields.io/pypi/v/tweet_model.svg
:target: https://pypi.python.org/pypi/tweet_model
.. image:: https://img.shields.io/travis/Serbaf/tweet_model.svg
:target: https://travis-ci.org/Serbaf/tweet_model
.. image:: https://img.shields.io/pypi/v/tweet_model_serpucga.svg
:target: https://pypi.python.org/pypi/tweet_model_serpucga
.. image:: https://readthedocs.org/projects/tweet-model/badge/?version=latest
:target: https://tweet-model.readthedocs.io/en/latest/?badge=latest
......@@ -28,10 +25,20 @@ Dashboard project.
Features
--------
* TODO
* A modelization of a tweet in the form of class Tweet. This class contains a
constructor that initializes all the possible tweet attributes to None
except those indicated otherwise.
* The inner objects of a tweet ("user", "entities", "places", etc.) are stored
internally as nested dictionaries.
* The __getitem__() method for Tweet is overriden to allow a dictionary-like
access to the tweet contents. For example, if "tweet1" is an instance of
Tweet, one could do tweet1["id"] to get the id of that tweet, or
tweet1["user"]["name"] to get the name of the person that published the
tweet.
Credits
-------
Creator: Sergio
This package was created with Cookiecutter_ and the `audreyr/cookiecutter-pypackage`_ project template.
......
......@@ -8,4 +8,5 @@ coverage==4.5.1
Sphinx==1.8.1
twine==1.12.1
# App requirements
tweetmanager-serpucga==1.1.4
......@@ -13,9 +13,9 @@ with open('HISTORY.rst') as history_file:
requirements = ['Click>=6.0', ]
setup_requirements = [ ]
setup_requirements = []
test_requirements = [ ]
test_requirements = []
setup(
author="Sergio Puche García",
......@@ -33,7 +33,8 @@ setup(
'Programming Language :: Python :: 3.6',
'Programming Language :: Python :: 3.7',
],
description="A modelization of a tweet object with convenient features and functionalities",
description="A modelization of a tweet object with convenient features " +
"and functionalities",
entry_points={
'console_scripts': [
'tweet_model=tweet_model.cli:main',
......@@ -44,12 +45,12 @@ setup(
long_description=readme + '\n\n' + history,
include_package_data=True,
keywords='tweet_model',
name='tweet_model',
name='tweet_model_serpucga',
packages=find_packages(include=['tweet_model']),
setup_requires=setup_requirements,
test_suite='tests',
tests_require=test_requirements,
url='https://github.com/Serbaf/tweet_model',
version='0.1.0',
version='0.3.3',
zip_safe=False,
)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment