Skip to content

Conversation

aabadie
Copy link
Contributor

@aabadie aabadie commented Jun 11, 2019

Contribution description

This variable is only used by drone.yml file and we don't use drone.io as CI anymore. Maybe the .drone.yml could also be removed ?

For the record, the Makefile.include of related boards were updated using the following command:

find . -name Makefile.features | xargs sed -i '/^# The board M[P,C]U family/,+2d'

Testing procedure

A green CI should be ok.

Issues/PRs references

fixes #10491
Waiting on #11672 as the way to handle the error message needs special handling with mac.

@aabadie aabadie added Type: cleanup The issue proposes a clean-up / The PR cleans-up parts of the codebase / documentation Area: CI Area: Continuous Integration of RIOT components labels Jun 11, 2019
@aabadie aabadie requested review from cladmi and kaspar030 June 11, 2019 06:47
@kaspar030
Copy link
Contributor

we don't use drone.io as CI anymore. Maybe the .drone.yml could also be removed ?

IIRC think @vincent-d uses Drone internally?
Maybe the Drone file can be changed not to use the variable anymore.

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

This was also referenced in #10491

This could also go with a removal/cleanup of BUILDTEST_MCU_GROUP if it is unused too.

@aabadie
Copy link
Contributor Author

aabadie commented Jun 11, 2019

This was also referenced in #10491

Thanks for the pointer, I didn't find it initially.

IIRC think @vincent-d uses Drone internally?
Maybe the Drone file can be changed not to use the variable anymore.

Agreed

@aabadie
Copy link
Contributor Author

aabadie commented Jun 11, 2019

This could also go with a removal/cleanup of BUILDTEST_MCU_GROUP if it is unused too.

git grep returns some use of BUILDTEST_MCU_GROUP with Murdock.

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

This could also go with a removal/cleanup of BUILDTEST_MCU_GROUP if it is unused too.

git grep returns some use of BUILDTEST_MCU_GROUP with Murdock.

Only to call the static-tests part of ci/build_and_test.sh, which would better be in dist/tools/static-tests.sh directly.

It would need some refactoring and is not a simple removal as this one.

@aabadie aabadie force-pushed the pr/boards/remove_features_mcu_group branch from bf1186c to 063350d Compare June 11, 2019 09:18
@aabadie
Copy link
Contributor Author

aabadie commented Jun 11, 2019

It would need some refactoring and is not a simple removal as this one.

Indeed, let's leave this to a follow-up PR.

@aabadie aabadie force-pushed the pr/boards/remove_features_mcu_group branch from 063350d to 7d908f6 Compare June 11, 2019 09:24
@vincent-d
Copy link
Member

IIRC think @vincent-d uses Drone internally?

I don't ;)

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

Indeed, let's leave this to a follow-up PR.

It is what I was thinking too, but was not clear while writing it.

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

Removing this variable was also in my targets, so is good on my side. It just depends on the CI constraints.

I will a follow up PR to prevent-the variable to be re-included by a non updated PR.

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

The follow up for preventing the variable to re-appear #11671

It showed that boards/same54-xpro must also be cleaned up.

If you want you can take the second commit alone and use it in this PR directly.

@aabadie
Copy link
Contributor Author

aabadie commented Jun 11, 2019

If you want you can take the second commit alone and use it in this PR directly.

That's what I'll do.

Since @vincent-d is not using drone.io, I guess the file could be completely removed ?

pathspec+=(":!${SCRIPT_PATH}")

git -C "${RIOTBASE}" grep "${patterns[@]}" -- "${pathspec[@]}" \
| sed '1i Deprecated variables or patterns:'
Copy link
Contributor

Choose a reason for hiding this comment

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

I added this change in a fixup commit in #11671

Suggested change
| sed '1i Deprecated variables or patterns:'
| sed '1i \\nDeprecated variables or patterns:'

It is required to behave correctly when multiple errors are shown.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I cherry-picked the fixup commit

@@ -87,12 +87,31 @@ check_not_exporting_variables() {
fi
}

# Deprecated variables or patterns
# Prevent deprecated varibles or patterns to re-appear after cleanup
Copy link
Contributor Author

Choose a reason for hiding this comment

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

s/varibles/variables/

Copy link
Contributor

Choose a reason for hiding this comment

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

Indeed

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I just fixed it

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

boards/same54-xpro must also be cleaned up, and it shown by the static tests \o/

@cladmi
Copy link
Contributor

cladmi commented Jun 11, 2019

You can already squash the fixups and start a round on CI.

For the commits order, I would rather remove the usage first explaining why it is removed and then remove the definitions.
Otherwise the first commit removes the definitions while still being referenced and without justification.

Otherwise I agree with removing them, and if CI works without it, its good for me.

@aabadie aabadie force-pushed the pr/boards/remove_features_mcu_group branch from bd1173d to 2440ac4 Compare June 11, 2019 15:36
@aabadie aabadie added the CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR label Jun 11, 2019
@aabadie
Copy link
Contributor Author

aabadie commented Jun 11, 2019

Thanks @cladmi. I squashed and reordered the commits like you suggested. Let's see what Murdock has to say.

@cladmi
Copy link
Contributor

cladmi commented Jun 13, 2019

The first commit documentation is not adapted.

    makefiles/info-global: remove use of FEATURES_MCU_GROUP
    
    The whole ifdef block depends on the fact that the FEATURES_MCU_GROUP variable is set but there
    no more occurence of it in the codebase. We can safely remove it.

The whole ifdef is depending on BUILDTEST_MCU_GROUP, not on FEATURES_MCU_GROUP. This disables the test filtering based on BUILDTEST_MCU_GROUP. Which will deprecate FEATURES_MCU_GROUP.

And after re-ordering, the definition are currently still there.

@aabadie aabadie force-pushed the pr/boards/remove_features_mcu_group branch from 2440ac4 to 3c362a8 Compare June 13, 2019 11:11
@aabadie
Copy link
Contributor Author

aabadie commented Jun 13, 2019

The first commit documentation is not adapted.

I changed it.

@cladmi
Copy link
Contributor

cladmi commented Jun 13, 2019

@kaspar030 @smlng from the CI point of view you agree this can be removed ?

@smlng
Copy link
Member

smlng commented Jun 13, 2019

to me this was inflexible anyway, and I think its not used anywhere anymore

@cladmi cladmi added the State: waiting for other PR State: The PR requires another PR to be merged first label Jun 13, 2019
pathspec+=(":!${SCRIPT_PATH}")

git -C "${RIOTBASE}" grep "${patterns[@]}" -- "${pathspec[@]}" \
| sed '1i \\nDeprecated variables or patterns:'
Copy link
Contributor

Choose a reason for hiding this comment

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

@aabadie #11672 was merged and changed the way to do the "buildsystem_sanity_check". Can you please rebase and adapt ?

Suggested change
| sed '1i \\nDeprecated variables or patterns:'
| error_with_message 'Deprecated variables or patterns:'


main() {
local errors=''

errors+="$(check_not_parsing_features)"
errors+="$(check_not_exporting_variables)"
errors+="$(check_deprecated_vars_patterns)"
Copy link
Contributor

Choose a reason for hiding this comment

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

The function should now be added the list in all_checks.

aabadie and others added 4 commits June 14, 2019 11:32
This is the last use of FEATURES_MCU_GROUP variable and thus it
deprecates it.
Add a function to list deprecated variables or patterns and use it for
* FEATURES_MCU_GROUP
@aabadie aabadie force-pushed the pr/boards/remove_features_mcu_group branch from 3c362a8 to 7d65a71 Compare June 14, 2019 09:34
@aabadie
Copy link
Contributor Author

aabadie commented Jun 14, 2019

@cladmi, rebased!

@kaspar030
Copy link
Contributor

git grep returns some use of BUILDTEST_MCU_GROUP with Murdock.

Only to call the static-tests part of ci/build_and_test.sh, which would better be in dist/tools/static-tests.sh directly.

It would need some refactoring and is not a simple removal as this one.

has this been addressed?

@aabadie
Copy link
Contributor Author

aabadie commented Jun 14, 2019

has this been addressed?

Is it supposed to be addressed here ? From previous @cladmi's comment, this is unclear to me.

@kaspar030
Copy link
Contributor

Is it supposed to be addressed here ? From previous @cladmi's comment, this is unclear to me.

Well, the static-tests are still run for this PR, and IIRC that's the only thing where the buildgroups variable was used by murdock, so I think we're good!

@cladmi
Copy link
Contributor

cladmi commented Jun 14, 2019

BUILDTEST_MCU_GROUP is different from FEATURES_MCU_GROUP which is removed by this PR.

It currently is only used with BUILDTEST_MCU_GROUP=static-tests.

@aabadie aabadie added CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR and removed State: waiting for other PR State: The PR requires another PR to be merged first CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR labels Jun 14, 2019
Copy link
Contributor

@cladmi cladmi left a comment

Choose a reason for hiding this comment

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

ACK, good to remove it for me.

No counter arguments from the CI maintainers.

@cladmi
Copy link
Contributor

cladmi commented Jun 17, 2019

Static test is still valid with last master, checked locally.

@cladmi cladmi merged commit a379d95 into RIOT-OS:master Jun 17, 2019
@aabadie
Copy link
Contributor Author

aabadie commented Jun 17, 2019

Thanks!

@aabadie aabadie deleted the pr/boards/remove_features_mcu_group branch July 2, 2019 11:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area: CI Area: Continuous Integration of RIOT components CI: ready for build If set, CI server will compile all applications for all available boards for the labeled PR Type: cleanup The issue proposes a clean-up / The PR cleans-up parts of the codebase / documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

FEATURES_MCU_GROUP is no longer used
5 participants