🇺🇸United States @trackleft2

Tucson, AZ 🇺🇸
Account created on 2 April 2014, about 11 years ago
#

Merge Requests

More

Recent comments

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I've added a post update function that just resaves all of the existing cron migrations on the site in order to recalculate dependencies.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I think we need to add a post_update function in order to update existing cron migration config entities to add their dependencies.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 2.1.x to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 3451525-add-config-dependency to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

The PHPUnit test introduced in this MR does not appear to adequately test this functionality.

I say this because the https://git.drupalcode.org/project/user_expire/-/jobs/5542470 test passed with or without the fix. Running the "Test Only Changes" test should fail but it does not.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Hi sahil.sharma@io-media.com I'll add this to the plan for the next release. Thanks! The patch looks ok to me, so feel free to use it until then.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Sorry for taking so long in creating a release with this in it. We have a lot tied up in our release number at the moment and don't want to back track since our next patch release should drop any day now and it would be a lot of administrative work to sneak in a hotfix.

On the bright side, during the process of creating the new release, we did realize that we should be supporting 7.3 and Drupal 9.3 and changed that to our target.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I've updated this to add dynamic title handling for the edit and delete form pages, and put it in a merge request with a tugboat preview.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 made their first commit to this issue’s fork.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Sounds like this has been resolved, I've added to the documentation: https://www.drupal.org/docs/extending-drupal/contributed-modules/contrib...

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Add usage note for config_split

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Move Environment switchers link above inline code help.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Adding config split instructions
Update headings
adding links

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Change lando to ddev

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Add example that would cover multiple environments.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸
🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Update headings.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Bolding the module names to further promote modular architecture.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I've rerolled all of the ideas here into merge request !102
Looks like this:

Additionally, the favicon works in !102

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Update wording in a few places and add information about sub modules.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 4.x to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

PHPUnit test broken

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 3484735-move-toolbar-integration to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

This should be ready for final review.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

In the database update, we should check whether the toolbar module is enabled before enabling the environment_indicator_toolbar submodule. If toolbar is not enabled, then environment_indicator_toolbar should not be enabled.

My reasoning:

  1. If the toolbar_integration config is set to ["toolbar" => "toolbar"] but the toolbar module isn’t enabled, then enabling environment_indicator_toolbar would result in a change in functionality: it would add the environment indicator to the toolbar (instead of #page_top) and also change the color of the toolbar. This could be unexpected or undesired.
  2. There’s also a risk in the opposite direction: since the libraries have changed, someone may be depending on the old toolbar-related libraries even if the toolbar integration option is not selected. In this case, the module will no longer work for them, and a new issue should be created for an additional integration.

To avoid introducing unexpected behavior, we should only enable environment_indicator_toolbar if the toolbar module is already enabled.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Thanks! Closing as a duplicate.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

@indrajithkb is this still an issue in the Dev version of this module? https://www.drupal.org/project/environment_indicator/releases/4.x-dev

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Also, it appears that all of the gitlab-ci tests are currently passing due to this issue: 💬 Validate stage may use outdated artifact, leading to flaky test results Active

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I've updated the PHPUnit tests so that they pass in all of the gitlab-ci jobs.

While updating the PHPUnit Test I was testing the module using the combination of PHP 8.3 and Drupal Core 11.0.13 as well.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

At the moment, when I enable the gin_toolbar module without the gin them being enabled the javascript breaks because the toolbar id changes from toolbar-bar to gin-toolbar-bar.

Additionally, when enabling the submodule the "default" environment indicator appears.

What should we do about the toolbar integration setting? I think if the environment_indicator_toolbar submodule is enabled, the default indicator should be disabled to keep existing functionality.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 3065135-add-support-for-tugboat to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

FYI I've added instructions to this module's .tugboat configuration file to install gin and gin_toolbar module, set gin as the default admin theme, and three environment switchers in order to help us test.

To view a demo site with a copy of the module installed with this merge request applied, click the view live preview link under this issue's summary.

To log in use these credentials
username: admin
password: admin

I've done the same on 📌 Update module to use CSS variables instead of adding inline CSS. Active If you'd like to review that alternate Merge request.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

FYI I've added instructions to this module's .tugboat configuration file to install gin and gin_toolbar module, set gin as the default admin theme, and three environment switchers in order to help us test.

To view a demo site with a copy of the module installed with this merge request applied, click the view live preview link under this issue's summary.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 changed the visibility of the branch 3487973-add-gin-theme to hidden.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Hi there, if this issue is resolved by either 🐛 Gin Compatibility: Account for "open" vertical toolbar Closed: outdated or 📌 Update module to use CSS variables instead of adding inline CSS. Active we could use your review on those issues instead. If so, please close this one as either a duplicate or outdated.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Hi, were you experiencing any console errors on the environment that the favicon is broken on? I noticed that the dependency order of the libraries is weird in this file https://git.drupalcode.org/project/environment_indicator/-/blob/4.x/envi...

If it is a load order thing, the solution in Separate Tinycon into its own library and use favicon option to determine inclusion. Active may resolve it.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

I've converted the patch to a merge request and updated it to integrate any upstream changes that have been merged.

Unfortunately this does not seem to work for me using Lando for local development.

If I enter: /core/themes/olivero/favicon.ico

The Json settings output looks like this

"environmentIndicator":{"name":"Lando","fgColor":"#EFEFEF","bgColor":"#990055","addFavicon":true,"faviconPath":"\/app\/web\/core\/themes\/olivero\/favicon.ico","toolbars":{"toolbar":"toolbar"}}

Seems to be setting the absolute path on the server.

Here is my config
```
name: environment_indicator
recipe: drupal10
config:
php: '8.3'
via: apache:2.4
webroot: web
database: mariadb:10.6
xdebug: false
services:
database:
type: compose
services:
image: mariadb:10.6
command: docker-entrypoint.sh mariadbd
restart: always
ports:
- '3306'
environment:
MARIADB_ALLOW_EMPTY_ROOT_PASSWORD: 'true'
MARIADB_DATABASE: drupal10
MYSQL_DATABASE: drupal10
MARIADB_USER: drupal10
MARIADB_PASSWORD: drupal10
appserver:
overrides:
environment:
SIMPLETEST_DB: 'mysql://drupal10:drupal10@database/drupal10'
SIMPLETEST_BASE_URL: 'http://appserver'
volumes:
# Don't share our host working directory as /app. We want /app empty for composer.
- /app
# Instead share our host working directory as a standalone package.
- .:/usr/local/environment_indicator
build:
# Create a new Drupal project and use the module as a non-packagist repository.
- composer create-project --dev drupal/recommended-project:11.1.x /app
- composer config extra.enable-patching true
- composer config extra.composer-exit-on-patch-failure true
- composer config allow-plugins.cweagans/composer-patches true
- composer require cweagans/composer-patches
- composer config minimum-stability dev
- composer config allow-plugins.phpstan/extension-installer true
- composer require --dev drupal/core-dev:^11.1 drush/drush phpspec/prophecy-phpunit:* phpstan/extension-installer mglaman/phpstan-drupal phpstan/phpstan-deprecation-rules drupal/config_inspector drupal/devel drupal/gin
- composer config repositories.localdev path /usr/local/environment_indicator && composer require drupal/environment_indicator:\*@dev
node:
type: node:20
build:
- yarn install
chromedriver:
type: compose
services:
image: seleniarm/standalone-chromium:4.1.4-20220429
command: /opt/bin/entry_point.sh
tooling:
# Provide a command to install Drupal.
install:
service: appserver
cmd:
- /app/vendor/bin/drush --root=/app/web site:install --account-mail=noreply@example.com --account-name=admin --account-pass=admin --db-url=mysql://drupal10:drupal10@database:3306/drupal10 -y --verbose
- /app/vendor/bin/drush --root=/app/web en -y environment_indicator environment_indicator_ui devel config_inspector
- /app/vendor/bin/drush --root=/app/web theme:enable -y gin
- /app/vendor/bin/drush --root=/app/web config:set -y system.theme admin gin
- /app/vendor/bin/drush --root=/app/web en -y gin_toolbar
- /app/vendor/bin/drush --root=/app/web config:set -y environment_indicator.indicator name 'Lando'
- /app/vendor/bin/drush --root=/app/web config:set -y environment_indicator.indicator bg_color '#990055'
- /app/vendor/bin/drush --root=/app/web config:set -y environment_indicator.indicator fg_color '#EFEFEF'
- /app/vendor/bin/drush --root=/app/web uli -l https://environmentindicator.lndo.site/
# Provide Drush tooling to automatically know the Drupal root.
drush:
service: appserver
cmd: /app/vendor/bin/drush --root=/app/web
phpcs:
service: appserver
cmd: /app/vendor/bin/phpcs -s --colors --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml web/modules/contrib/environment_indicator
# Provide PHPCBF tooling to fix coding standards.
phpcbf:
service: appserver
cmd: /app/vendor/bin/phpcbf -s --colors --standard=Drupal,DrupalPractice --extensions=php,module,inc,install,test,profile,theme,css,info,txt,md,yml web/modules/contrib/environment_indicator
# Provide phpstan tooling to check for code quality and deprecated code.
phpstan:
service: appserver
cmd: /app/vendor/bin/phpstan analyse --configuration web/modules/contrib/environment_indicator/phpstan.neon web/modules/contrib/environment_indicator
# Provide phpunit tooling to run unit tests.
phpunit:
service: appserver
cmd: /app/vendor/bin/phpunit --configuration /app/web/core/phpunit.xml.dist --bootstrap /app/web/core/tests/bootstrap.php /app/web/modules/contrib/environment_indicator
yarn:
service: node
cmd: yarn
eslint:
service: node
cmd: yarn run eslint --color

```

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

trackleft2 made their first commit to this issue’s fork.

🇺🇸United States trackleft2 Tucson, AZ 🇺🇸

Thank you for your inquiry, I've updated the issue summary. I welcome a merge request

Production build 0.71.5 2024