Skip to content
This repository was archived by the owner on Jun 4, 2023. It is now read-only.

Commit b3c6c43

Browse files
authored
Merge pull request #240 from bnavigator/fix-ci2
Fix CI Fix and support decorated classmethod/staticmethod in Python 3.10
2 parents b303f7e + 41245bd commit b3c6c43

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

.github/workflows/main-ci.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ jobs:
2323

2424
steps:
2525
- name: Checkout source
26-
- uses: actions/checkout@v2
26+
uses: actions/checkout@v2
2727
- name: Set up Python
2828
uses: actions/setup-python@v2
29-
with:
30-
python-version: ${{ matrix.python-version }}
29+
with:
30+
python-version: ${{ matrix.python-version }}
3131
- name: Install dependencies
3232
run: |
3333
python -m pip install --upgrade pip

src/Pyro4/core.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -987,7 +987,7 @@ def expose(method_or_class):
987987
func._pyroExposed = True
988988
return method_or_class
989989
attrname = getattr(method_or_class, "__name__", None)
990-
if not attrname:
990+
if not attrname or isinstance(method_or_class, (classmethod, staticmethod)):
991991
# we could be dealing with a descriptor (classmethod/staticmethod), this means the order of the decorators is wrong
992992
if inspect.ismethoddescriptor(method_or_class):
993993
attrname = method_or_class.__get__(None, dict).__name__

0 commit comments

Comments
 (0)