Skip to content

[ci] allow flex to run in CI #17020

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

Merged
merged 1 commit into from
Jul 22, 2022
Merged

Conversation

jrushlow
Copy link
Contributor

@jrushlow jrushlow commented Jul 20, 2022

Since Composer 2.3.9 unless you explicitly allow/disallow a plugin (flex in our case), an error is thrown (halts our CI run) before any tests are actually ran. (Code Blocks)

@jrushlow jrushlow requested a review from OskarStark as a code owner July 20, 2022 20:27
@carsonbot carsonbot added this to the 5.4 milestone Jul 20, 2022
@jrushlow jrushlow changed the base branch from 5.4 to 4.4 July 20, 2022 20:28
@xabbuh
Copy link
Member

xabbuh commented Jul 21, 2022

Flex is already allowed in the application (see https://github.com/symfony-tools/code-block-checker/blob/main/composer.json#L48). That should be enough, shouldn't it?

@jrushlow
Copy link
Contributor Author

jrushlow commented Jul 21, 2022

It is allowed for that package symfony-tools/code-block-checker but that wont automatically allow it in packages that use code-block-checker. So you have to explicitly allow that in symfony-docs CI as well to my understanding. Ref - symfony/maker-bundle#1145 (comment)

https://github.com/symfony/symfony-docs/runs/7438798967?check_suite_focus=true shows CI failing due to the plugin not explicitly being allowed.

EDIT a better example w/ CI failing because of allow_plugins #17023

@javiereguiluz
Copy link
Member

Jesse, thanks for this fix too.

@javiereguiluz javiereguiluz merged commit 36cf603 into symfony:4.4 Jul 22, 2022
@xabbuh
Copy link
Member

xabbuh commented Jul 22, 2022

Good hint @jrushlow. I think we should fix it their too (see symfony-tools/symfony-application#14).

@jrushlow jrushlow deleted the ci/fix-flex branch July 22, 2022 18:36
javiereguiluz added a commit that referenced this pull request Aug 3, 2022
This PR was squashed before being merged into the 5.4 branch.

Discussion
----------

Enable code blocks

Revert 8f250a2

Revert fb505de from #17020

Tests were broken, see that example from #17098:

```
Run composer config --no-plugins allow-plugins.symfony/flex true
Error: File "./composer.json" cannot be found in the current directory

In ConfigCommand.php line 206:

  File "./composer.json" cannot be found in the current directory

config [-g|--global] [-e|--editor] [-a|--auth] [--unset] [-l|--list] [-f|--file FILE] [--absolute] [-j|--json] [-m|--merge] [--append] [--source] [--] [<setting-key> [<setting-value>...]]

Error: Process completed with exit code 1.
```

[full output](https://github.com/symfony/symfony-docs/runs/7640214086?check_suite_focus=true)

It should not be necessary now that symfony-tools/symfony-application#14 has been merged.

Commits
-------

7bff8b5 Enable code blocks
HeahDude added a commit to HeahDude/symfony-docs that referenced this pull request Aug 6, 2022
javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Aug 8, 2022
This PR was merged into the 4.4 branch.

Discussion
----------

Fix CI by reverting symfony#17020

The CI is failing in symfony#16992 because of this, see https://github.com/symfony/symfony-docs/runs/7704382531?check_suite_focus=true.

My guess if that it's now fixed upstream thanks to symfony-tools/symfony-application#14.

Commits
-------

7c7c76e fix CI by reverting symfony#17020
javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Aug 8, 2022
* 4.4:
  fix CI by reverting symfony#17020
javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Aug 8, 2022
* 5.4:
  fix CI by reverting symfony#17020
javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Aug 8, 2022
* 6.0:
  fix CI by reverting symfony#17020
javiereguiluz added a commit to javiereguiluz/symfony-docs that referenced this pull request Aug 8, 2022
* 6.1:
  fix CI by reverting symfony#17020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants