Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Changing the bundle ID breaks the upgrader #11543

Closed
richardkazuomiller opened this issue Dec 19, 2016 · 18 comments
Closed

Changing the bundle ID breaks the upgrader #11543

richardkazuomiller opened this issue Dec 19, 2016 · 18 comments
Labels
Resolution: Locked This issue was locked by the bot.

Comments

@richardkazuomiller
Copy link

I've changed the bundle ID of my app to the usual com.something.somethingelse format but because of that react-native-git-upgrade fails. It writes a bunch of files to paths defined using the name in package.json, fails, then resets all the changes.

Is there any way to tell the upgrader what the bundle ID of the apps is supposed to be?

Another problem is that the thing that is supposed to show what part of the upgrade process is broken is apparently broken.

git-upgrade info Commit new version template 
git-upgrade info Generate the patch between the 2 versions 
git-upgrade info Save the patch in temp directory 
git-upgrade info Reset the 2 temporary commits 
git-upgrade info Apply the patch 
fatal: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts. 
git-upgrade info Upgrade done 

^^^ Unfortunately, there is no list of files which I'm guessing has something to do with the fatal unrecognized input.

@g3r4n
Copy link

g3r4n commented Jan 8, 2017

Got the same issue to upgrading from 0.39.2 to 0.40.0

@vinceprofeta
Copy link

@g3r4n were you able to fix the issue?

@srhise
Copy link

srhise commented Jan 12, 2017

Unrelated to changing bundleID, i get this when upgrading to 0.40

@g3r4n
Copy link

g3r4n commented Jan 15, 2017

@vinceprofeta I have delete the android and iOS folder. I run react-native init and react-native link to recreate these folder. It fix the issue for me 😄

@FDMatthias
Copy link

@g3r4n 'not using react-native-git-upgrade' is not a fix. You would lose all manual changes in these folders, the kind of changes that react-native-git-upgrade should help with merging.

And yes, I get the same fatal: unrecognized input error with no extra info (even using --verbose).

@alnorris
Copy link

I'm getting the same from 0.37.0, any help to get around this one anyone?

@richardkazuomiller
Copy link
Author

I understand people have priorities but the fact that no one involved with the project has replied makes me sad.

I thought the bundle ID had something to do with it because it was creating files in the wrong directory and stuff, but apparently it doesn't work at all for some people. There's a lot about this feature that is ... weird. I don't really understand all what's going on with all the tricky git stuff and I don't have time to look into it. I think it's a cool idea but needs a lot of polishing to get it to work.

I gave up and upgraded manually.

@mikaello
Copy link

mikaello commented Feb 4, 2017

I got the same problem, this worked for me:

Edit ~/.gitconfig and change

[color]
	ui = always

to

[color]
	ui = auto

I figured this out by manually trying to git apply the patch-file in the folder printed at the end of react-native-git-upgrade --verbose (you have to use --verbose for this folder to be printed). This patch-file was color-coded because I had ui = always, and this was the reason git printed fatal: unrecognized input.

@g3r4n
Copy link

g3r4n commented Feb 4, 2017

I correct the issue by upgrading the tools and RN

facebook-github-bot pushed a commit that referenced this issue Feb 5, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue #11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes #12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
edmofro pushed a commit to edmofro/react-native that referenced this issue Feb 6, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 7, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
normanjoyner pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
nicktate pushed a commit to nicktate/react-native that referenced this issue Feb 9, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
@ncuillery
Copy link
Contributor

@richardkazuomiller, @vinceprofeta @srhise, @matthiasdebaere, @alnorris Are you still able to reproduce this error using the recent version 0.2.6 of react-native-git-upgrade ?

@flyingace
Copy link

@ncuillery While I am not one of the previous posters you listed I came here b/c I was experiencing the reported issue with version 0.2.5 of react-native-git-upgrade

git-upgrade info Apply the patch 
fatal: unrecognized input

and was seeking a solution. I have now upgraded to react-native-git-upgrade 0.2.6 and I am still experiencing the same issue.

@FDMatthias
Copy link

FDMatthias commented Feb 13, 2017

Getting the same error:

git-upgrade info Commit new version template
[master 1e1ab7b] New version
git-upgrade info Generate the patch between the 2 versions
git-upgrade info Save the patch in temp directory
git-upgrade info Reset the 2 temporary commits
HEAD is now at 8ed1468 Project snapshot
git-upgrade info Apply the patch
error: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts.
git-upgrade info Upgrade done
git-upgrade info Temporary working directory: C:\Users\....\AppData\Local\Temp\react-native-git-upgrade

and it resets to the project snapshot it updates and has some files in conflict which I can resolve. Thing is, we have changed a lot of stuff in platform specific project files so I can understand updating RN would be difficult for a tool which checks for manual changes and doesn't want to overwrite them..
(for example: we've created new folders for the iOS xcode project which uses a new name.. not sure if it updated in that folder. I will check when I have more time at hand)

GaborWnuk pushed a commit to GaborWnuk/react-native that referenced this issue Feb 28, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
@wcandillon
Copy link
Contributor

I'm also experiencing this issue with "react-native-git-upgrade": "0.2.7"

@wcandillon
Copy link
Contributor

I found what was the issue for me. I had updated and installed the new react package I was looking for. I started again from scratch (just making sure that I was using "react-native-git-upgrade": "0.2.7") and it worked nicely.

maarf pushed a commit to fullcontact/react-native that referenced this issue Apr 26, 2017
Summary:
If a user sets `color.ui` or `color.diff` to `always` in their git configuration files, the output of `git diff` will contain some "color characters" as well as the diff. When you try to apply this diff with color characters with `git apply` you will get `fatal: unrecognized input`.

I think this is the cause of issue facebook#11543

Reproduce in git with:
```
mkdir git-test
cd git-test/
git init
echo "foo" > bar.txt
git add bar.txt
git commit -m "First"
echo "foomobile" > bar.txt
git add bar.txt
git diff HEAD > new.patch --color=always
git reset --hard HEAD
git apply new.patch --check
```

Set `--color=never` or `--no-color` and the unrecognized input error should disappear and the patch be applied successfully.
Closes facebook#12211

Differential Revision: D4514132

fbshipit-source-id: 3622df6ece92794c8a175f0599f5a276d92e82e8
@RichardLindhout
Copy link

RichardLindhout commented May 2, 2017

I run 0.2.7 and got the same error:

npm WARN @shoutem/animation@0.8.10 requires a peer of react@^15.0.0 but none was installed.
npm WARN babel-loader@6.4.1 requires a peer of webpack@1 || 2 || ^2.1.0-beta || ^2.2.0-rc but none was installed.
npm WARN native-base-shoutem-theme@0.1.3 requires a peer of react@>=15.1.0 but none was installed.
npm WARN react-native-interactable@0.0.8 requires a peer of react@>= 15.4.1 but none was installed.
npm WARN react-native-svg@5.1.7 requires a peer of react@>=15.4.0 but none was installed.
npm WARN react-static-container@1.0.1 requires a peer of react@^0.13.0 || ^0.14.0 || ^15.0.0 but none was installed.
git-upgrade info Generate new version template
git-upgrade info Add updated files to commit
git-upgrade info Commit new version template
[master 59f8d3c] New version
git-upgrade info Generate the patch between the 2 versions
git-upgrade info Save the patch in temp directory
git-upgrade info Reset the 2 temporary commits
HEAD is now at 923c5bd Project snapshot
git-upgrade info Apply the patch
fatal: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts.
git-upgrade info Upgrade done
git-upgrade info Temporary working directory: /var/folders/5k/mywmpyj53gl5qppzytyy43hw0000gn/T/react-native-git-upgrade

@hramos
Copy link
Contributor

hramos commented Jul 20, 2017

Hi there! This issue is being closed because it has been inactive for a while. Maybe the issue has been fixed in a recent release, or perhaps it is not affecting a lot of people. Either way, we're automatically closing issues after a period of inactivity. Please do not take it personally!

If you think this issue should definitely remain open, please let us know. The following information is helpful when it comes to determining if the issue should be re-opened:

  • Does the issue still reproduce on the latest release candidate? Post a comment with the version you tested.
  • If so, is there any information missing from the bug report? Post a comment with all the information required by the issue template.
  • Is there a pull request that addresses this issue? Post a comment with the PR number so we can follow up.

If you would like to work on a patch to fix the issue, contributions are very welcome! Read through the contribution guide, and feel free to hop into #react-native if you need help planning your contribution.

@hramos hramos added the Icebox label Jul 20, 2017
@hramos hramos closed this as completed Jul 20, 2017
@pie6k
Copy link

pie6k commented Feb 16, 2018

Still having this issue (or I'm not sure actually if there is error - as I've got error, but at the same time it says it was successful)

git-upgrade info Check for updates
git-upgrade info Using yarn 1.3.2
git-upgrade info Read package.json files
git-upgrade info Check declared version
git-upgrade info Check matching versions
git-upgrade info Check React peer dependency
git-upgrade info Check that Git is installed
git-upgrade info Get information from NPM registry
git-upgrade info Upgrading to React Native 0.53.0, React 16.2.0
git-upgrade info Setup temporary working directory
git-upgrade info Configure Git environment
git-upgrade info Init Git repository
git-upgrade info Add all files to commit
git-upgrade info Commit current project sources
git-upgrade info Create a tag before updating sources
git-upgrade info Generate old version template
git-upgrade info Add updated files to commit
git-upgrade info Commit old version template
git-upgrade info Install the new version
warning " > apollo-cache-inmemory@1.1.9" has incorrect peer dependency "graphql@0.11.7 || ^0.12.0".
warning " > apollo-client@2.2.5" has incorrect peer dependency "graphql@^0.11.0 || ^0.12.0".
warning " > graphql-tag@2.7.3" has incorrect peer dependency "graphql@^0.9.0 || ^0.10.0 || ^0.11.0 || ^0.12.0".
warning " > react-native-fbsdk@0.7.0" has unmet peer dependency "prop-types@15.x.x".
warning " > babel-jest@22.2.2" has unmet peer dependency "babel-core@^6.0.0 || ^7.0.0-0".
git-upgrade info Generate new version template
git-upgrade info Add updated files to commit
git-upgrade info Commit new version template
git-upgrade info Generate the patch between the 2 versions
git-upgrade info Save the patch in temp directory
git-upgrade info Reset the 2 temporary commits
git-upgrade info Apply the patch
error: unrecognized input
git-upgrade WARN The upgrade process succeeded but there might be conflicts to be resolved. See above for the list of files that have merge conflicts.
git-upgrade info Upgrade done

@hramos
Copy link
Contributor

hramos commented Feb 27, 2018

I advise opening a new issue, since this one was closed due to lack of a template + inactivity.

@facebook facebook locked as resolved and limited conversation to collaborators Jul 20, 2018
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Jul 20, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests