Closed teamhide closed 4 years ago
Merging #17 into master will not change coverage. The diff coverage is
100.00%
.
@@ Coverage Diff @@
## master #17 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 2 2
Lines 60 61 +1
=========================================
+ Hits 60 61 +1
Impacted Files | Coverage Δ | |
---|---|---|
fastapi_sqlalchemy/middleware.py | 100.00% <100.00%> (ø) |
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 b46b9e6...4df5289. Read the comment docs.
Thanks for the PR. I don't use Pycharm myself. Happy to resolve this problem. Could I ask you to try one alternative and tell me if this fixes it? Instead of adding self.session = None
, what happens if you change line 82 of middleware.py from db: DBSession = DBSession
to db: DBSessionMeta = DBSession
? Does that fix it or not?
Works perfectly. I will re-pr for this issue.
While using db.session on pycharm, it notify
Unresolved attribute reference 'session' for class 'DBSession'
errors.To avoid it, added
self.session
to DBSession.