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

Arduino lint #1743

Merged
merged 14 commits into from
Jun 21, 2022
Merged

Arduino lint #1743

merged 14 commits into from
Jun 21, 2022

Conversation

fpistm
Copy link
Member

@fpistm fpistm commented Jun 20, 2022

This PR:

@fpistm fpistm added this to the 2.3.0 milestone Jun 20, 2022
@fpistm fpistm requested a review from ABOSTM June 20, 2022 09:21
@fpistm fpistm added this to In progress in STM32 core based on ST HAL via automation Jun 20, 2022
@fpistm
Copy link
Member Author

fpistm commented Jun 20, 2022

Hi @valeros

Could you help me on this issue with pio build:
https://github.com/stm32duino/Arduino_Core_STM32/runs/6964033012?check_suite_focus=true#step:3:8213

This PR adds some examples. One required to enable USB HID options.
How can we define it or simply skip it if not applicable?

@valeros
Copy link
Contributor

valeros commented Jun 20, 2022

Hi @fpistm ! I see here several options:

  • Update CI/build/platformio-builder.py in a way that it will dynamically detect whether an example requires additional USB flags/macros (e.g. based on example name).
  • Introduce a special file that will indicate that this example shouldn't be compiled. Something like it's done in the Arduino core for ESP32 here.
  • Simply maintain a list of skipped examples or keywords in CI/build/platformio-builder.py.

Does anything from the above make sense?

@fpistm
Copy link
Member Author

fpistm commented Jun 20, 2022

Thanks @valeros for the quick feedback

I guess this one is the simpliest

Simply maintain a list of skipped examples or keywords in CI/build/platformio-builder.py.

From my point of view, it is not needed to build all examples. The only drawback I see here is that dedicated build options is not tested against pio. here the USB HID.

valeros added a commit to valeros/Arduino_Core_STM32 that referenced this pull request Jun 20, 2022
By default `Keyboard` and `Mouse` libraries are skipped as they may require additional configuration steps

Related stm32duino#1743
fpistm pushed a commit that referenced this pull request Jun 21, 2022
By default `Keyboard` and `Mouse` libraries are skipped as they may require additional configuration steps

Related #1743
fpistm added 14 commits June 21, 2022 09:38
even if those pattern properties are present thanks other patterns
to shorten some recipe lines.

WARNING: recipe.c.o.pattern property value does not contain a {compiler.c.extra_flags} reference. This is necessary to
         allow the user to customize the compiler command. (Rule PF057)
WARNING: recipe.S.o.pattern property value does not contain a {compiler.S.extra_flags} reference. This is necessary to
         allow the user to customize the compiler command. (Rule PF063)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties name CMSIS DSP contains spaces. Although supported, best practices is to not use spaces.
         (Rule LP015)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
ERROR: library.properties url value is less than minimum length. (Rule LP056)
ERROR: library.properties url field value  does not have a valid URL format. (Rule LP041)
WARNING: Unable to load the library.properties url field: Head "": unsupported protocol scheme "" (Rule LP042)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties maintainer value Arduino <info@arduino.cc> starts with "Arduino". 3rd party libraries are
         not maintained by Arduino. (Rule LP027)
WARNING: library.properties maintainer value Arduino <info@arduino.cc> contains "Arduino". 3rd party libraries are not
         maintained by Arduino. (Rule LP057)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties maintainer value Arduino <info@arduino.cc> starts with "Arduino". 3rd party libraries are
         not maintained by Arduino. (Rule LP027)
WARNING: library.properties maintainer value Arduino <info@arduino.cc> contains "Arduino". 3rd party libraries are not
         maintained by Arduino. (Rule LP057)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties name RGB LED TLC59731 contains spaces. Although supported, best practices is to not use
         spaces. (Rule LP015)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties version value 1.0 is not compliant with the semver specification. See https://semver.org/
         (Rule LP021)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties maintainer value Arduino <info@arduino.cc> starts with "Arduino". 3rd party libraries are
         not maintained by Arduino. (Rule LP027)
WARNING: library.properties maintainer value Arduino <info@arduino.cc> contains "Arduino". 3rd party libraries are not
         maintained by Arduino. (Rule LP057)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties version value 1.0 is not compliant with the semver specification. See https://semver.org/
         (Rule LP021)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: No header file found matching library name (Source_Wrapper.h). Best practices are for primary header filename
         to match library name. (Rule LS008)
WARNING: library.properties name Source Wrapper contains spaces. Although supported, best practices is to not use
         spaces. (Rule LP015)
ERROR: library.properties url value is less than minimum length. (Rule LP056)
ERROR: library.properties url field value  does not have a valid URL format. (Rule LP041)
WARNING: Unable to load the library.properties url field: Head "": unsupported protocol scheme "" (Rule LP042)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: library.properties version value 1.0 is not compliant with the semver specification. See https://semver.org/
         (Rule LP021)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
WARNING: No example sketches found. Please provide examples. See:
         https://arduino.github.io/arduino-cli/latest/library-specification/#library-examples (Rule LD004)

Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
Signed-off-by: Frederic Pillon <frederic.pillon@st.com>
STM32 core based on ST HAL automation moved this from In progress to Reviewer approved Jun 21, 2022
@fpistm fpistm merged commit 60e8deb into stm32duino:main Jun 21, 2022
STM32 core based on ST HAL automation moved this from Reviewer approved to Done Jun 21, 2022
@fpistm fpistm deleted the arduino-lint branch June 21, 2022 09:53
cparata pushed a commit to cparata/Arduino_Core_STM32 that referenced this pull request Jan 31, 2023
By default `Keyboard` and `Mouse` libraries are skipped as they may require additional configuration steps

Related stm32duino#1743
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Development

Successfully merging this pull request may close these issues.

None yet

3 participants