For some reason, the artifacts create_markdown is ...
# prefect-community
t
For some reason, the artifacts create_markdown is rendering the markdown, but it is ignoring the images. Has anyone had this issue?
1️⃣ 2
1
b
Hi Tomas, thanks for reaching out. Can you share a minimal reproducible example of your code so we can try to replicate this? Also, what version of prefect are you using?
t
of course
file temp.md
Copy code
# Precision Recall Curve

## Testing

<img src="<https://revtron-ml.s3.amazonaws.com/precision_recall_curve.png>">
then to call it
Copy code
with open('temp.md', 'r') as f:
	md = f.read()

    # testing artifacts
    md_id = create_markdown_artifact(md)
The first two lines of the readme.md show up fine, it is the image that is no showing in the UI.
b
Ahh, the issue is the syntax for how the image is referenced. You need to use GitHub flavored markdown. Here is an example that works:
Here is the temp.md:
Copy code
# Precision Recall Curve

## Testing

![foo](<https://revtron-ml.s3.amazonaws.com/precision_recall_curve.png>)
here is my flow:
Copy code
from prefect import task, Flow
from prefect.backend.artifacts import create_markdown_artifact

@task
def read_file():
    with open('temp.md', 'r') as f:
	    return(f.read())

@task
def make_artifact(file):
    create_markdown_artifact(file)


with Flow(name = "artifact-creation") as flow:
    artifact_file = read_file()
    make_artifact(artifact_file)
🙏 1
t
OOhh i see , i really appreciate your help
thank you