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

Make sure that getConfig is still called for browsers that do not support CSPv3 #22636

Merged
merged 1 commit into from
Sep 9, 2020

Conversation

juliusknorr
Copy link
Member

Fixes a regression from cbd2086 where browsers that do not support CSP v3 would not have initial state for config and capabilities provided. They are set in

$this->initialStateService->provideInitialState('core', 'config', $config);
$this->initialStateService->provideInitialState('core', 'capabilities', $capabilities);
which never got called for those browsers.

…port CSPv3

Signed-off-by: Julius Härtl <jus@bitgrid.net>
@juliusknorr
Copy link
Member Author

/backport to stable19

@juliusknorr
Copy link
Member Author

Should fix cypress tests in text where this was causing the sharing sidebar to not show the share link button since the sharing sidebar was unable to determine if OC.getCapabilities().files_sharing.public.enabled was set because of the missing capabilities.

@juliusknorr
Copy link
Member Author

We should ideally separate the injected ones from the initial state, however this pr is keeping changes minimal for easier backporting.

@faily-bot
Copy link

faily-bot bot commented Sep 7, 2020

🤖 beep boop beep 🤖

Here are the logs for the failed build:

Status of 32730: failure

mariadb10.4-php7.3

Show full log
There were 2 warnings:

1) Test\Files\ViewTest::testRenameFailDeleteTargetKeepSource
Trying to configure method "writeStream" which cannot be configured because it does not exist, has not been specified, is final, or is static

2) Test\Files\ViewTest::testCopyFailDeleteTargetKeepSource
Trying to configure method "writeStream" which cannot be configured because it does not exist, has not been specified, is final, or is static

--

There was 1 failure:

1) Test\SystemTag\SystemTagManagerTest::testUpdateTagDuplicate with data set #2 (array('one', false, false), array('one', true, true))
Failed asserting that exception of type "OCP\SystemTag\TagNotFoundException" matches expected exception "OCP\SystemTag\TagAlreadyExistsException". Message was: "Tag does not exist" at
/drone/src/lib/private/SystemTag/SystemTagManager.php:238
/drone/src/tests/lib/SystemTag/SystemTagManagerTest.php:382
.

@nickvergessen nickvergessen added 4. to release Ready to be released and/or waiting for tests to finish and removed 3. to review Waiting for reviews labels Sep 9, 2020
@nickvergessen nickvergessen added this to the Nextcloud 20 milestone Sep 9, 2020
@nickvergessen nickvergessen merged commit e280c05 into master Sep 9, 2020
@nickvergessen nickvergessen deleted the bugfix/noid/initial-stte-cspv3 branch September 9, 2020 11:12
@backportbot-nextcloud
Copy link

The backport to stable19 failed. Please do this backport manually.

@MorrisJobke
Copy link
Member

Backport in #22904

azul added a commit to nextcloud/text that referenced this pull request Dec 26, 2020
The `bugfix/noid/initial-stte-cspv3` branch has been merged into master in
nextcloud/server#22636 .

It does not exist anymore which will cause issues when trying to run the cypress tests.

Remove the `$BRANCH` environment variable from the docker-compose.yml.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4. to release Ready to be released and/or waiting for tests to finish bug regression
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants