Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unable to use crontab #11

Closed
amelio-vazquez-reina opened this issue Dec 22, 2014 · 1 comment
Closed

Unable to use crontab #11

amelio-vazquez-reina opened this issue Dec 22, 2014 · 1 comment

Comments

@amelio-vazquez-reina
Copy link

I have tried installing crontab as:

> pip install crontab

and as:

> pip install git+git://github.com/josiahcarlson/parse-crontab

on both Python 2.7.x and Python 3.4.x without luck.

However, whenever I invoke:

from crontab import CronTab
system_cron   = CronTab()
my_user_cron  = CronTab(user=True)
users_cron    = CronTab(user='dataxu')

I get:

> system_cron   = CronTab()
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-7-4132e81e1caa> in <module>()
----> 1 system_cron   = CronTab()

TypeError: __init__() missing 1 required positional argument: 'crontab'

Why?

@josiahcarlson
Copy link
Owner

You have either installed the wrong crontab package, or you are looking at the wrong docs/demos.

The docs/demos that you included above with system_cron = CronTab() is from a different crontab package: https://pypi.python.org/pypi/python-crontab .

The crontab package you installed is: https://pypi.python.org/pypi/crontab .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants