Modify

Opened 6 years ago

Closed 2 years ago

#4344 closed defect (fixed)

[Patch] Missing files in in .egg

Reported by: Niels B. Owned by: coderanger
Priority: high Component: ThemeEnginePlugin
Severity: normal Keywords: theme 0.11
Cc: Trac Release: 0.11

Description

I built the plugin with the latest sources from svn/trunk. Then I installed the plugin via WebAdmin. When testing the plugin in my trac/admin/theme panel, the preview images didn't show. My error log was telling me that several files were missing.

My best guess is that setup.py is missing some files in the "package_data" section.
This worked for me:

#!/usr/bin/env python
# -*- coding: iso-8859-1 -*-

from setuptools import setup

setup(
    name = 'TracThemeEngine',
    version = '2.0',
    packages = ['themeengine'],
    package_data = { 'themeengine': ['templates/*.html', 'htdocs/*.*', 'htdocs/img/*.*', 'htdocs/*.js', 'htdocs/*.css', 'htdocs/skins/ie7/*.*', 'htdocs/skins/sweetie/*.*', 'htdocs/skins/tango/*.*' ] },

    author = 'Noah Kantrowitz',
    author_email = 'noah@coderanger.net',
    description = 'Provide a modular interface to styling Trac.',
    license = 'BSD',
    keywords = 'trac plugin theme style',
    url = 'http://trac-hacks.org/wiki/ThemeEnginePlugin',
    classifiers = [
        'Framework :: Trac',
    ],
    
    install_requires = ['Trac>=0.11dev-r6696'],

    entry_points = {
        'trac.plugins': [
            'themeengine.web_ui = themeengine.web_ui',
            'themeengine.api = themeengine.api',
            'themeengine.admin = themeengine.admin',
        ],
    },
) 

Attachments (1)

t4344-missing-files.diff (1.5 KB) - added by otaku42 5 years ago.

Download all attachments as: .zip

Change History (5)

comment:1 Changed 5 years ago by anonymous

The same happened to me, and the solution worked fine.

comment:2 Changed 5 years ago by rjollos

  • Summary changed from missing files in in .egg to [Patch] Missing files in in .egg

Changed 5 years ago by otaku42

comment:3 Changed 5 years ago by otaku42

I confirm that the described approach fixes the original issue. However, I suggest to use finer-grained patterns to prevent unwanted side effects (such as including the .svn directories in the .egg). The attached patch implements this approach, and it works fine here in the 0.11 sandbox for trac-hacks.org.

comment:4 Changed 2 years ago by rjollos

  • Resolution set to fixed
  • Status changed from new to closed

Should be fixed as of r7741.

Add Comment

Modify Ticket

Action
as closed .
The resolution will be deleted. Next status will be 'reopened'.
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.