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

Move the i18n/ url outside of the i18n_patterns function as per the Django documentation #10754

Merged
merged 10 commits into from
May 13, 2024
1 change: 1 addition & 0 deletions arches/install/arches-templates/project_name/urls.py-tpl
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,4 @@ urlpatterns = [

# if settings.SHOW_LANGUAGE_SWITCH is True:
# urlpatterns = i18n_patterns(*urlpatterns)
# urlpatterns.append(path("i18n/", include("django.conf.urls.i18n")))
1 change: 0 additions & 1 deletion arches/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -288,7 +288,6 @@
# re_path(r'^admin/doc/', include('django.contrib.admindocs.urls')),
# Uncomment the next line to enable the admin:
re_path(r"^admin/", admin.site.urls),
path("i18n/", include("django.conf.urls.i18n")),
re_path(r"^password_reset/$",PasswordResetView.as_view(),name="password_reset",),
re_path(r"^password_reset/done/$", auth_views.PasswordResetDoneView.as_view(), name="password_reset_done"),
path(
Expand Down
20 changes: 15 additions & 5 deletions releases/7.6.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Arches 7.6.0 Release Notes
- 9191 Adds unlocalized string datatype
- 10781 Graph.delete_instances() now uses BulkDataDeletion
- 10665 Return resourceid in ActivityStream rather than resource url
- 10754 Move the i18n/ url outside of the i18n_patterns function

### Dependency changes
```
Expand Down Expand Up @@ -202,17 +203,26 @@ Minor incompatibilities:
},
}
```
9. In urls.py:
1. Update SHOW_LANGUAGE_SWITCH to the following:

9. Run `python manage.py updateproject`
*Note: If the previous code was uncommented in your project make sure to uncomment the new code.*
```
# if settings.SHOW_LANGUAGE_SWITCH is True:
# urlpatterns = i18n_patterns(*urlpatterns)
# urlpatterns.append(path("i18n/", include("django.conf.urls.i18n")))
```

10. Run `python manage.py updateproject`

10. Navigate to the directory with your project's package.json file. Then run:
11. Navigate to the directory with your project's package.json file. Then run:
```
yarn install
```

11. Start your application server in a separate terminal if it's not already running.
12. Start your application server in a separate terminal if it's not already running.

12. In the same terminal window where you ran `yarn` ( on the same level as `package.json` ):
13. In the same terminal window where you ran `yarn` ( on the same level as `package.json` ):

1. Run `yarn gettext:extract` followed by `yarn gettext:compile`. This will generate i18n files in your `locale` directory. Even if you're
not planning on internationalizing your project, it's important to have these files for creating Vue components.
Expand All @@ -225,7 +235,7 @@ Minor incompatibilities:
- `yarn build_production` This builds a production bundle. **takes up to 2hrs depending on resources**
- Alternatively you can run `python manage.py build_production`. This will create a production bundle of frontend assessts and also call `collectstatic`.

13. If you are running Arches on Apache, be sure to run:
14. If you are running Arches on Apache, be sure to run:

```
collectstatic
Expand Down