1. Marcin Kuzminski
  2. RhodeCode
  3. Issues

Issues

Issue #880 resolved

AttributeError: 'RootNode' object has no attribute 'extension'

Gili
created an issue

When I invoke paster make-index production.ini -f I get:

2013-07-10 16:40:53.661 INFO  [rhodecode.model] initializing db for mysql://rhod
ecode:XXXXX@127.0.0.1/rhodecode
2013-07-10 16:40:53.987 INFO  [rhodecode.model.scm] scanning for repositories in
 C:\Users\Gili\Documents\MercurialRepositories
Traceback (most recent call last):
  File "c:\Users\Gili\Documents\rhodecode\Scripts\paster-script.py", line 8, in
<module>
    load_entry_point('PasteScript==1.7.5', 'console_scripts', 'paster')()
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\paste\script\command
.py", line 104, in run
    invoke(command, command_name, options, args[1:])
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\paste\script\command
.py", line 143, in invoke
    exit_code = runner.run(args)
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\utils.py", line 720, in run
    return super(BasePasterCommand, self).run(args[1:])
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\paste\script\command
.py", line 238, in run
    result = self.command()
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\paster_commands\make_index.py", line 82, in command
    .run(full_index=self.options.full_index)
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\indexers\daemon.py", line 439, in run
    self.build_indexes()
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\indexers\daemon.py", line 424, in build_indexes
    self.index_files(file_idx_writer, repo_name, repo)
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\indexers\daemon.py", line 253, in index_files
    i, iwc = self.add_doc(file_idx_writer, idx_path, repo, repo_name)
  File "c:\Users\Gili\Documents\rhodecode\lib\site-packages\rhodecode-1.7.1-py2.
7.egg\rhodecode\lib\indexers\daemon.py", line 169, in add_doc
    if node.extension in INDEX_EXTENSIONS and not node.is_binary:
AttributeError: 'RootNode' object has no attribute 'extension'

Comments (9)

  1. Anton Volkov

    I have faced with the same problem. Is there any solution to this? I tried to delete whole "data/index" directory, but make-index command keeps saying that: AttributeError: 'RootNode' object has no attribute 'extension' ...

  2. Marcin Kuzminski repo owner

    I need some additional info about that issue to be able to deal with it. Can you somehow extract what nodes it breaks, maybe it's a symlink stuff ? Or best would be to get an example repository that does triggers that error.

  3. Anton Volkov

    Thank you for the quick response!

    I'm pretty sure that the problem is more related to the environment and not the repository itself, because I tried to remove all my repositories except a very simple one (you may download it here), however "make-index" script continues to stumble over.

    Here is the environment I'm using:

    • Windows Server 2012 R2 English
    • Latest Rhodecode (2.2.4) installed from scratch (i.e. without upgrades) onto a clean Windows (there is no other python based software there)
    • MySQL 5.5.35 (pretty sure it's not involved here)
    • Repositories location: "F:\HG Repositories" (just in case with full access applied to "Everyone")
    • Windows' regional settings set in the Control Panel are as follows:

    • Region->Formats -> "Japanese (Japan)"

    • Region->Location -> "Japan"
    • Region->Administrative -> Language for non-Unicode programs -> "English (United States)"

    That's all that I found worth mentioning. If you need something else please let me know.

    PS. Just in case, here is the full error log I get:

    C:\Program Files (x86)\RhodeCode Enterprise>"C:\Program Files (x86)\RhodeCode Enterprise\system\Scripts\paster" make-ind
    ex "C:\Program Files (x86)\RhodeCode Enterprise\data\production.ini" -f
    2014-01-15 23:52:20.923 INFO  [rhodecode.model] initializing db for mysql://root:XXXXX@localhost:3306/rhodecode
    2014-01-15 23:52:21.173 INFO  [rhodecode.model.scm] scanning for repositories in F:\HG Repositories
    Traceback (most recent call last):
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Scripts\paster-script.py", line 12, in <module>
        load_entry_point('PasteScript==1.7.5', 'console_scripts', 'paster')()
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\paste\script\command.py", line 104, in run
        invoke(command, command_name, options, args[1:])
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\paste\script\command.py", line 143, in invo
    ke
        exit_code = runner.run(args)
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\utils.py", line 757, in run
        return super(BasePasterCommand, self).run(args[1:])
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\paste\script\command.py", line 238, in run
        result = self.command()
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\paster_commands\make_index.py
    ", line 84, in command
        .run(full_index=self.options.full_index)
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\indexers\daemon.py", line 443
    , in run
        self.build_indexes()
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\indexers\daemon.py", line 428
    , in build_indexes
        self.index_files(file_idx_writer, repo_name, repo)
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\indexers\daemon.py", line 257
    , in index_files
        i, iwc = self.add_doc(file_idx_writer, idx_path, repo, repo_name, index_rev)
      File "C:\Program Files (x86)\RhodeCode Enterprise\system\Lib\site-packages\rhodecode\lib\indexers\daemon.py", line 172
    , in add_doc
        if node.extension in INDEX_EXTENSIONS and not node.is_binary:
    AttributeError: 'RootNode' object has no attribute 'extension'
    

    Thank you, Anton

  4. Log in to comment