Skip to content

Cannot edit/remove subproject when duplicate subprojects are defined. #6369

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
Aricg opened this issue Nov 12, 2019 · 9 comments
Closed

Cannot edit/remove subproject when duplicate subprojects are defined. #6369

Aricg opened this issue Nov 12, 2019 · 9 comments
Assignees
Labels
Support Support question

Comments

@Aricg
Copy link

Aricg commented Nov 12, 2019

Details

sub-project relationship created with v3 api.
Cannot remove subproject when duplicate subprojects are defined.
https://readthedocs.org/dashboard/o-ran-sc-doc/subprojects/o-ran-sc-ric-app-mc/edit/

returns:

          .
         ":"
       ___:____     |"\/"|
     ,'        `.    \  /
     |  O        \___/  |
   ~^~^~^~^~^~^~^~^~^~^~^~^~

Fail. Check back in a bit!

Expected Result

If a subproject listing already exists, refuse to create it a second time.
If duplicates do exist, allow user to remove them.

Actual Result

Subproject listing is duplicated many times https://imgur.com/a/BgYClJa

Note

The docs are now setup with a domain, docs.o-ran-sc.org and that may effect this. unsure.

My code actually checks if the subproject relationship exists, and tries to do the right thing.
So not sure how this happend.

Here is the code with the subproject check before subproject creation.
https://gist.github.com/Aricg/95812e76e8611a16ffde5c3f490813e2

@Aricg
Copy link
Author

Aricg commented Nov 12, 2019

Found a failure on our side that I believe led to the multiple sub-project relationship creations

https://jenkins.o-ran-sc.org/view/rtdv3-global/job/rtdv3-global-merge-master/230/console
Afaik this worked before, investigating our api implementation.

@humitos humitos added Accepted Accepted issue on our roadmap Bug A bug labels Nov 12, 2019
@humitos humitos self-assigned this Nov 12, 2019
@Aricg
Copy link
Author

Aricg commented Nov 12, 2019

18:14:59   File "/home/jenkins/.local/lib/python3.6/site-packages/lftools/api/endpoints/readthedocs.py", line 244, in subproject_list
18:14:59     subproject_list.append(subproject['child']['slug'])
18:14:59 TypeError: list indices must be integers or slices, not str

Looking into our implementation now.

@ghost
Copy link

ghost commented Nov 12, 2019

Reviewed this and confirmed Aricg's findings

@stsewd
Copy link
Member

stsewd commented Nov 12, 2019

This was already fixed in #6275, but the fix isn't deployed yet

@stsewd
Copy link
Member

stsewd commented Nov 12, 2019

@Aricg I'll need to delete the duplicate subproject relatioship manually for you. Which one is it?

@stsewd stsewd added Support Support question and removed Accepted Accepted issue on our roadmap Bug A bug labels Nov 12, 2019
@humitos
Copy link
Member

humitos commented Nov 12, 2019

I just tested this and I think the fix just deployed worked. Please, let us know if it's still there. Thanks!

@Aricg
Copy link
Author

Aricg commented Nov 12, 2019

@stsewd There are several listed here https://readthedocs.org/projects/o-ran-sc-doc/

@Aricg
Copy link
Author

Aricg commented Nov 12, 2019

$ cat /tmp/foo | sort | uniq -c
1 o-ran-sc-ci-management
2 o-ran-sc-it-dev
3 o-ran-sc-it-otf
1 o-ran-sc-it-test
2 o-ran-sc-nonrtric
1 o-ran-sc-portal-ric-dashboard
1 o-ran-sc-pti-rtp
1 o-ran-sc-ric-app-admin
6 o-ran-sc-ric-app-mc
1 o-ran-sc-ric-app-ml
1 o-ran-sc-ric-plt-a1
1 o-ran-sc-ric-plt-lib-rmr
2 o-ran-sc-scp-ocu-openlte

@stsewd
Copy link
Member

stsewd commented Nov 12, 2019

@Aricg ok, I think I have deleted all duplicated subprojects. Let me know if I missed one

@stsewd stsewd closed this as completed Nov 12, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Support Support question
Projects
None yet
Development

No branches or pull requests

3 participants