question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. ItΒ collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Re-running migration produces "invalid version" error

See original GitHub issue

🐞 Bug report

Command (mark with an x)

- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [ ] generate
- [ ] add
- [x] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Is this a regression?

Yes. Previously worked with pre-V8 CLI.

Description

If the migration from v7 to v8 fails, the CLI prints the following:

Migration can be rerun with: "ng update @angular/core --from 7 --to 8 --migrate-only"

Trying to run this command after fixing whatever was wrong does not work.

πŸ”₯ Exception or Error

Using package manager: 'npm'
Collecting installed dependencies...
Found 77 dependencies.
Invalid Version: 7

🌍 Your Environment

Angular CLI: 8.0.0
Node: 11.10.1
OS: darwin x64
Angular: 8.0.0
... animations, cdk, cli, common, compiler, compiler-cli, core
... forms, language-service, platform-browser
... platform-browser-dynamic, router

Package                           Version
-----------------------------------------------------------
@angular-devkit/architect         0.800.0
@angular-devkit/build-angular     0.800.0
@angular-devkit/build-optimizer   0.800.0
@angular-devkit/build-webpack     0.800.0
@angular-devkit/core              8.0.0
@angular-devkit/schematics        8.0.0
@ngtools/webpack                  8.0.0
@nguniversal/express-engine       7.1.1
@schematics/angular               8.0.0
@schematics/update                0.800.0
rxjs                              6.5.2
typescript                        3.4.5
webpack                           4.30.0

Anything else relevant?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:2
  • Comments:11 (2 by maintainers)

github_iconTop GitHub Comments

5reactions
alan-agius4commented, May 29, 2019

Increasing the priority as in the @angular/core migration schematics if it fail its will print Migration can be rerun with: "ng update @angular/core --from 7 --to 8 --migrate-only"

1reaction
alan-agius4commented, May 29, 2019

@filipesilva I don’t think this is related to what you mentioned above, this issue is not on Windows and migrations are being run.

The problem here is that ng update @angular/core --from 7 --to 8 --migrate-only errors out while ng update @angular/core --from 7.0.0 --to 8.0.0 --migrate-only works as expected.

/workspace/viewChild-test-ng8 $ yarn ng update @angular/core --from 7 --to 8 --migrate-only
yarn run v1.16.0
$ ng update @angular/core --from 7 --to 8 --migrate-only
Using package manager: 'npm'
Collecting installed dependencies...
Found 30 dependencies.
Invalid Version: 7

error Command failed with exit code 1.
info Visit https://yarnpkg.com/en/docs/cli/run for documentation about this command. 

/workspace/viewChild-test-ng8 $ yarn ng update @angular/core --from 7.0.0 --to 8.0.0 --migrate-only
yarn run v1.16.0
$ ng update @angular/core --from 7.0.0 --to 8.0.0 --migrate-only
Using package manager: 'npm'
Collecting installed dependencies...
Found 30 dependencies.
    ** Executing migrations for package '@angular/core' **
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to handle a previous Flyway migration becoming invalid ...
The best way to handle this is probably to carefully modify the migration and issue a flyway repair to realign the checksums in...
Read more >
Troubleshooting migration - IBM
Fix the problems in the Version 7.0 or later applications, and then remigrate. Proceed with the migration and ignore these errors. Restart the...
Read more >
Data migration service error codes - Google Support
Try running the migration while the server is not in use. If the issue persists, do an IMAP migration using the steps in...
Read more >
Flyway by Redgate β€’ Database Migrations Made Easy.
The version must be unique. The description is purely informative for you to be able to remember what each migration does. The checksum...
Read more >
USMT common issues - Windows Client | Microsoft Learn
USMT produces log files that describe in further detail any errors that ... When you encounter a problem or error message during migration,Β ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found