elpaso / django-dag

Basic portable Directed Acyclic Graph application for Django
66 stars 19 forks source link

Pypi package is broken and no explicit license #7

Closed constfun closed 9 years ago

constfun commented 11 years ago

The package on pypi is outdated and has a typo on it that prevents the module from being loaded.

Also, it would be nice if you could include a license.

elpaso commented 11 years ago

Done,

even if I still don't understand the need to attach a copy of the (well known) AGPLv3 license even when it's stated everywhere that that is the applied licence.

constfun commented 11 years ago

Before posting the issue, I looked in the various readme files and at the top of the code and didn't see any mention of a license.

Now I see that setup.py does list the license.

wilbertom commented 9 years ago

PyPi version is broken. I did a patch to my local version.

(storybase)~/Code/tdf/storybase (staff-badges) wil
>>> diff /home/wil/.virtualenvs/storybase/lib/python2.7/site-packages/django_dag/models.py models.py
40a41
>         disable_check = args.pop('disable_circular_check', False)
42c43
<         return cls.save()
---
>         return cls.save(disable_circular_check=disable_check)
138c139
<         return bool(self.children.count() and not self.ancestors_set())
---
>         return bool(self.children.exists() and not self._parents.exists())
144c145
<         return bool(self.ancestors_set() and not self.children.count())
---
>         return bool(self._parents.exists() and not self.children.exists())
150c151
<         return bool(not self.is_root() and not self.is_leaf())
---
>         return bool(not self.children.exists() and not self._parents.exists())
220c221
<         node_model_name = node_mode._meta.module_name
---
>         node_model_name = node_model._meta.module_name
233c234,235
<             self.parent.__class__.circular_checker(self.parent, self.child)
---
>             if not kwargs.pop('disable_circular_check', False):
>                 self.parent.__class__.circular_checker(self.parent, self.child)
251c253,254
<                 through     = edge_model)
---
>                 through     = edge_model,
>                 related_name = '_parents') # NodeBase.parents() is a function
(storybase)~/Code/tdf/storybase (staff-badges) wil

I only reamed node_mode._meta.module_name to node_model._meta.module_name locally so that it would run. Hopefully this is the only change I needed.

@elpaso sorry if I'm wrong about this.

elpaso commented 9 years ago

Can you please make a pull request with the changes?

wilbertom commented 9 years ago

Hey @elpaso, the changes you saw were between the version installed via pip django-dag==1.1 and your master branch. node_model._meta.module_name was misspelled as node_mode._meta.module_name. This is totally on me for using an old version. So no pull request needed. You already fixed it.

The weird parts are the differences between your PyPi and Github versions.

/tmp wil
>>> wget https://pypi.python.org/packages/source/d/django-dag/django-dag-1.2.tar.gz
--2015-02-12 10:00:24--  https://pypi.python.org/packages/source/d/django-dag/django-dag-1.2.tar.gz
Resolving pypi.python.org (pypi.python.org)... 23.235.40.223
Connecting to pypi.python.org (pypi.python.org)|23.235.40.223|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 3235 (3.2K) [application/octet-stream]
Saving to: ‘django-dag-1.2.tar.gz’

django-dag-1.2.tar.gz     100%[======================================>]   3.16K  --.-KB/s   in 0.001s 

2015-02-12 10:00:24 (3.51 MB/s) - ‘django-dag-1.2.tar.gz’ saved [3235/3235]
/tmp wil
>>> tar -zxvf django-dag-1.2.tar.gz 
django-dag-1.2/
django-dag-1.2/README
django-dag-1.2/django_dag/
django-dag-1.2/django_dag/__init__.py
django-dag-1.2/django_dag/models.py
django-dag-1.2/MANIFEST.in
django-dag-1.2/setup.py
django-dag-1.2/PKG-INFO
/tmp wil
>>> git clone https://github.com/elpaso/django-dag
Cloning into 'django-dag'...
remote: Counting objects: 107, done.
remote: Total 107 (delta 0), reused 0 (delta 0)
Receiving objects: 100% (107/107), 19.70 KiB | 0 bytes/s, done.
Resolving deltas: 100% (45/45), done.
Checking connectivity... done.
/tmp wil
>>> diff django-dag django-dag-1.2
Common subdirectories: django-dag/django_dag and django-dag-1.2/django_dag
Only in django-dag: django_dag_test
Only in django-dag: .git
Only in django-dag: .gitignore
Only in django-dag: __init__.py
Only in django-dag: manage.py
Only in django-dag: MANIFEST
Only in django-dag-1.2: PKG-INFO
Only in django-dag: settings.py
diff django-dag/setup.py django-dag-1.2/setup.py
6c6
< version = '1.1'
---
> version = '1.2'
31c31
<     license='GNU Affero General Public License v3',
---
>     license='LICENSE.txt',
34d33
<     #package_data={'dag': ['templates/admin/*.html']},
37a37,39
>     install_requires=[
>         "Django >= 1.1.1",
>     ],
Only in django-dag: urls.py

Your master branch is versioned 1.1 and PyPi 1.2. Did you forget to git push after updating PyPi? Commands to replicate if my shell is confusing are:

wget https://pypi.python.org/packages/source/d/django-dag/django-dag-1.2.tar.gz
tar -zxvf django-dag-1.2.tar.gz 
git clone https://github.com/elpaso/django-dag
diff django-dag django-dag-1.2

Again, I might be wrong and if so, sorry!

elpaso commented 9 years ago

I've rewritten some tests and bumped to 1.3, now tested on Django 1.7