Skip to content

Coldfront update 1.1.8#48

Open
matthew-kusz wants to merge 320 commits into
coldfront-update-1.1.8-mergerfrom
coldfront-update-1.1.8
Open

Coldfront update 1.1.8#48
matthew-kusz wants to merge 320 commits into
coldfront-update-1.1.8-mergerfrom
coldfront-update-1.1.8

Conversation

@matthew-kusz

Copy link
Copy Markdown
Collaborator

No description provided.

cecilialau6776 and others added 30 commits December 5, 2025 12:57
Signed-off-by: Cecilia Lau <cecilialau6776@gmail.com>
Signed-off-by: Cecilia Lau <cecilialau6776@gmail.com>
In preparation for upgrading to Django5, this commit cleans up the
following minor warnings/errors found by running:

```
PYTHONWARNINGS=always uv run coldfront test
```

- ResourceWarning: unclosed file <_io.TextIOWrapper name='.env' mode='r' encoding='UTF-8'>
- RemovedInDjango50Warning: The USE_L10N setting is deprecated. (always
  enabled by default now)
- RemovedInDjango50Warning: The django.utils.timezone.utc alias is deprecated.
- DeprecationWarning: The 'warn' method is deprecated, use 'warning' instead

We also adjust this test case which will error out in Django5:

ERROR: test_project_attribute_create_post_required_values
ProjectAttributeCreate correctly flags missing project or value
----------------------------------------------------------------------
Traceback (most recent call last):
  File "coldfront/core/project/tests/test_views.py", line 174, in test_project_attribute_create_post_required_values
    self.assertFormError(response, "form", "project", "This field is required.")
  File ".venv/lib/python3.12/site-packages/django/test/testcases.py", line 708, in assertFormError
    self._assert_form_error(form, field, errors, msg_prefix, f"form {form!r}")
  File ".venv/lib/python3.12/site-packages/django/test/testcases.py", line 674, in _assert_form_error
    if not form.is_bound:
           ^^^^^^^^^^^^^
AttributeError: 'TemplateResponse' object has no attribute 'is_bound'

The `assertFormError` in SimpleTestCase requires a bound form instance not a
template response. Instead we check the response content to ensure we're still
on the project attribute create page.

Signed-off-by: Andrew E. Bruno <aebruno2@buffalo.edu>
Signed-off-by: Simon Leary <simon.leary42@proton.me>
document undocumented settings, document settings vs. environment variables
When syncing unix groups with FreeIPA, the group_remove_member and
group_add_member commands are submitted to the IPA server separately per
user. This patch modifies the FreeIPA sync command to leverage the batch
command from the IPA API which can be used to send commands in the same
API request. Currently the batch size is hard coded to 100 which should
be sufficent. In the future consider making this a CLI arg.

See here: https://freeipa.readthedocs.io/en/latest/api/basic_usage.html#batch-operations

We have also been experiencing random failures on IPA API calls, for
example:

```
ipa: ERROR: connect to 'https://ipa-server/ipa/json': EOF occurred in violation of protocol (_ssl.c:2427)
```

It appears this may be caused by running the IPA API bootstrapping when
utils.py was imported instead of right before making an API call.  This
patch adds a helper function for more control over when to bootstrap the
IPA API.

Signed-off-by: Andrew E. Bruno <aebruno2@buffalo.edu>
Signed-off-by: Chris Diaz <24395592+chrisdaaz@users.noreply.github.com>
PR coldfront#902 did not work with postgres. This commit fixes that.

Signed-off-by: Andrew E. Bruno <aebruno2@buffalo.edu>
Fix aggregation to be compatible with postgres.
- Remove default_app_config (has been deprecated since 3.2)
- Fix admin.action descriptions

Signed-off-by: Andrew E. Bruno <aebruno2@buffalo.edu>
Batch commands when syncing FreeIPA.
This allows for center directors to configure which Project fields
project managers are able to edit.

Signed-off-by: Cecilia Lau <cecilialau6776@gmail.com>
…ds_setting

add coldfront core setting for PROJECT_UPDATE_FIELDS
Squashed commits:
- fix project notifs
- fix allocation change detail page button spacing
- fix allocation change request edit button visibility
- add request change button to allocation change requests section
- formatting
- make test pass
- Add title for grant/research output pagees
- Add "Creating/updating grant/research output for project: <project>" to the
  appropriate pages.
- Update button icons
- Add space between folder icon and project title on home page
- Fix select all for add user to project
- Merge branch 'main' into ui_fixes
- fix allocation change detail button margins

Signed-off-by: Cecilia Lau <cecilialau6776@gmail.com>
Squashed commits:
- add emails for user added to a project/allocation
- set default sender for emails to EMAIL_SENDER
- remove redundant EMAIL_ENABLED checks, set default email sender to EMAIL_SENDER
- add project archived email
- add get_user_emails method for Project and Allocation
- fix missing redirect, remove redundant CENTER_NAME from ctx

Signed-off-by: Cecilia Lau <cecilialau6776@gmail.com>
…roject-access-tests

Add additional access checks for existing project tests and fix comments
…lp-text

Add slurm help text on the home page and allocation page
Signed-off-by: Simon Leary <simon.leary42@proton.me>
Signed-off-by: Simon Leary <simon.leary42@proton.me>
Signed-off-by: Matthew Kusz <kuszm646@gmail.com>
…lurm-doc

Add new Slurm config options to documentation
…cations

Add more email notifs + cleanup email code
…r-boilerplate

remove attribute validation boilerplate, add tests, improve tests
matthew-kusz and others added 30 commits July 17, 2026 12:48
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.

7 participants