Skip to content
This repository has been archived by the owner on Jan 20, 2018. It is now read-only.

pub serve hangs forever after a change (using the web-components transformer) #27

Closed
kasperpeulen opened this issue Jun 15, 2015 · 4 comments · Fixed by #28 or #29
Closed

pub serve hangs forever after a change (using the web-components transformer) #27

kasperpeulen opened this issue Jun 15, 2015 · 4 comments · Fixed by #28 or #29

Comments

@kasperpeulen
Copy link
Contributor

pub serve hangs forever after a change (using the web-components transformer)

similar to these issues:
dart-archive/angular.dart#1709
dart-archive/angular.dart#1276

kasperpeulen added a commit to kasperpeulen/web-components that referenced this issue Jun 15, 2015
jakemac53 added a commit that referenced this issue Jun 15, 2015
@jakemac53 jakemac53 reopened this Jun 15, 2015
@jakemac53
Copy link
Contributor

Re-opening this as we should try to fix the actual issue. The current fix creates a new resolver every time, which is probably going the have bad performance implications.

@kasperpeulen
Copy link
Contributor Author

@jakemac53 For me, the deadlock occurs in this method:
https://github.com/dart-lang/code_transformers/blob/master/lib/src/resolvers.dart#L54

If I don't run this method, the deadlock won't occur. If I run this method (and if don't do anything else after running this method), the deadlock occurs.

If I change:

var resolver = _resolvers.putIfAbsent(
      id, () => new ResolverImpl(dartSdk, dartUriResolver, options: options));

to

var resolver = new ResolverImpl(dartSdk, dartUriResolver, options: options));

then everything goes fine as well

@jakemac53
Copy link
Contributor

Thanks for investigating this, the actual problem is we were never releasing the resolver inside our web_components transformer :). You can see a mention of that in the comments for that method. I will work on a pull request and release a new version asap.

@jakemac53
Copy link
Contributor

published as 0.12.0+1

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
2 participants