Skip to content

Commit b33593e

Browse files
committed
Merge branch 'develop' into feature/9691-osfmetrics-migration
2 parents dce545d + 3f36856 commit b33593e

217 files changed

Lines changed: 5986 additions & 6759 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/actions/gen-report/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,12 @@ runs:
44
using: "composite"
55
steps:
66
- name: Archive code coverage results
7-
uses: actions/upload-artifact@v4
7+
uses: actions/upload-artifact@v7
88
with:
99
name: ${{github.job}} HTML REPORT
1010
path: report.html
1111
- name: Generate Report
12-
uses: dorny/test-reporter@v2
12+
uses: dorny/test-reporter@v3
1313
if: success() || failure() # run this step even if previous step failed
1414
with:
1515
name: ${{github.job}} REPORT # Name of the check run which will be created

.github/actions/start-build/action.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ runs:
44
using: "composite"
55
steps:
66
- id: cache-objects
7-
uses: actions/cache@v4
7+
uses: actions/cache@v5
88
with:
99
path: ~/.cache
1010
key: reqs_${{ hashFiles('poetry.lock') }}
@@ -16,7 +16,7 @@ runs:
1616
with:
1717
ELASTICSEARCH6_ARCHIVE: ${{ env.ELASTICSEARCH6_ARCHIVE }}
1818
- name: Set up Python 3.12
19-
uses: actions/setup-python@v5
19+
uses: actions/setup-python@v6
2020
with:
2121
python-version: '3.12'
2222
- name: Install lxml

.github/workflows/test-build.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ jobs:
1717
build-cache:
1818
runs-on: ubuntu-22.04
1919
steps:
20-
- uses: actions/checkout@v2
20+
- uses: actions/checkout@v6
2121
- id: cache-objects
22-
uses: actions/cache@v4
22+
uses: actions/cache@v5
2323
with:
2424
path: ~/.cache
2525
key: reqs_${{ hashFiles('poetry.lock') }}
@@ -62,7 +62,7 @@ jobs:
6262
# Maps tcp port 5432 on service container to the host
6363
- 5432:5432
6464
steps:
65-
- uses: actions/checkout@v2
65+
- uses: actions/checkout@v6
6666
- uses: ./.github/actions/start-build
6767
- name: Run tests
6868
run: poetry run python3 -m invoke test-ci-addons --junit
@@ -80,7 +80,7 @@ jobs:
8080
services:
8181
postgres: *POSTGRES_SERVICE
8282
steps:
83-
- uses: actions/checkout@v2
83+
- uses: actions/checkout@v6
8484
- uses: ./.github/actions/start-build
8585
- name: Run tests
8686
run: poetry run python3 -m invoke test-ci-website --junit
@@ -97,7 +97,7 @@ jobs:
9797
elasticsearch8: *ES8_SERVICE
9898
postgres: *POSTGRES_SERVICE
9999
steps:
100-
- uses: actions/checkout@v2
100+
- uses: actions/checkout@v6
101101
- uses: ./.github/actions/start-build
102102
- name: NVM & yarn install
103103
run: poetry run python3 -m invoke assets --dev
@@ -118,7 +118,7 @@ jobs:
118118
elasticsearch8: *ES8_SERVICE
119119
postgres: *POSTGRES_SERVICE
120120
steps:
121-
- uses: actions/checkout@v2
121+
- uses: actions/checkout@v6
122122
- uses: ./.github/actions/start-build
123123
- name: Run tests
124124
run: poetry run python3 -m invoke test-ci-api2 --junit
@@ -136,7 +136,7 @@ jobs:
136136
services:
137137
postgres: *POSTGRES_SERVICE
138138
steps:
139-
- uses: actions/checkout@v2
139+
- uses: actions/checkout@v6
140140
- uses: ./.github/actions/start-build
141141
- name: Run tests
142142
run: poetry run python3 -m invoke test-ci-api3-and-osf --junit
@@ -157,7 +157,7 @@ jobs:
157157
- 1025:1025
158158
- 8025:8025
159159
steps:
160-
- uses: actions/checkout@v2
160+
- uses: actions/checkout@v6
161161
- uses: ./.github/actions/start-build
162162
- name: Run tests
163163
run: poetry run python3 -m invoke test-ci-mailhog -n 1 --junit
@@ -173,7 +173,7 @@ jobs:
173173
services:
174174
postgres: *POSTGRES_SERVICE
175175
steps:
176-
- uses: actions/checkout@v2
176+
- uses: actions/checkout@v6
177177
- uses: ./.github/actions/start-build
178178
- name: Run tests
179179
run: poetry run python3 -m invoke test-ci-scripts -n 1 --junit

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ website/static/sitemaps/
122122
##############
123123

124124
api/static/vendor
125+
osf/features.override.yaml
125126

126127
# Local settings files
127128
local.py

CHANGELOG

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,42 @@
22

33
We follow the CalVer (https://calver.org/) versioning scheme: YY.MINOR.MICRO.
44

5+
26.8.0 (2026-04-23)
6+
===================
7+
8+
- Miscellaneous improvements and bug fixes
9+
10+
26.7.1 (2026-04-22)
11+
===================
12+
13+
- Hotfix to improve notifications and logging for failed registrations
14+
15+
26.7.0 (2026-04-08)
16+
===================
17+
18+
- ORCiD Integration Project - BE Part
19+
20+
26.6.3 (2026-04-02)
21+
===================
22+
23+
- Readd reindex share button
24+
- Fix missing notification during email throttle check
25+
- Fix filter query in AbstractProviderSubscriptionList
26+
27+
26.6.0 (2026-03-26)
28+
===================
29+
30+
- Miscellaneous improvements and bug fixes
31+
32+
26.5.1 (2026-03-25)
33+
===================
34+
35+
- Post-NR hotfixes
36+
- Rework notification history cleanup task
37+
- Update merge subscription provider task
38+
- Enable overriding features.yaml for local dev to use mailhog
39+
- Remove deprecated routes, script and commands
40+
541
26.5.0 (2026-03-13)
642
===================
743

README-docker-compose.md

Lines changed: 11 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -171,7 +171,7 @@
171171
- When starting with an empty database you will need to run migrations and populate preprint providers. See the [Running arbitrary commands](#running-arbitrary-commands) section below for instructions.
172172
6. Start the OSF Web, API Server, and Preprints (Detached)
173173
```bash
174-
docker compose up -d worker web api admin preprints ember_osf_web gv
174+
docker compose up -d worker web api admin preprints gv
175175
```
176176
7. View the OSF at [http://localhost:5000](http://localhost:5000).
177177

@@ -181,7 +181,7 @@
181181
- Once the requirements have all been installed, you can start the OSF in the background with
182182

183183
```bash
184-
docker compose up -d assets admin_assets mfr wb fakecas sharejs worker web api admin preprints ember_osf_web gv
184+
docker compose up -d assets admin_assets mfr wb fakecas sharejs worker web api admin preprints gv
185185
```
186186

187187
- To view the logs for a given container:
@@ -270,20 +270,10 @@
270270
```bash
271271
docker compose run --rm web python3 -m scripts.parse_citation_styles
272272
```
273-
- Populate Notification Types
274-
- Needed for notifications.
275-
```bash
276-
docker compose run --rm web python3 manage.py populate_notification_types
277-
```
278-
- _NOTE: The waffle switch `POPULATE_NOTIFICATION_TYPES` needs to be turned on.
279-
- Start ember_osf_web
280-
- Needed for ember app:
281-
- `docker-compose up -d ember_osf_web`
282273
- OPTIONAL: Register OAuth Scopes
283-
- Needed for things such as the ember-osf dummy app
284-
```bash
285-
docker compose run --rm web python3 -m scripts.register_oauth_scopes
286-
```
274+
```bash
275+
docker compose run --rm web python3 -m scripts.register_oauth_scopes
276+
```
287277
- OPTIONAL: Create migrations:
288278
- After changing a model you will need to create migrations and apply them. Migrations are python code that changes either the structure or the data of a database. This will compare the django models on disk to the database, find the differences, and create migration code to change the database. If there are no changes this command is a noop.
289279
```bash
@@ -294,6 +284,11 @@
294284
```bash
295285
docker compose run --rm web python3 manage.py reset_db --noinput
296286
```
287+
- OPTIONAL: Create a `features.yaml` override
288+
```bash
289+
cp osf/features.yaml osf/features.override.yaml
290+
```
291+
Note: Update the WAFFLE_VALUES_YAML variable to point to the override file (osf/features.override.yaml).
297292

298293
## Application Debugging
299294

@@ -506,4 +501,4 @@ wb:
506501
507502
### Running Collections
508503
509-
To run collections, you must uncomment COLLECTIONS_ENABLED=true in docker-compose.yml under ember_osf_web, then recreate your ember and web containers.
504+
To run collections, you must uncomment COLLECTIONS_ENABLED=true in docker-compose.yml, then recreate web container.

addons/base/views.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -950,12 +950,12 @@ def addon_view_or_download_file(auth, path, provider, **kwargs):
950950
)
951951
)
952952

953-
# There's no download action redirect to the Ember front-end file view and create guid.
953+
# There's no download action redirect to the front-end file view and create guid.
954954
if action != 'download':
955-
if isinstance(target, Node) and flag_is_active(request, features.EMBER_FILE_PROJECT_DETAIL):
955+
if isinstance(target, Node):
956956
guid = file_node.get_guid(create=True)
957957
return redirect(f'{settings.DOMAIN}{guid._id}/')
958-
if isinstance(target, Registration) and flag_is_active(request, features.EMBER_FILE_REGISTRATION_DETAIL):
958+
if isinstance(target, Registration):
959959
guid = file_node.get_guid(create=True)
960960
return redirect(f'{settings.DOMAIN}{guid._id}/')
961961

addons/osfstorage/tests/test_views.py

Lines changed: 11 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@
3636

3737
from osf_tests.factories import ProjectFactory, ApiOAuth2PersonalTokenFactory, PreprintFactory
3838
from website.files.utils import attach_versions
39-
from website.settings import EXTERNAL_EMBER_APPS
4039
from api_tests.draft_nodes.views.test_draft_node_files_lists import prepare_mock_wb_response
4140

4241

@@ -1413,28 +1412,17 @@ def test_file_view_updates_history(self):
14131412
{'name': 'testpath', 'path': '/testpath', 'materialized': '/testpath', 'kind': 'file'},
14141413
]
14151414
)
1416-
with override_flag(features.EMBER_FILE_PROJECT_DETAIL, active=True):
1417-
url = self.node.web_url_for('addon_view_or_download_file', path='testpath', provider='github')
1418-
self.app.get(url, auth=self.user.auth)
1419-
file = GithubFile.objects.get(_path='/testpath', provider='github')
1420-
assert file.history
1421-
1422-
@mock.patch('website.views.stream_emberapp')
1423-
def test_file_views(self, mock_ember):
1424-
with override_flag(features.EMBER_FILE_PROJECT_DETAIL, active=True):
1425-
file = create_test_file(target=self.node, user=self.user)
1426-
url = self.node.web_url_for('addon_view_or_download_file', path=file._id, provider=file.provider)
1427-
res = self.app.get(url, auth=self.user.auth)
1428-
assert res.status_code == 302
1429-
assert res.headers['Location'] == f'{settings.DOMAIN}{file.get_guid()._id}/'
1430-
assert not mock_ember.called
1431-
res = self.app.get(url, auth=self.user.auth, follow_redirects=True)
1432-
assert res.status_code == 200
1433-
assert mock_ember.called
1434-
args, kwargs = mock_ember.call_args
1435-
1436-
assert args[0] == EXTERNAL_EMBER_APPS['ember_osf_web']['server']
1437-
assert args[1] == EXTERNAL_EMBER_APPS['ember_osf_web']['path'].rstrip('/')
1415+
url = self.node.web_url_for('addon_view_or_download_file', path='testpath', provider='github')
1416+
self.app.get(url, auth=self.user.auth)
1417+
file = GithubFile.objects.get(_path='/testpath', provider='github')
1418+
assert file.history
1419+
1420+
def test_file_views(self):
1421+
file = create_test_file(target=self.node, user=self.user)
1422+
url = self.node.web_url_for('addon_view_or_download_file', path=file._id, provider=file.provider)
1423+
res = self.app.get(url, auth=self.user.auth)
1424+
assert res.status_code == 302
1425+
assert res.headers['Location'] == f'{settings.DOMAIN}{file.get_guid()._id}/'
14381426

14391427
def test_download_file(self):
14401428
file = create_test_file(target=self.node, user=self.user)

addons/wiki/routes.py

Lines changed: 2 additions & 72 deletions
Original file line numberDiff line numberDiff line change
@@ -3,88 +3,18 @@
33
"""
44

55
from framework.routing import Rule, json_renderer
6-
from website.routes import OsfWebRenderer
76

87
from . import views
98

10-
TEMPLATE_DIR = './addons/wiki/templates/'
11-
129
settings_routes = {
1310
'rules': [],
1411
'prefix': '/api/v1',
1512
}
1613

1714
# NOTE: <wname> refers to a wiki page's key, e.g. 'Home'
15+
# All HTML-rendered wiki routes have been removed; only API routes remain.
1816
page_routes = {
19-
20-
'rules': [
21-
22-
# Home (Base) | GET
23-
Rule(
24-
[
25-
'/project/<pid>/wiki/',
26-
'/project/<pid>/node/<nid>/wiki/',
27-
],
28-
'get',
29-
views.project_wiki_home,
30-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
31-
),
32-
33-
# View (ID) | GET
34-
Rule(
35-
[
36-
'/project/<pid>/wiki/id/<wid>/',
37-
'/project/<pid>/node/<nid>/wiki/id/<wid>/',
38-
],
39-
'get',
40-
views.project_wiki_id_page,
41-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
42-
),
43-
44-
# Wiki | GET
45-
Rule(
46-
[
47-
'/project/<pid>/wiki/<wname>/',
48-
'/project/<pid>/node/<nid>/wiki/<wname>/',
49-
],
50-
'get',
51-
views.project_wiki_view,
52-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
53-
),
54-
55-
# Edit | GET (legacy url, trigger redirect)
56-
Rule(
57-
[
58-
'/project/<pid>/wiki/<wname>/edit/',
59-
'/project/<pid>/node/<nid>/wiki/<wname>/edit/',
60-
],
61-
'get',
62-
views.project_wiki_edit,
63-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
64-
),
65-
66-
# Compare | GET (legacy url, trigger redirect)
67-
Rule(
68-
[
69-
'/project/<pid>/wiki/<wname>/compare/<int:wver>/',
70-
'/project/<pid>/node/<nid>/wiki/<wname>/compare/<int:wver>/',
71-
],
72-
'get',
73-
views.project_wiki_compare,
74-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
75-
),
76-
77-
# Edit | POST
78-
Rule(
79-
[
80-
'/project/<pid>/wiki/<wname>/',
81-
'/project/<pid>/node/<nid>/wiki/<wname>/',
82-
],
83-
'post',
84-
views.project_wiki_edit_post,
85-
OsfWebRenderer('edit.mako', trust=False, template_dir=TEMPLATE_DIR)
86-
),
87-
]
17+
'rules': [],
8818
}
8919

9020
api_routes = {

0 commit comments

Comments
 (0)