run_foreman.py issue: cannot import name monthdelta

Issue #58 new
Former user created an issue
$ sudo run_foreman.py run_server /home/foreman/config/config_template.ini
Binding to database
Traceback (most recent call last):
 File "run_foreman.py", line 120, in <module>
  args.func(args)
File "run_foreman.py", line 22, in runserser
 app = make_app(args.config_file)
 File "run_foreman.py", line 14, in make_app
  from foreman.application import make_app
 File "home/foreman/controllers/application.py", line 10, in <module>
  from controllers import controller_lookup
 File "/home/foreman/controllers/__init__.py", line 1, in <module>
  from controllers import GeneralController
 File "/home/foreman/generalController.py", line 4, in <module>
  from monthdelta import MonthDelta
ImportError: cannot import name MonthDelta

Comments (2)

  1. Linklinsse

    I have the same issue, but with setup and more info :

    sudo run_foreman.py setup /home/foreman/config/config.ini
    

    config.ini changed :

    database_name = foreman

    port_number = 5432

    database_type = postgres

    database_location = localhost

    ...

    website_domain = http://foreman:5000/

    ==================Something Suspicius==================

    python2.7
    Python 2.7.12 (default, Dec    4 2017, 14:50:18)
    [GCC 5.4.0 20160609] on linux2
    Type "help", "copyright", "credits" or "license" for more information.
    >>> import monthdelta
    >>> from monthdelta import MonthDelta
    Traceback (most recent call last):
         File "<stdin>", line 1, in <module>
    ImportError: cannot import name MonthDelta
    >>> exit()
    

    I suppose that the new version of monthdelta with does this ¯\(ツ)/¯ , the question is maybe witch version to use?

    ==================Machine info==================

    All installed with setup.py

    monthdelta version = 0.9.1

    I use a vm of ubuntu-serveur 16.04 LTS (so every code is manualy write, sorry for mistakes)

    Thanks for answer 😄

  2. Linklinsse

    I think i have figured out, it is strange that setup.py install the 0.9.1 version and not the 1.0b

    this seems to correct it :

    sudo pip uninstall monthdelta
    sudo pip uninstall monthdelta==1.0b
    sudo pip install -Iv monthdelta==1.0b
    
  3. Log in to comment