magento / magento/magento-coding-standard

DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.

Open
#498 2 comments 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
PHP
Stars
375
Forks
165
PR merge metrics
No merged PRs in 30d

Description

### Preconditions

- phpcs v3.13.2
- magento coding standard 38

### Steps to reproduce

1. use versions from above
2. run phpcs against magento

### Expected result

No deprecation warnings

### Actual result

```
DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.
The Magento2.GraphQL.ValidArgumentName sniff is listening for GRAPHQL.
DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.
The Magento2.GraphQL.ValidFieldName sniff is listening for GRAPHQL.
DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.
The Magento2.GraphQL.ValidTopLevelFieldName sniff is listening for GRAPHQL.
DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.
The Magento2.GraphQL.ValidTypeName sniff is listening for GRAPHQL.
DEPRECATED: Support for custom tokenizers will be removed in PHP_CodeSniffer 4.0.
The Magento2.GraphQL.ValidEnumValue sniff is listening for GRAPHQL.
```

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the warnings with PHP_CodeSniffer v3.13.2 and Magento Coding Standard 38 by running phpcs against Magento. Inspect the custom-tokenizer handling and the listed Magento2.GraphQL sniffs. Done means the GraphQL checks still work without the PHP_CodeSniffer 4.0 deprecation warnings.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.