Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
W
Wiki
Manage
Activity
Members
Labels
Plan
Issues
53
Issue boards
Milestones
Wiki
Code
Merge requests
6
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
MDM Lab
Wiki
Commits
97def49c
Commit
97def49c
authored
1 year ago
by
Remi PLANEL
Browse files
Options
Downloads
Patches
Plain Diff
fix: did not get all systems
parent
e2751eed
No related branches found
No related tags found
No related merge requests found
Pipeline
#120001
canceled with stages
in 3 minutes and 23 seconds
Changes
2
Pipelines
2
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
data/list-systems.json
+498
-9147
498 additions, 9147 deletions
data/list-systems.json
packages/df-wiki-cli/df_wiki_cli/content/main.py
+12
-13
12 additions, 13 deletions
packages/df-wiki-cli/df_wiki_cli/content/main.py
with
510 additions
and
9160 deletions
data/list-systems.json
+
498
−
9147
View file @
97def49c
This diff is collapsed.
Click to expand it.
packages/df-wiki-cli/df_wiki_cli/content/main.py
+
12
−
13
View file @
97def49c
...
@@ -185,10 +185,10 @@ def systems(
...
@@ -185,10 +185,10 @@ def systems(
with
open
(
file
)
as
f
:
with
open
(
file
)
as
f
:
metadata
,
_
=
frontmatter
.
parse
(
f
.
read
())
metadata
,
_
=
frontmatter
.
parse
(
f
.
read
())
del
metadata
[
"
layout
"
]
del
metadata
[
"
layout
"
]
sanitizedMetadata
=
{
**
metadata
}
if
"
tableColumns
"
in
metadata
:
if
"
tableColumns
"
in
metadata
:
table_data
=
metadata
[
"
tableColumns
"
]
table_data
=
metadata
[
"
tableColumns
"
]
if
"
PFAM
"
in
table_data
:
if
"
PFAM
"
in
table_data
:
# print(table_data["PFAM"])
pfams_list
=
[
pfams_list
=
[
pfam
.
strip
()
pfam
.
strip
()
for
pfam
in
table_data
[
"
PFAM
"
].
split
(
"
,
"
)
for
pfam
in
table_data
[
"
PFAM
"
].
split
(
"
,
"
)
...
@@ -210,19 +210,18 @@ def systems(
...
@@ -210,19 +210,18 @@ def systems(
style
=
"
red
"
,
style
=
"
red
"
,
)
)
continue
continue
del
metadata
[
"
tableColumns
"
]
if
"
article
"
in
table_data
:
metadata
[
"
doi
"
]
=
table_data
[
"
article
"
][
"
doi
"
]
if
"
abstract
"
in
table_data
[
"
article
"
]:
metadata
[
"
abstract
"
]
=
table_data
[
"
article
"
][
"
abstract
"
]
del
table_data
[
"
article
"
]
sanitizedMetadata
=
{
**
metadata
,
**
table_data
}
sanitizedMetadata
[
"
PFAM
"
]
=
pfam_metadata
sanitizedMetadata
[
"
PFAM
"
]
=
pfam_metadata
systems
.
append
(
sanitizedMetadata
)
if
"
article
"
in
table_data
:
metadata
[
"
doi
"
]
=
table_data
[
"
article
"
][
"
doi
"
]
if
"
abstract
"
in
table_data
[
"
article
"
]:
metadata
[
"
abstract
"
]
=
table_data
[
"
article
"
][
"
abstract
"
]
del
table_data
[
"
article
"
]
del
metadata
[
"
tableColumns
"
]
sanitizedMetadata
=
{
**
metadata
,
**
table_data
}
systems
.
append
(
sanitizedMetadata
)
json_object
=
json
.
dumps
(
systems
,
indent
=
2
)
json_object
=
json
.
dumps
(
systems
,
indent
=
2
)
ty
.
write
(
json_object
)
ty
.
write
(
json_object
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment