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

feat(allow-list)!: integrate and refactor core plugin #1138

Merged
merged 5 commits into from Jul 2, 2021

Conversation

erisu
Copy link
Member

@erisu erisu commented Dec 1, 2020

Motivation, Context & Description

Integrate the Allow List core plugin to platform.

Testing

  • npm t
  • cordova create
  • cordova platform add
  • cordova build android

Run in emulator though Android Studio.

  • Must remove the original plugin that is configured with new projects.

Checklist

  • I've run the tests to see all new and existing tests pass
  • I've updated the documentation if necessary

@erisu erisu requested a review from dpogue December 1, 2020 08:10
Copy link
Member

@NiklasMerz NiklasMerz left a comment

Choose a reason for hiding this comment

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

Code LGTM 👍

Copy link
Member

@dpogue dpogue left a comment

Choose a reason for hiding this comment

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

This looks okay to me

boolean external = (xml.getAttributeValue(null, "launch-external") != null);
if (origin != null) {
if (external) {
LOG.w(LOG_TAG, "Found <access launch-external> within config.xml. Please use <allow-intent> instead.");
Copy link
Member

Choose a reason for hiding this comment

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

Now seems like a good time to drop this deprecated <access launch-external> support?

Copy link
Member Author

@erisu erisu Dec 2, 2020

Choose a reason for hiding this comment

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

Yes, we can remove this now too... I didn't carefully read to notice that this deprecated code existed. I will go ahead and delete this.

Copy link
Member Author

@erisu erisu Dec 2, 2020

Choose a reason for hiding this comment

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

@dpogue The launch-external has been removed: 4fc48ff?diff=split&w=1

I also moved the String subdomains into the else statement where it is used.

@codecov-io
Copy link

codecov-io commented Dec 2, 2020

Codecov Report

Merging #1138 (4fc48ff) into master (97e2d15) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1138   +/-   ##
=======================================
  Coverage   71.19%   71.19%           
=======================================
  Files          21       21           
  Lines        1739     1739           
=======================================
  Hits         1238     1238           
  Misses        501      501           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 97e2d15...4fc48ff. Read the comment docs.

Copy link
Contributor

@breautek breautek left a comment

Choose a reason for hiding this comment

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

lgtm

Whitelist class rename to AllowList sounds like a breaking change to me, which means this should be targeted for cordova-android@10, correct?

@breautek breautek added this to the 10.0.0 milestone Dec 3, 2020
@erisu
Copy link
Member Author

erisu commented Dec 4, 2020

Yes, because the core's original classname was renamed, this is a major change.

@NiklasMerz
Copy link
Member

Should we resolve the conflicts and move forward with this? Especially as we should solve #1217 after merging this PR.

@codecov-commenter
Copy link

codecov-commenter commented Jul 1, 2021

Codecov Report

Merging #1138 (8c3f59c) into master (0f13f4a) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master    #1138   +/-   ##
=======================================
  Coverage   71.90%   71.90%           
=======================================
  Files          21       21           
  Lines        1694     1694           
=======================================
  Hits         1218     1218           
  Misses        476      476           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 0f13f4a...8c3f59c. Read the comment docs.

@erisu erisu requested a review from PieterVanPoyer July 1, 2021 10:20
Copy link
Contributor

@PieterVanPoyer PieterVanPoyer left a comment

Choose a reason for hiding this comment

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

Awesome effort. Great.

@erisu erisu merged commit 015db81 into apache:master Jul 2, 2021
Release Plan - 10.1.0 automation moved this from Reviewer approved to Done Jul 2, 2021
@erisu erisu deleted the feat/allowlist branch July 2, 2021 02:52
@erisu erisu changed the title feat(allow-list): integrate and refactor core plugin feat(allow-list)!: integrate and refactor core plugin Jul 2, 2021
@dalybouba

This comment was marked as off-topic.

@NiklasMerz
Copy link
Member

@dalyboub Please go to Stack Overflow or Slack for questions.

Issues and pullrequests are not for questions.

@rmoehn
Copy link

rmoehn commented Apr 21, 2022

Congratulations, you've broken my code. Granted, using the word ‘whitelist’ might make some people feel bad. But what about all the developer hours wasted by having to deal with a breaking change? Does this not factor into your ethics?

@breautek
Copy link
Contributor

breautek commented Apr 21, 2022

Congratulations, you've broken my code. Granted, using the word ‘whitelist’ might make some people feel bad. But what about all the developer hours wasted by having to deal with a breaking change? Does this not factor into your ethics?

Apache uses a Code of Conduct to guide decisions such as these. More importantly we had community users raise the issue and other community members volunteer their time to solve their complaints.

We also strive not to include breaking changes. However, sometimes it is necessary. We reserve breaking changes to major version updates, so that by default, breaking changes aren't automatically rolled into your projects.

As with any library or framework using the semver version model, it would be expected that major version upgrades requires some foresight and may require refactoring on our users end. Breaking changes are generally listed in our changelog.

If you want to discuss Cordova's strategies for releases or provide advice on how we can improve the release process that can be done via our Mailing List. A closed PR is not the place for that kind of discussion. For that reason I'm locking this thread.

@apache apache locked as resolved and limited conversation to collaborators Apr 21, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
No open projects
Development

Successfully merging this pull request may close these issues.

None yet

9 participants