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

RNTester: Update Image page and remove assert #4842

Merged
6 commits merged into from
Jul 10, 2020
Merged

Conversation

marlenecota
Copy link
Contributor

@marlenecota marlenecota commented May 8, 2020

Fix for #4691

Microsoft Reviewers: Open in CodeFlow

@marlenecota marlenecota requested a review from asklar May 8, 2020 23:44
@marlenecota marlenecota requested a review from a team as a code owner May 8, 2020 23:44
Copy link
Contributor

@kaiguo kaiguo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

// #4691
assert(value != ResizeMode::Repeat);

default: // ResizeMode::Center || ResizeMode::Repeat
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

consider replacing default: with:

case ResizeMode::Center:
case ResizeMode::Repeat:
    <code goes here>
default:
    assert("this should not be hit");
}

@@ -26,7 +26,7 @@ const base64Icon =

const ImageCapInsetsExample = require('./ImageCapInsetsExample');
const IMAGE_PREFETCH_URL =
'http://origami.design/public/images/bird-logo.png?r=1&t=' + Date.now();
'https://www.facebook.com/favicon.ico?r=1&t=' + Date.now();
Copy link
Collaborator

@NickGerleman NickGerleman May 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ReactCopies needs to remain an exact copy of upstream RN at the current version, and will get overwritten during updates.

Copy link
Collaborator

@NickGerleman NickGerleman May 9, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What version was the change in? If we need to add a new version of this to our fork we can, but we will likely need to do it a different way.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like we'll get this with 63. Didn't look to see if it all came into nightly bits.

Could we leave the assertion removed but leave tester as is? I'm going to start integrating a 63-ish release next week. Bad links should recoverably redbox, right?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If this needs to match facebooks, repo, should we at least send a PR to facebook to declare this url as a private const in the file?
It seems silly to repeat a URL many times ;)

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I mean that this exact file is a copy from React Native at a given version. There's an ask for them to publish source for this as a package, but right now we have tooling to ensure it stays up to date.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I can revert the RNTester changes, but I only updated it because one of the urls they changed is now dead: https://facebook.github.io/react-native/img/favicon.png

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can definitely understand the intent here, but forking is expensive in general, and we should avoid it where possible. Can explain more about that if interested.

Do the wrong URLs prevent validating the change? That's a case where we might be okay making changes, but we need to do it in a slightly different way.

But in general, my preference would be to wait until we get Facebook's, especially since it's coming in the version we're about to upgrade to.

Copy link
Collaborator

@NickGerleman NickGerleman left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Requesting changes around how we're forking the tester page.

@ghost ghost added the Needs: Author Feedback The issue/PR needs activity from its author (label drives bot activity) label May 9, 2020
@NickGerleman
Copy link
Collaborator

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@ghost ghost removed the Needs: Author Feedback The issue/PR needs activity from its author (label drives bot activity) label May 11, 2020
@marlenecota
Copy link
Contributor Author

/azp run

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

@asklar
Copy link
Member

asklar commented May 14, 2020

/azp run

@marlenecota you might need to rebase to clear the verdaccio error:

ERROR: Attempting to bump to a version that already exists in the registry: [email protected]
Validating package version - [email protected] package version validation - package e2etest is private
Something went wrong with the publish! Manually update these package and versions:
Skipping package version validation - package microsoft-reactnative-sampleapps is private
- [email protected]

@asklar
Copy link
Member

asklar commented Jun 19, 2020

@marlenecota "is this still available"? :)

@marlenecota marlenecota added the AutoMerge Causes a PR to be automatically merged once all requirements are passed (label drives bot activity) label Jul 10, 2020
@ghost
Copy link

ghost commented Jul 10, 2020

Hello @marlenecota!

Because this pull request has the AutoMerge label, I will be glad to assist with helping to merge this pull request once all check-in policies pass.

p.s. you can customize the way I help with merging this pull request, such as holding this pull request until a specific person approves. Simply @mention me (@msftbot) and give me an instruction to get started! Learn more here.

@ghost ghost merged commit 009e922 into microsoft:master Jul 10, 2020
@marlenecota marlenecota deleted the image branch July 10, 2020 23:18
This pull request was closed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
AutoMerge Causes a PR to be automatically merged once all requirements are passed (label drives bot activity)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants