ray icon indicating copy to clipboard operation
ray copied to clipboard

[RLlib] Replace ordinary pygame imports by try_imports

Open ArturNiederfahrenhorst opened this issue 2 years ago • 0 comments

Signed-off-by: Artur Niederfahrenhorst [email protected]

Why are these changes needed?

Replaces imports of pygame with try_imports, akin to the ones we use for frameworks. This helps us output a more informative import error.

Related issue number

https://github.com/ray-project/ray/issues/31321

Checks

  • [x] I've signed off every commit(by using the -s flag, i.e., git commit -s) in this PR.
  • [x] I've run scripts/format.sh to lint the changes in this PR.
  • [ ] I've included any doc changes needed for https://docs.ray.io/en/master/.
  • [ ] I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • [x] Unit tests
    • [ ] Release tests
    • [ ] This PR is not tested :(

ArturNiederfahrenhorst avatar Dec 27 '22 20:12 ArturNiederfahrenhorst