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

Fix args type in docstring #2888

Merged
merged 3 commits into from
Dec 13, 2024
Merged

Conversation

Galaxy-Husky
Copy link
Contributor

Motivation

I've noticed that several args types in the docstring don't match the types in type hints.

Modification

Replace List[Dict] with List[List[Dict]]].

@lvhan028
Copy link
Collaborator

Hi, @Galaxy-Husky
Thanks for your contribution
Please resolve the linting errors by

pip install pre-commit
cd lmdeploy # the root dir of lmdeploy repo
pre-commit install
pre-commit run --all-files

@Galaxy-Husky
Copy link
Contributor Author

pre-commit run --all-files

Hi, I've run into two problems.

  1. double-quote-string-fixer hook will modify another 6 files.
  2. Pre-commit raised an error:
Traceback (most recent call last):
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/bin/flake8", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/main/cli.py", line 22, in main
    app.run(argv)
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/main/application.py", line 375, in run
    self._run(argv)
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/main/application.py", line 363, in _run
    self.initialize(argv)
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/main/application.py", line 343, in initialize
    self.find_plugins(config_finder)
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/main/application.py", line 157, in find_plugins
    self.check_plugins = plugin_manager.Checkers(local_plugins.extension)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/plugins/manager.py", line 363, in __init__
    self.manager = PluginManager(
                   ^^^^^^^^^^^^^^
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/plugins/manager.py", line 243, in __init__
    self._load_entrypoint_plugins()
  File "/home/ping/.cache/pre-commit/repofprg0frh/py_env-python3.12/lib/python3.12/site-packages/flake8/plugins/manager.py", line 261, in _load_entrypoint_plugins
    eps = importlib_metadata.entry_points().get(self.namespace, ())
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
AttributeError: 'EntryPoints' object has no attribute 'get'

Could you tell me how to fix them?

@lvhan028
Copy link
Collaborator

I haven't met this issue.
The linting error shows that

lmdeploy/serve/async_engine.py:226:80: E501 line too long (82 > 79 characters)
lmdeploy/serve/async_engine.py:300:80: E501 line too long (82 > 79 characters)
lmdeploy/serve/async_engine.py:377:80: E501 line too long (82 > 79 characters)

Please make characters in each line is not greater than 79.
I pulled a request to your branch to fix it: Galaxy-Husky#1

@lvhan028 lvhan028 self-requested a review December 12, 2024 13:30
@Galaxy-Husky
Copy link
Contributor Author

@lvhan028
Hi,there is an OOM error in the check. I don't know if I could rerun the check.
Could you help me?

@lvhan028
Copy link
Collaborator

Don't worry. That's because the GPUs in the runner is occupied by others. This PR has nothing to do with it.

@lvhan028 lvhan028 merged commit 8f34eb1 into InternLM:main Dec 13, 2024
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants