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

Tests for Color UI and Robin Nano Boards (and fixes) #19118

Merged

Conversation

rhapsodyv
Copy link
Member

Description

Some recent menu changes broke the compilation for New Color UI. I noted that it have no tests.

Benefits

Add test for new color ui.

Related Issues

@rhapsodyv
Copy link
Member Author

rhapsodyv commented Aug 23, 2020

@ivankravets seems pio dev is broken....

ImportError: cannot import name 'cd' from 'platformio.util' (/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/util.py):

Take a look in the failing tests.

@ivankravets
Copy link
Contributor

This is a legacy Core 3.x API. Please use from platformio.fs import cd.

@ivankravets
Copy link
Contributor

Should revert back this 3.x API and add warning? We just wanted to clean up a code.

@rhapsodyv
Copy link
Member Author

Should revert back this 3.x API and add warning? We just wanted to clean up a code.

Is not our scripts. Is the esp32 framework package

  File "/home/runner/.platformio/platforms/espressif32/builder/frameworks/_embed_files.py", line 21:
74
    from platformio.util import cd

Seems there’re packages that use some legacy code, and they aren’t migrated yet.

@ivankravets
Copy link
Contributor

Sorry for these issues. We don't do a major refactoring of our codebase so often. 1 time per a few years. This time it has happened with refactoring our package management infrastructure. Maybe, it makes sense to release it as PIO Core 5.0. However, we don't see a reason in PIO Core 5.0 if all user projects are compatible with PIO Core 4.4 changes.

@rhapsodyv thanks for your report. It is an outdated version of ESP32 dev platform. I've just back ported util.cd API.

@thinkyhead "PIO-dev unsuitable for CI", why it is unsuitable? Is it better if we fix all known issues before the final releases of both projects? How about if we switch back to "develop" branch after PIO Core 4.4 release? We plan to have it on Tuesday. We don't have any significant changes in PIO Core in our roadmap for the next months.

Thanks!

@rhapsodyv
Copy link
Member Author

@thinkyhead we need release 2.0.6.1 with #19034 before Tuesday. If we don't, any build using the upcoming pio will be broken. 🙁

@ivankravets
Copy link
Contributor

Do you have any blockers for 2.0.6.1? Indeed, we can wait in this case.

@rhapsodyv
Copy link
Member Author

rhapsodyv commented Aug 23, 2020

@ivankravets I think we have more issues:

2020-08-23.3240891Z �[0;32m[Test esp32] �[0mESP32 with WIFISUPPORT and WEBSUPPORT...
AttributeError: module 'platformio.exception' has no attribute 'InternetIsOffline':
  File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/builder/main.py", line 169:
    env.SConscript("$BUILD_SCRIPT")
  File "/home/runner/.platformio/packages/tool-scons/scons-local-4.0.1/SCons/Script/SConscript.py", line 598:
    return _SConscript(self.fs, *files, **subst_kw)
  File "/home/runner/.platformio/packages/tool-scons/scons-local-4.0.1/SCons/Script/SConscript.py", line 287:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "/home/runner/.platformio/platforms/espressif32/builder/main.py", line 210:
    target_elf = env.BuildProgram()
  File "/home/runner/.platformio/packages/tool-scons/scons-local-4.0.1/SCons/Environment.py", line 219:
    return self.method(*nargs, **kwargs)
  File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/builder/tools/platformio.py", line 62:
    env.ProcessProjectDeps()
  File "/home/runner/.platformio/packages/tool-scons/scons-local-4.0.1/SCons/Environment.py", line 219:
    return self.method(*nargs, **kwargs)
  File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/builder/tools/platformio.py", line 140:
    project_lib_builder = env.ConfigureProjectLibBuilder()
  File "/home/runner/.platformio/packages/tool-scons/scons-local-4.0.1/SCons/Environment.py", line 219:
    return self.method(*nargs, **kwargs)
  File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/builder/tools/piolib.py", line 1047:
    project.install_dependencies()
  File "/opt/hostedtoolcache/Python/3.7.8/x64/lib/python3.7/site-packages/platformio/builder/tools/piolib.py", line 885:
    except (UnknownPackageError, exception.InternetIsOffline) as e:

@rhapsodyv
Copy link
Member Author

AttributeError: module 'platformio.exception' has no attribute 'InternetIsOffline':

@ivankravets
Copy link
Contributor

@rhapsodyv thanks for the report! Fixed in platformio/platformio-core@24f85a3

P.S: It was a typo with excluding "no-member" from PyLint.

@asasin6666
Copy link

asasin6666 commented Aug 23, 2020 via email

@asasin6666
Copy link

asasin6666 commented Aug 23, 2020 via email

@thinkyhead
Copy link
Member

why it is unsuitable?

I find it frustrating to have to stop at random times to deal with a morphing PlatformIO when there are so many notifications and pull requests piling up. To avoid these interruptions I would prefer to stick with a known working version of PlatformIO until the kinks are worked out.

If the build of Marlin is helpful for catching errors in PlatformIO, perhaps we can set up a copy of Marlin under a different GitHub account, have it re-build itself each time there's a new push to PlatformIO, and then have it ping you if there's a build failure of any kind.

Do you have any blockers for 2.0.6.1? Indeed, we can wait in this case.

Before tagging 2.0.6.1 I had hoped to find and fix:

  • A reported freeze caused by long filenames and some LCD screens; probably a buffer overflow.
  • A confirmed freeze that occurs with gradient mixing.

But so far I haven't been able to narrow down the cause of either of these issues.

@ivankravets
Copy link
Contributor

@thinkyhead thanks for the honest feedback! I think I asked to switch to PIO dev-version at the wrong moment. However, you are right. You have tons of own issues and it does not make sense to spent time on our issues.

So, should we postpone 4.4 release? We want to do this tomorrow becase there huge update of PlatformIO IDE 2.0 for VSCode. It depends on PlatformIO Core 4.4. It might be useful for Marlin project as well. It bring support for custom targets and IDE automatically provides UI for them.

@thinkyhead
Copy link
Member

So, should we postpone 4.4 release? We want to do this tomorrow becase there huge update…

I don't want anything to hold up your schedule, and Marlin needs to be adaptable. If you feel confident you've got all the breaking issued solved, I defer to your judgment. I've been using the 4.4 alpha / beta for a while and the most important thing is that it builds the project just fine and we don't need to make any changes to platformio.ini for compatibility. Plus, it will be stabilized, in contrast to the mercurial develop branch.

It bring support for custom targets and … UI for them.

That's good news! I look forward to seeing it in action.

I believe that, now, if an environment uses extends it still needs to include platform or it won't be respected. Has that been changed?

@thinkyhead thinkyhead merged commit f7fe499 into MarlinFirmware:bugfix-2.0.x Aug 24, 2020
@ivankravets
Copy link
Contributor

I believe that, now, if an environment uses extends it still needs to include platform or it won't be respected. Has that been changed?

This also has been fixed. We rewrote INI parser in Node.JS.

@rhapsodyv
Copy link
Member Author

@thinkyhead @ivankravets CI using PIO dev is broken again. 🥳 😅

Error: Development platform 'nxplpc-arduino-lpc176x' is not compatible with PlatformIO Core v5.0.0-b.1 and depends on PlatformIO Core ^4.0.0.

Maybe @p3p need to do some adjustment?

@p3p
Copy link
Member

p3p commented Aug 25, 2020

No idea, I will need to look up all the major changes that required the platformio major version bump and make sure every thing is compatible before doing a release with the platformio version requirement updated.

If the only breaking changes are the manifest file deprecation then it will be an easy update, I will just have to get used to publishing packages ^^.

@rhapsodyv
Copy link
Member Author

@ivankravets Is there any way to lock users in a specific pio version?

@ivankravets
Copy link
Contributor

We have decided to release everything under 5.0. A lot of changes... So, it should close any questions about why we modified our internal package structure, and etc.

In any case, all projects and dev-platforms are compatible between 1.0 and 5.0.

5.0.0-beta.2 is out. I hope this is the last issue. We know automatically mark all PIO Core 1.0-4.0 dev-platforms compatible with 5.0. See platformio/platformio-core@0db39cc

P.S: Thanks for pinging to me!

albertogg pushed a commit to albertogg/Marlin that referenced this pull request Aug 31, 2020
thinkyhead pushed a commit to thinkyhead/Marlin that referenced this pull request Sep 2, 2020
@rhapsodyv rhapsodyv deleted the color-ui-test-robin-nano branch October 25, 2020 00:32
vgadreau pushed a commit to vgadreau/Marlin that referenced this pull request Dec 9, 2020
kageurufu pushed a commit to CR30-Users/Marlin-CR30 that referenced this pull request Apr 30, 2021
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.

5 participants