Skip to content

Fixes #52 - #119

Merged
andriumon merged 1 commit into
oeg-upm:mainfrom
louvetv:selfhosted-gitlab
Jul 15, 2026
Merged

andriumon merged 1 commit into
oeg-upm:mainfrom
louvetv:selfhosted-gitlab

Conversation

@louvetv

@louvetv louvetv commented Jul 13, 2026 •

Copy link
Copy Markdown
Contributor

Problem

RSFC only worked with github.com and gitlab.com. Repositories on self-hosted GitLab instances (e.g. plmlab.math.cnrs.fr, forge.inrae.fr, gitlab.in2p3.fr) failed in several ways.

Changes

src/rsfc/harvesters/github_harvester.py

  • Add detect_repo_type() and _is_gitlab_instance(): host-based detection that recognises self-hosted GitLab.
  • Build the GitLab API base URL from the repo's actual host instead of hardcoding gitlab.com, fix some related issues.

src/rsfc/rsfc_checks/rsfc_checks.py

  • uses detect_repo_type() instead of a hardcoded github.com/gitlab.com substring check.

src/rsfc/utils/rsfc_helpers.py

  • uses detect_repo_type(), fix some issues.

Testing

Verified end-to-end on gitlab.in2p3.fr, forge.inrae.fr and plmlab.math.cnrs.fr.
Regression tests completed.

Known limitation

Repositories behind bot-protection proxies (e.g. Anubis) cannot be assessed, since the challenge is enforced upstream of GitLab and is not bypassed by an API token.

@louvetv louvetv mentioned this pull request Jul 13, 2026
@dgarijo
dgarijo requested a review from andriumon July 13, 2026 13:43
@dgarijo

dgarijo commented Jul 13, 2026

Copy link
Copy Markdown
Member

in theory newest versions of somef do support self hosted gitlab instances. Please @andriumon review and merge this pr.

@andriumon

Copy link
Copy Markdown
Collaborator

Thanks for the contribution! Everything seems fine by my side. Merging it

@andriumon andriumon closed this Jul 15, 2026
@andriumon andriumon reopened this Jul 15, 2026
@andriumon
andriumon merged commit 93ebfb1 into oeg-upm:main Jul 15, 2026
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants