incalculable-dawn-43014
05/24/2023, 8:38 AMmetaflow==2.9.1 with VSCode and pylint enabled.
The from metaflow import card statement shows the pylint error No name 'card' in module 'metaflow' . The flow actually runs fine.
Does anybody have any help for that? All other metaflow import are fine, for example:
from metaflow import FlowSpec, IncludeFile, Parameter, step
Thanks in advance! 🙂incalculable-dawn-43014
05/25/2023, 8:37 AMcurrent has no card member.
Example Code:
"""Example module importing and using cards."""
from metaflow import FlowSpec, step, current
from metaflow import card
from metaflow.cards import Markdown
class CardSpec(FlowSpec):
"""Example spec."""
@card
@step
def start(self):
""" Start."""
current.card.append(Markdown("# Test"))
self.next(self.end)
@step
def end(self):
"""End."""
print("HelloFlow is all done.")
if __name__ == "__main__":
CardSpec()
and if I run pylint on this I get two errors:
pylint cards_example.py
************* Module cards_example
cards_example.py:4:0: E0611: No name 'card' in module 'metaflow' (no-name-in-module)
cards_example.py:13:8: E1101: Instance of 'Current' has no 'card' member (no-member)
------------------------------------------------------------------
Your code has been rated at 0.91/10 (previous run: 0.91/10, +0.00)