Skip to content

Commit

Permalink
Merge pull request #48 from massgov/release/0.225.0
Browse files Browse the repository at this point in the history
Release0.225.0
  • Loading branch information
ygannett authored Dec 18, 2019
2 parents 0a10e77 + e32dec0 commit e4dcc33
Show file tree
Hide file tree
Showing 16 changed files with 80 additions and 108 deletions.
12 changes: 12 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@


## [0.225.0] - December 18, 2019

### Changed
- DP-16764: Stop purge from false exception at end of a deployment.
- DP-16689: Exclude purges sent to New Relic.

### Added
- DP-16429: KPI information added to api/v1/content-metadata REST endpoint

## [0.224.1] - December 11, 2019

### Changed

- DP-16759: Downgrade Drush to fix sitemap and massdocs cron tasks.
- DP-16759: `ma:deploy` erroring during cache clearing.

## [0.224.0] - December 11, 2019

Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ _The official website of the Commonwealth of Massachusetts_

This is the codebase for the Drupal 8 web site `www.mass.gov`. The site's theme, [mass_theme](https://github.com/massgov/openmass/blob/develop/docroot/themes/custom/mass_theme/README.md), is powered by Mayflower, a companion repo available at https://github.com/massgov/mayflower.

See the [Table of Contents](/docs/README.md) for additional documentation related to this repository. In addition, there is [documentation for the Mass Digital team](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/README.md) that covers topics such as [Releases](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/release.md).
See the [Table of Contents](/docs/README.md) for additional documentation related to this repository. In addition, there is [documentation for the Mass Digital team](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/README.md) that covers topics such as [Releases](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/releases/release.md).

## Getting Started

Expand Down Expand Up @@ -58,7 +58,7 @@ This is a suggestion for how you can transition between branches when working on
### Blackfire
[Blackfire](http://blackfire.io/) is available for performance profiling of CLI or web requests. See `.env.example` for information on how to enable it, and the [Performance Documentation](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/Performance.md#running-blackfire) on how to use it.
[Blackfire](http://blackfire.io/) is available for performance profiling of CLI or web requests. See `.env.example` for information on how to enable it, and the [Performance](https://github.com/massgov/openmass/blob/develop/docs/performance.md#blackfire) documentation on how to use it.
### Email
Expand Down
33 changes: 0 additions & 33 deletions changelogs/DP-16759-2.yml

This file was deleted.

33 changes: 0 additions & 33 deletions changelogs/DP-16759.yml

This file was deleted.

3 changes: 3 additions & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -342,6 +342,9 @@
"Dynamic routes like image styles break under pathologic (https://www.drupal.org/project/pathologic/issues/2718473)": "https://www.drupal.org/files/issues/2018-11-14/2718473-dynamic-image-style-lookup-19.patch",
"Convert href to the aliased url if possible (https://www.drupal.org/project/pathologic/issues/2692641#comment-13317616)": "https://www.drupal.org/files/issues/2019-10-20/2692641-15.diff"
},
"drupal/purge": {
"Remove exception during first run in p:queue-work (https://www.drupal.org/project/purge/issues/3101392)": "https://www.drupal.org/files/issues/2019-12-16/empty.patch"
},
"drupal/office_hours": {
"Fix timezone for the office hours module": "patches/fix-timezone-for-office-hours.patch"
},
Expand Down
5 changes: 4 additions & 1 deletion composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public function get() {
if (!empty($org)) {
$organization = [
'name' => $org->name->value,
'uuid' => $org->uuid->value,
'uuid' => $org->uuid(),
'id' => $org->tid->value,
];
}
Expand All @@ -135,6 +135,24 @@ public function get() {
}
}

/*
* Get any field_kpi_ fields for this entity.
* See https://jira.mass.gov/browse/DP-16429.
*/
$kpis = [];
$info = $item->getFieldDefinitions();
foreach ($info as $name => $field) {
if (strpos($name, 'field_kpi_') !== FALSE) {
$is_pct = strpos($name, '_pct') !== FALSE;
$is_ctr = strpos($name, '_ctr') !== FALSE;
$value = $item->get($name)->value;
if ($value && ($is_ctr || $is_pct)) {
$value = $value / 100;
}
$kpis[$name] = $value;
}
}

$roles = array_map($get_target_id, $node_owner->roles->getValue());
$mod_state = $item->moderation_state->getValue();
$path = $this->aliasManager->getAliasByPath('/node/' . $item->nid->value);
Expand All @@ -160,6 +178,7 @@ public function get() {
'is_intern' => $node_owner->field_user_intern->value == 1,
'roles' => $roles,
],
'kpis' => $kpis,
];

if ($flag_show_flat) {
Expand Down
1 change: 1 addition & 0 deletions docroot/sites/default/services.acquia.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ parameters:
monolog.channel_handlers:
# Log to syslog and NewRelic
default: ['acquia_syslog', 'acquia_newrelic']
purge: ['acquia_syslog']
4 changes: 2 additions & 2 deletions docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
See also: [Documentation for Mass Digital team](https://github.com/massgov/DS-Infrastructure/blob/develop/docs/massgov/README.md) (not public)

## Developer basics
- [Getting Started](#getting-started)
- [Getting Started](https://github.com/massgov/openmass#getting-started)
- Clone the repo; set up Docker and ahoy; workflow
- [Changelog Instructions](changelog_instructions.md)
- [Composer](composer.md)
Expand Down Expand Up @@ -31,7 +31,7 @@ Contributors should familiarize themselves with existing modules both custom and

## Testing
- [Testing](testing.md)
- [Behat & PHPUnit](testing.md#run-tests-locally)
- [Behat & PHPUnit](https://github.com/massgov/openmass/blob/develop/docs/testing.md#tests-run-on-every-pr)
- [Backstop](https://github.com/massgov/openmass/blob/develop/backstop/README.md)
- [Performance Optimization and Profiling (Blackfire.io)](performance.md)
- [Nightcrawler](https://github.com/massgov/openmass/blob/develop/.circleci/nightcrawler/README.md)
Expand Down
6 changes: 3 additions & 3 deletions docs/composer.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

Composer uses a "lock file", named `composer.lock`. Whereas `composer.json` can specify "loose" versions of the packages you need, `composer.lock` will always specify exact versions. This allows `composer install` to be very fast, and ensures that all developers on the project are using the same versions. As a rule of thumb, any time you change `composer.json`, you should run `composer update --lock` to regenerate the lock file so the two stay in sync.

\*\*Important: You should never just delete the lock file. If you hit a conflict, see the [conflict resolution](#Conflicts) section.
\*\*Important: You should never just delete the lock file. If you hit a conflict, see the [conflict resolution](#Conflicts) section below.

## Installing a new package/module:

Expand Down Expand Up @@ -55,12 +55,12 @@ Most packages that are used will follow [Semantic Versioning](https://semver.org

## Tips/Troubleshooting

- Symfony components have been added to `composer.json` as root requirements. This is only to [save memory during the update process](https://jira.mass.gov/browse/DP-7567). It is against best practices to add dependencies of dependencies to your root `composer.json`, but the memory and time savings made it worth it for this project. To update these in the future, open Drupal core's `composer.json` and copy out the `symfony/` dependencies into the root `composer.json`
- Symfony components have been added to `composer.json` as root requirements. This is only to [save memory during the update process](https://github.com/massgov/mass/pull/1784). It is against best practices to add dependencies of dependencies to your root `composer.json`, but the memory and time savings made it worth it for this project. To update these in the future, open Drupal core's `composer.json` and copy out the `symfony/` dependencies into the root `composer.json`
- Use loose version constraints wherever possible. This will allow the version to be updated in the future without changing `composer.json`.

- On occasion, `composer.json` and `composer.lock` files can get out of sync. In order to prevent this from happening, we enabled CircleCI to run `composer validate`. This validation process ensures that both `.json` and `.lock` are in sync and no `json` syntax errors exist. If you get an error that these two files are out of sync, run `composer update --lock` on your local branch and commit the output of this operation.

- If you have trouble running `ahoy comi` you can try deleting the vendor directory and rerunning `composer install` to get a fresh copy of the vendor directory:
- `cd <path/to/mass>`
- `rm -r vendor`
- `composer install`
- `composer install`
2 changes: 1 addition & 1 deletion docs/modules.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,5 @@ Follow these steps in order to keep Mass.gov up to date with desired dependency
1. If the new version of your package is included in the version constraint in `composer.json`, then you can update your package by running `composer update <package owner>/<package> -- with dependencies`. For example, `composer update drupal/bad_judgement --with-dependencies`. _(If the update was successful, then `git status` should show changes to `composer.lock` to reflect the new package version.)_
1. If the new version of your package is _not_ included in the version constraint in `composer.json`, then you need to first update the version constraint and then update the package by running `composer require <package owner>/<package name>:<version constraint> --update-with-dependencies`. For example, `composer require drupal/bad_judgement:^3.0 --update-with-dependencies`. _(If the update was successful, then `git status` should show changes to both `composer.json` and `composer.lock` to reflect the new package version constraint and installed version, respectively.)_
1. Test Mass.gov with the new release (remember to `drush cr`!):
1. Smoke test the [Mass.gov featureset](releases/smoke_testing.md) to ensure existing functionality has not been broken - especially the functionality that the dependency adds.
1. [Smoke test](https://github.com/massgov/DS-Infrastructure/blob/develop/smoke_testing.md) Mass.gov to ensure existing functionality has not been broken - especially the functionality that the dependency adds.
1. Functional test: Does this release introduce new functionality? Verify that this functionality works in Mass.gov. If any issues are identified during testing steps, make the necessary code fixes in Mass.gov to accommodate.
2 changes: 1 addition & 1 deletion docs/peer_review_checklist.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## General

- [ ] Does the PR include a changelog.yml file [see instructions](changelog_instructions.md)?
- [ ] Does the PR include a changelog.yml file ([see instructions](changelog_instructions.md))?
- [ ] Does the code actually work? Does it perform its intended function, is the logic correct, etc.
- [ ] Does the code break other stuff? (Acknowledge that you can't test everything, but think about it). A common offense: custom rendering of a field that is used in more than one place or in more than one context.
- [ ] Is all the code easily understood? Does anything confuse you or give you pause?
Expand Down
1 change: 0 additions & 1 deletion docs/performance.md
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ To get the environment details follow these steps:
2. Go to the `Databases` on the left column
3. Click the `Details` tab, where you will see the information you need to make the SSH connection.

![ssh database](assets/sequel_pro.png)

The query in question can be found in different ways. Here are a few approaches to consider:

Expand Down
Loading

0 comments on commit e4dcc33

Please sign in to comment.