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

Make autoimport cache generation non-blocking #499

Merged
Prev Previous commit
address comments
  • Loading branch information
tkrabel committed Dec 22, 2023
commit 4af136ced3c3d666f5d831b574db20c070680ee8
5 changes: 2 additions & 3 deletions pylsp/_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,9 @@
import pathlib
import re
import threading
import time
from typing import List, Optional

import time
from functools import wraps
import docstring_to_markdown
import jedi

Expand Down Expand Up @@ -61,7 +60,7 @@ def throttle(seconds=1):
"""Throttles calls to a function evey `seconds` seconds."""

def decorator(func):
@wraps(func)
@functools.wraps(func)
def wrapper(*args, **kwargs): # pylint: disable=inconsistent-return-statements
if not hasattr(wrapper, "last_call"):
wrapper.last_call = 0
Expand Down
Loading