Skip to content
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

Do not specify a category delimiter by default #13688

Merged
merged 11 commits into from Nov 29, 2018
Merged

Do not specify a category delimiter by default #13688

merged 11 commits into from Nov 29, 2018

Conversation

tsteur
Copy link
Member

@tsteur tsteur commented Nov 8, 2018

Doesn't require a note in the developer changelog but we should ideally mention this in the changelog as it is changing the behaviour for people that actually want to use it.

Tested it locally and worked.

fix #2956

@tsteur tsteur added not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org. Needs Review PRs that need a code review labels Nov 8, 2018
@tsteur tsteur added this to the 3.8.0 milestone Nov 8, 2018
@sgiehl
Copy link
Member

sgiehl commented Nov 11, 2018

Guess it makes sense to set it empty by default. Regarding mentioning it in a changelog: Might it make sense to trigger a notification within Matomo after updating to explain the possible change to the super user once?

@tsteur
Copy link
Member Author

tsteur commented Nov 11, 2018

I reckon it's not needed as long as it is mentioned clearly in the regular changelog. I suppose not too many people are too keen on how this feature worked previously and might maybe rather confuse people?

@sgiehl
Copy link
Member

sgiehl commented Nov 11, 2018

Guess you're right. The page title report might not be one of the frequently used reports at all

@diosmosis
Copy link
Member

Looks like this change causes issues in displaying the "Page Name not defined" text, not sure why on first glance.

@tsteur
Copy link
Member Author

tsteur commented Nov 26, 2018

pushed a fix that hopefully resolves the issue. I'll have a look at the failing tests and update them later.

@tsteur
Copy link
Member Author

tsteur commented Nov 26, 2018

Things should work now. There were various bugs around the delimiter in the code and the code is quite hard to understand / messy. Also added to some tests the delimiter with / to make sure this doesn't regress.

if (empty($name)) {
$name = self::getUnknownActionName($type);
}
return array(trim($name));
Copy link
Member

Choose a reason for hiding this comment

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

Should we do the trim() before checking for an empty($name)?

Copy link
Member Author

Choose a reason for hiding this comment

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

done, also realised empty but not be best if the name of a title is 0 (which might not happen but who knows)

public static function setUpBeforeClass()
{
parent::setUpBeforeClass(); // TODO: Change the autogenerated stub
}
Copy link
Member

Choose a reason for hiding this comment

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

Not super important to me, but don't need this method.

Copy link
Member Author

Choose a reason for hiding this comment

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

will remove it 👍

return $previous;
}),
);
}
Copy link
Member

Choose a reason for hiding this comment

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

Should we just change the tests w/ the new config or is there value in keeping the old behavior in all tests?

Copy link
Member

Choose a reason for hiding this comment

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

Actually, it looks like only a couple of the tests have this, so I guess most use the new default?

Copy link
Member Author

Choose a reason for hiding this comment

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

Most use default empty, but wanted to make sure some tests still use this behaviour to test it as well.

Copy link
Member

Choose a reason for hiding this comment

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

👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs Review PRs that need a code review not-in-changelog For issues or pull requests that should not be included in our release changelog on matomo.org.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Actions>Page Titles believes there is a subpage if page <title> includes a forwards slash
3 participants