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

Format code on master (black + isort) #538

Merged
merged 12 commits into from
Jun 13, 2022
Merged

Format code on master (black + isort) #538

merged 12 commits into from
Jun 13, 2022

Conversation

lihuoran
Copy link
Contributor

@lihuoran lihuoran commented May 31, 2022

Description

  • Guangbin
    • docs/
    • examples/
    • notebooks/
    • scripts/
    • tests/
    • setup.py/
  • He
    • maro/cli/
  • Jinyu & Huoran
    • maro/ (except rl and cli)

Linked issue(s)/Pull request(s)

Type of Change

  • Non-breaking bug fix
  • Breaking bug fix
  • New feature
  • Test
  • Doc update
  • Docker update

Related Component

  • Simulation toolkit
  • RL toolkit
  • Distributed toolkit

Has Been Tested

  • OS:
    • Windows
    • Mac OS
    • Linux
  • Python version:
    • 3.6
    • 3.7
  • Key information snapshot(s):

Needs Follow Up Actions

  • New release package
  • New docker image

Checklist

  • Add/update the related comments
  • Add/update the related tests
  • Add/update the related documentations
  • Update the dependent downstream modules usage

@codecov
Copy link

codecov bot commented May 31, 2022

Codecov Report

Merging #538 (842ae00) into master (17ad489) will increase coverage by 0.06%.
The diff coverage is 50.00%.

@@            Coverage Diff             @@
##           master     #538      +/-   ##
==========================================
+ Coverage   78.83%   78.90%   +0.06%     
==========================================
  Files          85       85              
  Lines        5463     5455       -8     
==========================================
- Hits         4307     4304       -3     
+ Misses       1156     1151       -5     
Flag Coverage Δ
unittests 78.90% <50.00%> (+0.06%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
maro/communication/dist_decorator.py 18.51% <ø> (ø)
maro/communication/driver/abs_driver.py 71.42% <0.00%> (ø)
maro/communication/driver/driver_type.py 100.00% <ø> (ø)
maro/communication/driver/zmq_driver.py 19.69% <ø> (ø)
maro/communication/message.py 67.39% <0.00%> (ø)
maro/communication/proxy.py 22.97% <0.00%> (ø)
maro/data_lib/cim/cim_data_container.py 99.32% <ø> (ø)
maro/data_lib/cim/cim_data_dump.py 100.00% <ø> (ø)
maro/data_lib/cim/entities.py 98.79% <0.00%> (ø)
maro/data_lib/cim/parsers.py 100.00% <ø> (ø)
... and 64 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 17ad489...842ae00. Read the comment docs.

maro/__init__.py Show resolved Hide resolved

cimport cython
Copy link
Collaborator

Choose a reason for hiding this comment

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

mark

maro/backends/_raw_backend_.pyx Show resolved Hide resolved
import numpy as np

from cpython cimport bool

Copy link
Collaborator

Choose a reason for hiding this comment

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

mark

@@ -51,8 +51,20 @@ def __init__(self, scenario: str, topology: str, source: str, is_temp: bool = Fa
self._data_root = StaticParameter.data_root
self._meta_folder = os.path.join(StaticParameter.data_root, scenario, "meta")
self._build_folder = os.path.join(self._data_root, self._scenario, ".build", self._topology)
self._clean_folder = os.path.join(self._data_root, self._scenario, ".source", ".clean", self._topology)
Copy link
Collaborator

Choose a reason for hiding this comment

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

mark

maro/communication/proxy.py Show resolved Hide resolved
scripts/code_gen.py Outdated Show resolved Hide resolved
maro/vector_env/env_process.py Outdated Show resolved Hide resolved
maro/simulator/scenarios/cim/common.py Outdated Show resolved Hide resolved
maro/simulator/scenarios/citi_bike/business_engine.py Outdated Show resolved Hide resolved
@Jinyu-W
Copy link
Collaborator

Jinyu-W commented Jun 13, 2022

Please add a detailed example for this part:

  • raw code v.s. formatted code if adding tailing comma manually
  • raw code v.s. formatted code if not adding tailing comma

@Jinyu-W
Copy link
Collaborator

Jinyu-W commented Jun 13, 2022

add command example (a single line):

pre-commit run --all-files

into this part

@Jinyu-W Jinyu-W merged commit 7e3c1d5 into master Jun 13, 2022
@Jinyu-W Jinyu-W deleted the black_format_master branch June 13, 2022 23:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants