Skip to content

Commit bf8cfcc

Browse files
committed
Ignore some annoying dirs and show more details of valid validation
1 parent 337e4f1 commit bf8cfcc

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

componentize.py

+4-4
Original file line numberDiff line numberDiff line change
@@ -87,11 +87,11 @@ def validate_source_bundle(source):
8787
data = os.path.join(source, 'metadata.json')
8888

8989
if not os.path.exists(icon):
90-
raise ValueError('icon missing, make sure icon.png is present in the source bundle')
90+
raise ValueError('icon missing, make sure icon.png is present in the source bundle: {}'.format(source))
9191
if not os.path.exists(code):
92-
raise ValueError('code missing, make sure code.py is present in the source bundle')
92+
raise ValueError('code missing, make sure code.py is present in the source bundle: {}'.format(source))
9393
if not os.path.exists(data):
94-
raise ValueError('metadata missing, make sure metadata.json is present in the source bundle')
94+
raise ValueError('metadata missing, make sure metadata.json is present in the source bundle: {}'.format(source))
9595

9696
icon = bitmap_from_image_path(icon)
9797

@@ -267,7 +267,7 @@ def create_ghuser_component(source, target, version=None):
267267
libdir = os.path.abspath(args.ghio)
268268
gh_io = find_ghio_assembly(libdir)
269269
source_bundles = [d for d in os.listdir(sourcedir)
270-
if os.path.isdir(os.path.join(sourcedir, d))]
270+
if os.path.isdir(os.path.join(sourcedir, d)) and d not in ('__pycache__', '.git')]
271271

272272
print('GHPython componentizer')
273273
print('======================')

0 commit comments

Comments
 (0)