Skip to content
New issue

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

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

Already on GitHub? # to your account

build.dart ignores part 'xxx.dart' files from an imported components source files #12811

Closed
DartBot opened this issue Aug 27, 2013 · 1 comment
Assignees
Labels
closed-duplicate Closed in favor of an existing report

Comments

@DartBot
Copy link

DartBot commented Aug 27, 2013

This issue was originally filed by @zoechi

What steps will reproduce the problem?
1.
I have a library my_component containing a Polymer component.
Source files are located in lib
The Dart source consists of my_comp.html, my_comp.dart, helper_class_a.dart to helper_class_g.dart

my_comp.dart starts with
  library my_component;
  (imports go here)
  part 'helper_class_a.dart';
  ...
  part 'helper_class_g.dart';

helper_class_(n).dart start with
  part of my_component;
2.
Import the component and use it in a web application project

run the build script
run dart2js

3.
Part of the output:
Copying package:browser/dart.js → deploy/out/packages/browser/dart.js
Copying package:browser/interop.js → deploy/out/packages/browser/interop.js
Compiling web/out/index.html_bootstrap.dart → deploy/out/index.html_bootstrap.dart.js
web/out/_from_packages/my_component/my_component.dart:57:1: Error: Can't read 'file:///home/myuser/dart/demoapp/web/out/_from_packages/my_component/helper_class_a.dart' (Error reading 'web/out/_from_packages/my_component/data.dart' (OS Error: No such file or directory, errno = 2)).
part 'helper_class_a.dart';
^^^^^^^^^^^^^^^^^^^^^^^^^^^

What is the expected output? What do you see instead?
dart2js should process the files so that the output is a valid web app.

What version of the product are you using? On what operating system?
Dart 0.6.21
Debian Linux x64 jessie

Please provide any additional information below.
I have a class (Model) from helper_class_c.dart referenced in main().
helper_class_c.dart is the only file of all helper_class_n.dart files that was copied to web/out/_from_packages/my_component (beside the my_component.dart file)

build.dart:
import 'dart:io';
import 'package:polymer/component_build.dart';
main() {
  var pages = ['web/index.html'];
  var args = new Options().arguments;
  args.addAll(['--', '--deploy']);
  build(args, pages);
}

@sigmundch
Copy link
Member

thanks for reporting this bug! I'm currently doing a bunch of work that will replace and fix a lot of issues in our deploy step. This should be handled now by the new system but we should double check when we switch over.

We have a couple related issues:

This issue was closed.
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
closed-duplicate Closed in favor of an existing report
Projects
None yet
Development

No branches or pull requests

3 participants