Is there any known issue with removing parameters ...
# prefect-community
j
Is there any known issue with removing parameters from a Flow and Prefect Cloud still showing the removed Parameter?
k
Like you removed the
Parameter
part of the code and re-registered and it still shows? Did you re-register?
j
Correct. I re-registered it, and also did a register with --force. The param didn't go away until I deleted the flow entirely and then deployed fresh
k
This sounds off. I think it might be like that if you set it from the UI?
j
I'm not sure if I set it from the UI or not. it had a default so I don't think I did, but I might have
Hey @Kevin Kho, I found a way of showing this issue. I have a flow where I removed the parameter "pgp_keyring_path". You can see in the image of the flow run schematic that parameter is not showing
But in the Parameters page in Settings, it does show up.
It also shows up in the Parameters section of the Flow Run details
k
Could you do one quick check for me and make sure the versions of the Flow are aligned so you’re looking at the latest one?
j
Yep, i made sure to switch the latest version in the drop down because I had the same thought
I'll triple check though
Yep, it is the latest version
k
Thank you, will try to replicate then make an issue
I actually could not replicate. I made a flow like this:
Copy code
from prefect import Flow, task, Parameter

@task
def abc(x, y):
    return 1

with Flow("parameter-test") as flow:
    x = Parameter("x", 2)
    y = Parameter("y", 2)
    abc(x,y)
registered it and ran it. I then re-registered without
y
and the UI seems to show things properly. Do you have any advice how to reproduce?
j
The only thing off the top of my head is that my scaffolding script adds the Parameters with the add_task method. I don't feel like that would make a difference but 🤷‍♀️