incubator-devlake icon indicating copy to clipboard operation
incubator-devlake copied to clipboard

[Bug][Projects] Cannot read properties of null (reading 'id')

Open dwaghulade opened this issue 1 year ago • 2 comments

Search before asking

  • [X] I had searched in the issues and found no similar issues.

What happened

Project created intially without any data connection is showing in the project list and would like to dlete it however when click on project or setting icon getting error message as "Cannot read properties of null (reading 'id')"

image

What do you expect to happen

Should able to open setting for project so that it can be deleted.

How to reproduce

Issue in highlighted project

image

Anything else

No response

Version

v1.0.0-beta6

Are you willing to submit PR?

  • [ ] Yes I am willing to submit a PR!

Code of Conduct

dwaghulade avatar May 06 '24 18:05 dwaghulade

How did you create the project, by API or Config UI?

Startrekzky avatar May 07 '24 03:05 Startrekzky

Hi everyone.

Faced with the same issue. Project created via Config UI

Also noticed, for that new project there is no Blueprint created. And in database tables ‘_devlake_blueprint*’ there are rows filled with ’null’.

Screenshot 2024-05-09 at 19 29 03 Screenshot 2024-05-09 at 19 29 24

ArtRout1313 avatar May 09 '24 17:05 ArtRout1313

Config UI

Project created with Config UI

dwaghulade avatar May 10 '24 22:05 dwaghulade

Upgraded to v1.0.0-beta8 however issue still persist.

dwaghulade avatar May 20 '24 22:05 dwaghulade

Hi @dwaghulade, I'm so sorry for this issue, but existing data cannot be modified, please create a new project.

mintsweet avatar May 21 '24 03:05 mintsweet

@dwaghulade The fix can only prevent the problem for the new projects onward

klesh avatar May 21 '24 03:05 klesh

Thanks @mintsweet & @klesh for the clarification.

Any way to clean-up existing projects as those are unnecessary being displayed in the list.

dwaghulade avatar May 21 '24 04:05 dwaghulade

@dwaghulade try deleting the project from the database.

klesh avatar May 21 '24 04:05 klesh

@klesh I was avoiding to use direct DB deletion approach because of any dependencies impact. Do you have list of tables from where I need to delete entries to make sure all related data as well deleted for these projects?

dwaghulade avatar May 21 '24 04:05 dwaghulade

@dwaghulade I assumed that the problematic project has never been actually used, correct? you may delete it from the projects table if so.

klesh avatar May 21 '24 04:05 klesh

Thanks @klesh for your help. I have removed entries from projects tables which has cleared unwanted projects from the list on UI.

dwaghulade avatar May 21 '24 04:05 dwaghulade

Glad to know, close the issue now

klesh avatar May 24 '24 07:05 klesh