Skip to content
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

style: apply pre-commit hooks #418

Merged
merged 1 commit into from
Sep 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 12 additions & 12 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
version: 2
updates:
- package-ecosystem: github-actions
directory: /
schedule:
interval: monthly
- package-ecosystem: pip
directory: /
schedule:
interval: monthly
- package-ecosystem: docker
directory: /
schedule:
interval: monthly
- package-ecosystem: github-actions
directory: /
schedule:
interval: monthly
- package-ecosystem: pip
directory: /
schedule:
interval: monthly
- package-ecosystem: docker
directory: /
schedule:
interval: monthly
52 changes: 26 additions & 26 deletions fuji_server/data/ResourceTypes.txt
Original file line number Diff line number Diff line change
@@ -1,46 +1,37 @@
Audiovisual
Collection
DataPaper
Dataset
Event
Image
InteractiveResource
Model
PhysicalObject
Service
Software
Sound
Text
Workflow
MovingImage
Service
Software
StillImage
CreativeWork
AmpStory
ArchiveComponent
Article
Atlas
Audiovisual
BioChemEntity
BioSample
Blog
Book
Chapter
ChemicalSubstance
Claim
Clip
Collection
ComicStory
Comment
Conversation
Course
CreativeWork
CreativeWorkSeason
CreativeWorkSeries
DataCatalog
DataPaper
Dataset
DefinedTermSet
Diet
DigitalDocument
Drawing
EducationalOccupationalCredential
Episode
Event
ExercisePlan
Game
Gene
Guide
HowTo
HowToDirection
Expand All @@ -49,6 +40,8 @@ HowToStep
HowToTip
HyperToc
HyperTocEntry
Image
InteractiveResource
LearningResource
Legislation
Manuscript
Expand All @@ -58,36 +51,43 @@ MediaObject
Menu
MenuSection
Message
Model
MolecularEntity
Movie
MovingImage
MusicComposition
MusicPlaylist
MusicRecording
Painting
Photograph
PhysicalObject
Play
Poster
Protein
PublicationIssue
PublicationVolume
Quotation
Review
Sculpture
Service
Service
SheetMusic
ShortStory
Software
Software
SoftwareApplication
SoftwareSourceCode
Sound
SpecialAnnouncement
StillImage
TVSeason
TVSeries
Taxon
Text
Thesis
VisualArtwork
WebContent
WebPage
WebPageElement
WebSite
BioChemEntity
BioSample
ChemicalSubstance
Gene
MolecularEntity
Protein
Taxon
Workflow
2 changes: 1 addition & 1 deletion fuji_server/data/bioschemastypes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,4 @@ SequenceRange
Study
Taxon
TaxonName
TrainingMaterial
TrainingMaterial
114 changes: 57 additions & 57 deletions fuji_server/data/creativeworktypes.txt
Original file line number Diff line number Diff line change
@@ -1,27 +1,43 @@
3DModel
AdvertiserContentArticle
AmpStory
Answer
ArchiveComponent
Article
Atlas
AudioObject
Audiobook
Blog
Book
BookSeries
Chapter
Claim
ClaimReview
Clip
Collection
ComicCoverArt
ComicStory
Comment
Conversation
CorrectionComment
Course
Course
CreativeWork
CreativeWorkSeason
CreativeWorkSeries
CriticReview
DataCatalog
DataDownload
DataFeed
Dataset
DefinedTermSet
DefinedTermSet
Diet
DigitalDocument
Drawing
EducationalOccupationalCredential
EmailMessage
EmployerReview
Episode
ExercisePlan
Game
Expand All @@ -33,97 +49,81 @@ HowToStep
HowToTip
HyperToc
HyperTocEntry
ImageObject
LearningResource
Legislation
LegislationObject
LegislationObject
Manuscript
Map
MathSolver
MediaObject
MediaReview
MediaReviewItem
Menu
MenuSection
Message
Movie
MovieClip
MovieSeries
MusicAlbum
MusicComposition
MusicPlaylist
MusicRecording
MusicRelease
MusicVideoObject
NewsArticle
NoteDigitalDocument
Painting
Periodical
Photograph
Play
PodcastEpisode
PodcastSeason
PodcastSeries
Poster
PresentationDigitalDocument
ProductCollection
PublicationIssue
PublicationVolume
Question
Quiz
Quotation
RadioClip
RadioEpisode
RadioSeason
RadioSeries
Recipe
Recommendation
Report
Review
SatiricalArticle
ScholarlyArticle
Sculpture
SheetMusic
ShortStory
SocialMediaPosting
SoftwareApplication
SoftwareSourceCode
SpecialAnnouncement
SpreadsheetDigitalDocument
Statement
TVClip
TVEpisode
TVSeason
TVSeason
TVSeries
TVSeries
TechArticle
TextDigitalDocument
Thesis
UserReview
VideoGame
VideoGameClip
VideoGameSeries
VideoObject
VisualArtwork
WebContent
WebPage
WebPageElement
WebSite
AdvertiserContentArticle
NewsArticle
Report
SatiricalArticle
ScholarlyArticle
SocialMediaPosting
TechArticle
Audiobook
MovieClip
RadioClip
TVClip
VideoGameClip
ProductCollection
ComicCoverArt
Answer
CorrectionComment
Question
PodcastSeason
RadioSeason
TVSeason
BookSeries
MovieSeries
Periodical
PodcastSeries
RadioSeries
TVSeries
VideoGameSeries
DataFeed
NoteDigitalDocument
PresentationDigitalDocument
SpreadsheetDigitalDocument
TextDigitalDocument
PodcastEpisode
RadioEpisode
TVEpisode
VideoGame
Recipe
Course
Quiz
LegislationObject
3DModel
AudioObject
DataDownload
ImageObject
LegislationObject
MusicVideoObject
VideoObject
EmailMessage
MusicAlbum
MusicRelease
ClaimReview
CriticReview
EmployerReview
MediaReview
Recommendation
UserReview
DefinedTermSet
34 changes: 17 additions & 17 deletions fuji_server/data/default_namespaces.txt
Original file line number Diff line number Diff line change
@@ -1,25 +1,25 @@
http://ogp.me/ns#
http://purl.org/dc/elements/1.1/
http://purl.org/dc/terms/
http://schema.org/
http://www.w3.org/1999/02/22-rdf-syntax-ns#
http://www.w3.org/1999/XSL/Transform
http://www.w3.org/1999/xhtml/vocab
http://www.w3.org/2000/01/rdf-schema#
http://www.w3.org/ns/rdfa
http://www.w3.org/2002/07/owl#
http://www.w3.org/2000/xmlns
http://www.w3.org/2001/XMLSchema#
http://www.w3.org/2001/XMLSchema-instance
http://www.w3.org/2002/07/owl#
http://www.w3.org/2004/02/skos/core#
http://www.w3.org/XML/1998/namespace
http://www.w3.org/2004/07/xpath-functions
http://www.w3.org/XSL/Transform/1.0
http://www.w3.org/1999/XSL/Transform
http://www.w3.org/TR/WD-xsl
http://www.w3.org/2006/vcard/ns#
http://www.w3.org/2001/XMLSchema-instance
http://www.w3.org/2000/xmlns
http://xmlns.com/foaf/0.1/
http://purl.org/dc/elements/1.1/
http://purl.org/dc/terms/
http://www.w3.org/2005/sparql-results#
http://www.w3.org/2005/xqt-errors#
http://www.w3.org/2005/xpath-functions#
http://schema.org/
https://schema.org/
http://ogp.me/ns#
http://www.w3.org/1999/xhtml/vocab
http://www.w3.org/2005/xqt-errors#
http://www.w3.org/2006/vcard/ns#
http://www.w3.org/2007/05/powder-s#
http://www.w3.org/TR/WD-xsl
http://www.w3.org/XML/1998/namespace
http://www.w3.org/XSL/Transform/1.0
http://www.w3.org/ns/rdfa
http://xmlns.com/foaf/0.1/
https://schema.org/
6 changes: 3 additions & 3 deletions fuji_server/helper/linked_vocab_helper.py
Original file line number Diff line number Diff line change
Expand Up @@ -144,9 +144,9 @@ def get_linked_vocab_by_iri(self, IRI, isnamespaceIRI=False, firstonly=True):
if reg_res.get("regex"):
comb_regex = reg_res.get("regex").lstrip("^").rstrip("$")
else:
if '?' in reg_res.get('pattern'):
reg_res['pattern']=reg_res.get('pattern').replace('?',r'\?')
comb_regex = reg_res.get('pattern').split('$1')[0].rstrip('/#')
if "?" in reg_res.get("pattern"):
reg_res["pattern"] = reg_res.get("pattern").replace("?", r"\?")
comb_regex = reg_res.get("pattern").split("$1")[0].rstrip("/#")

if comb_regex not in tested_patterns:
tested_patterns.append(comb_regex)
Expand Down