[1.0.x] Bilingual Language Switch

Created on 20 August 2023, 11 months ago
Updated 5 November 2023, 8 months ago

This module adds a block for switching between two languages configured in a multilingual Drupal site. The block will render a link that will switch between two different languages. The module will not work if there are more than two languages enabled.

Project link

https://www.drupal.org/project/bilingual_switch →

📌 Task
Status

Needs work

Component

module

Created by

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

  • Issue created by @clgarciab
  • 🇮🇳India vishal.kadam Mumbai

    Thank you for applying! Reviewers will review the project files, describing what needs to be changed.

    Please read Review process for security advisory coverage: What to expect → for more details and Security advisory coverage application checklist → to understand what reviewers look for. Tips for ensuring a smooth review gives some hints for a smoother review.

    To reviewers: Please read How to review security advisory coverage applications → , What to cover in an application review → , and Drupal.org security advisory coverage application workflow → .

    While this application is open, only the user who opened the application can make commits to the project used for the application.

    Reviewers only describe what needs to be changed; they don't provide patches to fix what reported in a review.

  • 🇮🇳India vishal.kadam Mumbai

    Remember to change the status to Needs review when the project is ready for review.

  • 🇮🇹Italy apaderno Brescia, 🇮🇹

    Thank you for applying!

    Please read Review process for security advisory coverage: What to expect → for more details and Security advisory coverage application checklist → to understand what reviewers look for. Tips for ensuring a smooth review → gives some hints for a smother review.

    The important notes are the following.

    • If you have not done it yet, you should run phpcs --standard=Drupal,DrupalPractice on the project, which alone fixes most of what reviewers would report.
    • For the time this application is open, only your commits are allowed.
    • The purpose of this application is giving you a new drupal.org role that allows you to opt projects into security advisory coverage, either projects you already created, or projects you will create. The project status won't be changed by this application and no other user will be able to opt projects into security advisory policy.
    • We only accept an application per user. If you change your mind about the project to use for this application, or it is necessary to use a different project for the application, please update the issue summary with the link to the correct project and the issue title with the project name and the branch to review.

    To the reviewers

    Please read How to review security advisory coverage applications → , Application workflow → , What to cover in an application review → , and Tools to use for reviews → .

    The important notes are the following.

    • It is preferable to wait for a Code Review Administrator before commenting on newly created applications. Code Review Administrators will do some preliminary checks that are necessary before any change on the project files is suggested.
    • Reviewers should show the output of a CLI tool → only once per application.
    • It may be best to have the applicant fix things before further review.

    For new reviewers, I would also suggest to first read In which way the issue queue for coverage applications is different from other project queues → .

  • Status changed to Needs review 11 months ago
  • Status changed to Needs work 11 months ago
  • 🇮🇳India vishal.kadam Mumbai

    1. Fix phpcs issues.

    phpcs --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml bilingual_switch/
    
    FILE: bilingual_switch/README.md
    ----------------------------------------------------------------------
    FOUND 0 ERRORS AND 2 WARNINGS AFFECTING 2 LINES
    ----------------------------------------------------------------------
      4 | WARNING | Line exceeds 80 characters; contains 254 characters
     21 | WARNING | Line exceeds 80 characters; contains 90 characters
    ----------------------------------------------------------------------
    
    
    FILE: bilingual_switch/src/Plugin/Block/BilingualSwitchBlock.php
    -----------------------------------------------------------------------------------------------------------------------------
    FOUND 6 ERRORS AND 5 WARNINGS AFFECTING 11 LINES
    -----------------------------------------------------------------------------------------------------------------------------
       5 | WARNING | [x] Unused use statement
       6 | WARNING | [x] Unused use statement
       8 | ERROR   | [x] Use statements should be sorted alphabetically. The first wrong one is Drupal\Core\Access\AccessResult.
      67 | ERROR   | [ ] Parameter $route_match is not described in comment
      78 | ERROR   | [ ] Missing parameter name
     115 | ERROR   | [x] Equals sign not aligned correctly; expected 1 space but found 2 spaces
     157 | WARNING | [ ] Only string literals should be passed to t() where possible
     165 | WARNING | [x] A comma should follow the last multiline array item. Found: $another_language_langcode
     170 | ERROR   | [x] Array indentation error, expected 8 spaces but found 6
     172 | ERROR   | [x] Array closing indentation error, expected 6 spaces but found 8
     187 | WARNING | [x] A comma should follow the last multiline array item. Found: ]
    -----------------------------------------------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 8 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    -----------------------------------------------------------------------------------------------------------------------------
    
    
    FILE: bilingual_switch/css/bilingual-switch.css
    ------------------------------------------------------------------------------------
    FOUND 4 ERRORS AFFECTING 3 LINES
    ------------------------------------------------------------------------------------
     1 | ERROR | [x] Expected 1 space before opening brace of class definition; 0 found
     1 | ERROR | [ ] Class definition is empty
     2 | ERROR | [x] Blank lines are not allowed in class definitions
     3 | ERROR | [x] Expected 1 newline at end of file; 0 found
    ------------------------------------------------------------------------------------
    PHPCBF CAN FIX THE 3 MARKED SNIFF VIOLATIONS AUTOMATICALLY
    ------------------------------------------------------------------------------------

    2. main is a wrong branch name, as branch names end with the literal .x. That branch needs to be removed.

    3. FILE: bilingual_switch.info.yml

    core_version_requirement: ^8 || ^9 || ^10

    The Drupal Core versions before 8.7.7 do not recognize the core_version_requirement: key.

  • Removed branch "main". Fixed errors.

  • Status changed to Needs review 11 months ago
  • 🇮🇳India vishal.kadam Mumbai

    Rest looks fine to me.

    Let’s wait for other reviewers to take a look and if everything goes fine, you will get the role.

  • 🇮🇹Italy apaderno Brescia, 🇮🇹
  • Status changed to RTBC 9 months ago
  • 🇮🇳India vinaymahale

    No issues found
    Changing status to RTBC!

  • Status changed to Needs work 9 months ago
  • 🇮🇹Italy apaderno Brescia, 🇮🇹

    I find not clear why a site would use a module that cannot handle more than two language when a Drupal core module can handle more than two languages.
    At least, the project page should make clear what the differences between this and the Drupal core module is.

  • 🇮🇹Italy apaderno Brescia, 🇮🇹

    I am changing priority as per Issue priorities → .

Production build 0.69.0 2024