Compare commits

..

5 Commits
4.4.2 ... 4.4.3

Author SHA1 Message Date
e2e8ba6ffa release: cut the 4.4.3 release 2017-09-19 15:22:05 -07:00
60cdf9dc38 docs(CHANGELOG.MD): add release notes for 4.4.2 and 4.4.3 2017-09-19 15:21:51 -07:00
0371538d10 fix(tsc-wrapped): deduplicate metadata only when the module is the same (#19261)
Fixes #19219
PR Close #19261
2017-09-19 14:25:27 -07:00
351331a81b ci: update yarn to 1.0.2 (#19270)
PR Close #19270
2017-09-19 13:53:09 -07:00
0a54713f8a build: automatically version tsc-wrapped just like other packages (#19270)
This removes manual steps from the release list.

I had to modify a few integration tests not to install compiler-cli dirrectly
because it depends on tsc-wrapped which yarn was eager to fetch from npm rather
than from the local build.

PR Close #19270
2017-09-19 13:53:09 -07:00
15 changed files with 52 additions and 17 deletions

View File

@ -1,3 +1,21 @@
<a name="4.4.3"></a>
## [4.4.3](https://github.com/angular/angular/compare/4.4.2...4.4.3) (2017-09-19)
### Bug Fixes
* **tsc-wrapped:** deduplicate metadata only when the module is the same ([#19261](https://github.com/angular/angular/issues/19261)) ([0371538](https://github.com/angular/angular/commit/0371538)), closes [#19219](https://github.com/angular/angular/issues/19219)
<a name="4.4.2"></a>
## [4.4.2](https://github.com/angular/angular/compare/4.4.1...4.4.2) (2017-09-18)
### Bug Fixes
* **platform-server**: fix for packaging issues [#19250](https://github.com/angular/angular/issues/19250)
<a name="4.4.1"></a>
# [4.4.1](https://github.com/angular/angular/compare/4.3.6...4.4.1) (2017-09-15)

View File

@ -45,7 +45,7 @@
},
"engines": {
"node": ">=6.9.5 <7.0.0",
"yarn": ">=0.21.3 <1.0.0"
"yarn": ">=1.0.2 <2.0.0"
},
"private": true,
"dependencies": {

View File

@ -347,6 +347,10 @@ if [[ ${BUILD_TOOLS} == true ]]; then
$(npm bin)/tsc -p ${TSCONFIG}
cp ./tools/@angular/tsc-wrapped/package.json ./dist/tools/@angular/tsc-wrapped
echo "====== VERSION: Updating version references"
echo "====== EXECUTE: perl -p -i -e \"s/0\.0\.0\-PLACEHOLDER/${VERSION}/g\" $""(grep -ril 0\.0\.0\-PLACEHOLDER ./dist/tools/@angular/tsc-wrapped/package.json)"
perl -p -i -e "s/0\.0\.0\-PLACEHOLDER/${VERSION}/g" $(grep -ril 0\.0\.0\-PLACEHOLDER ./dist/tools/@angular/tsc-wrapped/package.json) < /dev/null 2> /dev/null
travisFoldEnd "build tools"
fi

View File

@ -6,12 +6,12 @@
"@angular/animations": "file:../../dist/packages-dist/animations",
"@angular/common": "file:../../dist/packages-dist/common",
"@angular/compiler": "file:../../dist/packages-dist/compiler",
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
"@angular/core": "file:../../dist/packages-dist/core",
"@angular/platform-browser": "file:../../dist/packages-dist/platform-browser",
"@angular/platform-server": "file:../../dist/packages-dist/platform-server",
"@angular/tsc-wrapped": "file:../../dist/tools/@angular/tsc-wrapped",
"google-closure-compiler": "20170409.0.0",
"reflect-metadata": "^0.1.2",
"rxjs": "5.3.1",
"typescript": "2.1.6",
"zone.js": "0.8.6"
@ -29,4 +29,4 @@
"preprotractor": "tsc -p e2e",
"protractor": "protractor e2e/protractor.config.js"
}
}
}

View File

@ -7,7 +7,6 @@
"@angular/animations": "file:../../dist/packages-dist/animations",
"@angular/common": "file:../../dist/packages-dist/common",
"@angular/compiler": "file:../../dist/packages-dist/compiler",
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
"@angular/core": "file:../../dist/packages-dist/core",
"@angular/language-service": "file:../../dist/packages-dist/language-service",
"@angular/platform-browser": "file:../../dist/packages-dist/platform-browser",

View File

@ -24,6 +24,15 @@ for testDir in $(ls | grep -v node_modules) ; do
# Workaround for https://github.com/yarnpkg/yarn/issues/2256
rm -f yarn.lock
yarn install --cache-folder ../$cache
# this is a workaround for resolving tsc-wrapped as the local version not available on npm
# tsc-wrapped is installed as a transitive dependency of compiler-cli
if [[ $testDir == "hello_world__closure" || $$testDir == "language_service_plugin" ]]; then
# compiler-cli needs to be installed while offline so that it doesn't try to look up tsc-wrapped version on npm
# it should instead use the version that is already installed in the project via package.json
yarn add --offline ../../dist/packages-dist/compiler-cli --cache-folder ../$cache
fi
yarn test || exit 1
)
done

View File

@ -7,7 +7,6 @@
"@angular/animations": "file:../../dist/packages-dist/animations",
"@angular/common": "file:../../dist/packages-dist/common",
"@angular/compiler": "file:../../dist/packages-dist/compiler",
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
"@angular/core": "file:../../dist/packages-dist/core",
"@angular/forms": "file:../../dist/packages-dist/forms",
"@angular/http": "file:../../dist/packages-dist/http",

View File

@ -7,7 +7,6 @@
"@angular/animations": "file:../../dist/packages-dist/animations",
"@angular/common": "file:../../dist/packages-dist/common",
"@angular/compiler": "file:../../dist/packages-dist/compiler",
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
"@angular/core": "file:../../dist/packages-dist/core",
"@angular/forms": "file:../../dist/packages-dist/forms",
"@angular/http": "file:../../dist/packages-dist/http",

View File

@ -7,7 +7,6 @@
"@angular/animations": "file:../../dist/packages-dist/animations",
"@angular/common": "file:../../dist/packages-dist/common",
"@angular/compiler": "file:../../dist/packages-dist/compiler",
"@angular/compiler-cli": "file:../../dist/packages-dist/compiler-cli",
"@angular/core": "file:../../dist/packages-dist/core",
"@angular/forms": "file:../../dist/packages-dist/forms",
"@angular/http": "file:../../dist/packages-dist/http",

View File

@ -1,6 +1,6 @@
{
"name": "angular-srcs",
"version": "4.4.2",
"version": "4.4.3",
"private": true,
"branchPattern": "2.0.*",
"description": "Angular - a web framework for modern web apps",
@ -10,7 +10,7 @@
"engines": {
"node": ">=6.9.5 <7.0.0",
"npm": ">=3.10.7 <4.0.0",
"yarn": ">=0.21.3 <1.0.0"
"yarn": ">=1.0.2 <2.0.0"
},
"repository": {
"type": "git",

View File

@ -16,6 +16,7 @@
"@angular/http": "file:../../../dist/packages-dist/http",
"@angular/platform-browser": "file:../../../dist/packages-dist/platform-browser",
"@angular/platform-server": "file:../../../dist/packages-dist/platform-server",
"@angular/tsc-wrapped": "file:../../../dist/tools/@angular/tsc-wrapped",
"express": "^4.14.1",
"rxjs": "file:../../../node_modules/rxjs",
"typescript": "2.1.6",

View File

@ -36,7 +36,7 @@ fi
setEnvVar NODE_VERSION 6.9.5
setEnvVar NPM_VERSION 3.10.7 # do not upgrade to >3.10.8 unless https://github.com/npm/npm/issues/14042 is resolved
setEnvVar YARN_VERSION 0.24.6
setEnvVar YARN_VERSION 1.0.2
setEnvVar SAUCE_CONNECT_VERSION 4.3.11
setEnvVar PROJECT_ROOT $(cd ${thisDir}/../..; pwd)

View File

@ -1,6 +1,6 @@
{
"name": "@angular/tsc-wrapped",
"version": "4.4.2",
"version": "0.0.0-PLACEHOLDER",
"description": "Wraps the tsc CLI, allowing extensions.",
"homepage": "https://github.com/angular/angular/blob/master/tools/@angular/tsc-wrapped",
"bugs": "https://github.com/angular/angular/issues",

View File

@ -263,24 +263,25 @@ export class MetadataBundler {
Array.from(this.symbolMap.values()).forEach(symbol => {
if (symbol.referenced && !symbol.reexport) {
let name = symbol.name;
const declaredName = symbol.declaration !.name;
const identifier = `${symbol.declaration!.module}:${symbol.declaration !.name}`;
if (symbol.isPrivate && !symbol.privateName) {
name = newPrivateName();
symbol.privateName = name;
}
if (symbolsMap.has(declaredName)) {
const names = symbolsMap.get(declaredName);
if (symbolsMap.has(identifier)) {
const names = symbolsMap.get(identifier);
names !.push(name);
} else {
symbolsMap.set(declaredName, [name]);
symbolsMap.set(identifier, [name]);
}
result[name] = symbol.value !;
}
});
// check for duplicated entries
symbolsMap.forEach((names: string[], declaredName: string) => {
symbolsMap.forEach((names: string[], identifier: string) => {
if (names.length > 1) {
const [module, declaredName] = identifier.split(':');
// prefer the export that uses the declared name (if any)
let reference = names.indexOf(declaredName);
if (reference === -1) {

View File

@ -197,26 +197,32 @@ describe('metadata bundler', () => {
const host = new MockStringBundlerHost('/', {
'public-api.ts': `
export {A as A2, A, B as B1, B as B2} from './src/core';
export {A as A3} from './src/alternate';
`,
'src': {
'core.ts': `
export class A {}
export class B {}
`,
'alternate.ts': `
export class A {}
`,
}
});
const bundler = new MetadataBundler('/public-api', undefined, host);
const result = bundler.getMetadataBundle();
const {A, A2, B1, B2} = result.metadata.metadata as{
const {A, A2, A3, B1, B2} = result.metadata.metadata as{
A: ClassMetadata,
A2: MetadataGlobalReferenceExpression,
A3: ClassMetadata,
B1: ClassMetadata,
B2: MetadataGlobalReferenceExpression
};
expect(A.__symbolic).toEqual('class');
expect(A2.__symbolic).toEqual('reference');
expect(A2.name).toEqual('A');
expect(A3.__symbolic).toEqual('class');
expect(B1.__symbolic).toEqual('class');
expect(B2.__symbolic).toEqual('reference');
expect(B2.name).toEqual('B1');