Skip to content

Mark Framework interfaces as API part 2 #32140

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

Merged

Conversation

mrtuvn
Copy link
Contributor

@mrtuvn mrtuvn commented Feb 12, 2021

Description (*)

Mark following interfaces as API + Added strict_types

lib/internal/Magento/Framework/App/CsrfAwareActionInterface.php
lib/internal/Magento/Framework/App/DefaultPathInterface.php
lib/internal/Magento/Framework/App/DeploymentConfig/ImporterInterface.php
lib/internal/Magento/Framework/App/DeploymentConfig/ValidatorInterface.php
lib/internal/Magento/Framework/App/DeploymentConfig/Writer/FormatterInterface.php
lib/internal/Magento/Framework/App/DesignInterface.php
lib/internal/Magento/Framework/App/EnvironmentInterface.php
lib/internal/Magento/Framework/App/ExceptionHandlerInterface.php
lib/internal/Magento/Framework/App/FeedFactoryInterface.php
lib/internal/Magento/Framework/App/FeedInterface.php
lib/internal/Magento/Framework/App/HttpRequestInterface.php
lib/internal/Magento/Framework/App/ObjectManager/ConfigWriterInterface.php
lib/internal/Magento/Framework/App/PageCache/NotCacheableInterface.php
lib/internal/Magento/Framework/App/Request/ValidatorInterface.php
lib/internal/Magento/Framework/App/ResourceConnection/ConfigInterface.php
lib/internal/Magento/Framework/App/ResourceConnection/ConnectionAdapterInterface.php
lib/internal/Magento/Framework/App/Response/FileInterface.php
lib/internal/Magento/Framework/App/Response/HeaderProvider/HeaderProviderInterface.php
lib/internal/Magento/Framework/App/Response/RedirectInterface.php
lib/internal/Magento/Framework/App/Router/NoRouteHandlerInterface.php
lib/internal/Magento/Framework/App/Router/PathConfigInterface.php
lib/internal/Magento/Framework/App/RouterInterface.php
lib/internal/Magento/Framework/App/RouterListInterface.php
lib/internal/Magento/Framework/App/Rss/RssManagerInterface.php
lib/internal/Magento/Framework/App/Rss/UrlBuilderInterface.php
lib/internal/Magento/Framework/App/Scope/ValidatorInterface.php
lib/internal/Magento/Framework/App/ScopeFallbackResolverInterface.php
lib/internal/Magento/Framework/App/ScopeResolverInterface.php
lib/internal/Magento/Framework/App/ScopeTreeProviderInterface.php
lib/internal/Magento/Framework/App/ScopeValidatorInterface.php
lib/internal/Magento/Framework/App/View/Asset/MaterializationStrategy/StrategyInterface.php
lib/internal/Magento/Framework/App/View/Deployment/Version/StorageInterface.php

Also marked api for references class/interfaces

lib/internal/Magento/Framework/\App/Request/InvalidRequestException
lib/internal/Magento/Framework/Interception/ObjectManager/ConfigInterface
lib/internal/Magento/Framework/App/Response/Http
lib/internal/Magento/Framework/App/Request/Http

lib/internal/Magento/Framework/ObjectManager/RelationsInterface.php
lib/internal/Magento/Framework/ObjectManager/ConfigInterface.php
lib/internal/Magento/Framework/ObjectManager/ConfigCacheInterface.php
lib/internal/Magento/Framework/Interception/ConfigInterface.php

lib/internal/Magento/Framework/DB/LoggerInterface (by lib/internal/Magento/Framework/App/ResourceConnection/ConnectionAdapterInterface.php)

lib/internal/Magento/Framework/View/DesignInterface (by
lib/internal/Magento/Framework/App/DesignInterface.php)

Related Pull Requests

#32142
#32156

Fixed Issues (if relevant)

  1. Fixes Mark Framework interfaces as API part 2 #32025

Manual testing scenarios (*)

  1. ...
  2. ...

Questions or comments

Contribution checklist (*)

  • Pull request has a meaningful description of its purpose
  • All commits are accompanied by meaningful commit messages
  • All new or changed code is covered with unit/integration tests (if applicable)
  • All automated tests passed successfully (all builds are green)

@m2-assistant
Copy link

m2-assistant bot commented Feb 12, 2021

Hi @mrtuvn. Thank you for your contribution
Here are some useful tips how you can test your changes using Magento test environment.
Add the comment under your pull request to deploy test or vanilla Magento instance:

  • @magento give me test instance - deploy test instance based on PR changes
  • @magento give me 2.5-develop instance - deploy vanilla Magento instance

❗ Automated tests can be triggered manually with an appropriate comment:

  • @magento run all tests - run or re-run all required tests against the PR changes
  • @magento run <test-build(s)> - run or re-run specific test build(s)
    For example: @magento run Unit Tests

<test-build(s)> is a comma-separated list of build names. Allowed build names are:

  1. Database Compare
  2. Functional Tests CE
  3. Functional Tests EE,
  4. Functional Tests B2B
  5. Integration Tests
  6. Magento Health Index
  7. Sample Data Tests CE
  8. Sample Data Tests EE
  9. Sample Data Tests B2B
  10. Static Tests
  11. Unit Tests
  12. WebAPI Tests
  13. Semantic Version Checker

You can find more information about the builds here

ℹ️ Please run only needed test builds instead of all when developing. Please run all test builds before sending your PR for review.

For more details, please, review the Magento Contributor Guide documentation.

⚠️ According to the Magento Contribution requirements, all Pull Requests must go through the Community Contributions Triage process. Community Contributions Triage is a public meeting.

🕙 You can find the schedule on the Magento Community Calendar page.

📞 The triage of Pull Requests happens in the queue order. If you want to speed up the delivery of your contribution, please join the Community Contributions Triage session to discuss the appropriate ticket.

🎥 You can find the recording of the previous Community Contributions Triage on the Magento Youtube Channel

✏️ Feel free to post questions/proposals/feedback related to the Community Contributions Triage process to the corresponding Slack Channel

@m2-community-project m2-community-project bot added Priority: P1 Once P0 defects have been fixed, a defect having this priority is the next candidate for fixing. Progress: pending review labels Feb 12, 2021
@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch from d7afbfb to c83e092 Compare February 18, 2021 14:47
@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 18, 2021

Rebased 2.5-develop

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 18, 2021

@magento run all tests

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 19, 2021

Public type 'Magento\Framework\App\CsrfAwareActionInterface' references following non-public types:
Magento\Framework\App\Request\InvalidRequestException

Public type 'Magento\Framework\App\DesignInterface' references following non-public types:
Magento\Framework\View\DesignInterface

Public type 'Magento\Framework\App\EnvironmentInterface' references following non-public types:
Magento\Framework\Interception\ObjectManager\ConfigInterface

Public type 'Magento\Framework\App\ExceptionHandlerInterface' references following non-public types:
Magento\Framework\App\Response\Http
Magento\Framework\App\Request\Http

Public type 'Magento\Framework\App\ResourceConnection\ConnectionAdapterInterface' references following non-public types:
Magento\Framework\DB\LoggerInterface

@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch 2 times, most recently from 4a1eca6 to f997658 Compare February 20, 2021 09:08
@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 21, 2021

@magento run Functional Tests B2B, Static Tests

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 22, 2021

@magento run Functional Tests B2B

@eduard13
Copy link
Contributor

@mrtuvn instead of marking the api classes that are failing on Static Tests, it's better to take a quick look, maybe they were already mentioned in scope of another PRs. For example, here you are marking as api:

This will cause a lot of conflicts while merging them.

Please add all the PRs that you find useful for your PR, as related.

Please let me know if any questions arise.

@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch from f997658 to 78f9a27 Compare February 22, 2021 15:07
@gabrieldagama gabrieldagama added this to the 2.5 milestone Feb 22, 2021
@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch 2 times, most recently from 1eeb928 to a9bb8b2 Compare February 24, 2021 16:33
@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 24, 2021

@magento run Static Tests, Unit Tests

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 25, 2021

@magento run Static Tests

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 25, 2021

@magento run Database Compare, Functional Tests B2B, Functional Tests CE, Functional Tests EE, Integration Tests, Magento Health Index, Sample Data Tests B2B, Sample Data Tests CE, Sample Data Tests EE, Semantic Version Checker, WebAPI Tests

@eduard13
Copy link
Contributor

@magento run Unit Tests, Functional Tests EE, Functional Tests CE, Functional Tests B2B

@eduard13
Copy link
Contributor

@magento run Functional Tests EE, Functional Tests CE, Functional Tests B2B

@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch from a9bb8b2 to 06092bb Compare February 26, 2021 08:00
@mrtuvn
Copy link
Contributor Author

mrtuvn commented Feb 26, 2021

@magento run all tests

@eduard13 eduard13 added the Auto-Tests: Not Required Changes in Pull Request does not require coverage by auto-tests label Feb 26, 2021
@eduard13
Copy link
Contributor

eduard13 commented Mar 1, 2021

@magento run Functional Tests EE, WebAPI Tests

@@ -131,7 +133,7 @@ public function sendVary()
*/
public function setPublicHeaders($ttl)
{
if ($ttl < 0 || !preg_match('/^[0-9]+$/', $ttl)) {
if ($ttl < 0 || !is_numeric($ttl)) {
Copy link
Contributor

Choose a reason for hiding this comment

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

We are not looking for code changes with these issues, please revert as it was.

Copy link
Contributor Author

@mrtuvn mrtuvn Apr 13, 2021

Choose a reason for hiding this comment

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

This change introduce since i added strict_type at the first line of fine! This change pass test too should i revert strict_type in only this

Copy link
Contributor

Choose a reason for hiding this comment

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

In this case, let's create a separate PR to add the strict type and the code change. On this scope, we are looking just for API marking.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

updating it

Update


hollymolly


up


update


update types


fix fail tests


update strict type for preg_match 2rd argument


Update


revert origin code


resolve conflicts
@mrtuvn mrtuvn force-pushed the api-interfaces-mark-2 branch from 123fe6b to 789c540 Compare April 13, 2021 15:46
@mrtuvn
Copy link
Contributor Author

mrtuvn commented Apr 13, 2021

@magento run all tests

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Apr 13, 2021

@magento run Functional Tests B2B

@mrtuvn
Copy link
Contributor Author

mrtuvn commented Apr 14, 2021

@gabrieldagama all green tests and ready!

@gabrieldagama
Copy link
Contributor

@magento-engcom-team
Copy link
Contributor

@gabrieldagama the branch with code successfully imported intomagento-engcom/magento2ce repository. Branch name: imported-magento-magento2-32140.

@magento-cicd2 magento-cicd2 merged commit d0afdf9 into magento:api-changes-develop May 6, 2021
@m2-assistant
Copy link

m2-assistant bot commented May 6, 2021

Hi @mrtuvn, thank you for your contribution!
Please, complete Contribution Survey, it will take less than a minute.
Your feedback will help us to improve contribution process.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Auto-Tests: Not Required Changes in Pull Request does not require coverage by auto-tests Component: App Priority: P1 Once P0 defects have been fixed, a defect having this priority is the next candidate for fixing. Progress: accept Project: API Changes QA: Added to Regression Scope Scenario was analysed and added to Regression Testing Scope Release Line: 2.4
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Mark Framework interfaces as API part 2
7 participants