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

Conceal the name of the editor during project submission. Ref #2117. #2156

Merged
merged 3 commits into from
Jan 11, 2024

Conversation

tompollard
Copy link
Member

@li-lcp has asked to conceal the name of the editor for projects (see #2117).

This pull request removes the name of the editor from the submission history page, and add general contact information for the platform.

In #2117, Li-wei asks for an "[email protected]" email address to be listed. This address is not recorded in the config file, so for now I am using the general CONTACT_EMAIL.

Example:

Screenshot 2023-12-02 at 3 25 55 PM

@bemoody
Copy link
Collaborator

bemoody commented Jan 4, 2024

I think we really don't want to use contact@ and this behavior should be configurable. Could be as simple as:

    if settings.PROJECT_EDITOR_EMAIL:
        contact_email = settings.PROJECT_EDITOR_EMAIL
    else:
        contact_email = project.editor.email

But we could also allow for a project-specific contact address (see my comment in #2117):

    if settings.PROJECT_EDITOR_EMAIL:
        contact_email = settings.PROJECT_EDITOR_EMAIL.replace('PROJECT-SLUG',
                                                              project.slug)
    else:
        contact_email = project.editor.email

@bemoody
Copy link
Collaborator

bemoody commented Jan 11, 2024

Thanks! The setting needs to be defined in physionet-django/physionet/settings/base.py (and it shouldn't default to physionet.org). I don't think there is any need to define it separately in development/base.py, production.py, settings.py, and staging.py.

@bemoody
Copy link
Collaborator

bemoody commented Jan 11, 2024

looks good!

@bemoody bemoody merged commit 323cdff into dev Jan 11, 2024
11 checks passed
@bemoody bemoody deleted the tp/hide_editor branch January 11, 2024 20:06
tompollard added a commit that referenced this pull request Jan 18, 2024
Pull #2156 introduced the PROJECT_EDITOR_EMAIL setting.

If this setting is not defined (or blank) then we want to fall back to
the old behavior of showing the assigned editor's email address.

However, if the project has not yet been assigned to an editor, and
PROJECT_EDITOR_EMAIL is blank, it would crash.

(For example, clear the PROJECT_EDITOR_EMAIL setting, then log in as
rgmark and try to submit the "MIMIC-III Clinical Database" project.)
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.

2 participants