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

Sync opencraft-release/palm.1 with Upstream 20230911-1694390586 #584

Conversation

opencraft-requirements-bot

Syncing opencraft-release/palm.1 with Upstream

Important❗

Please always use the "Create a merge commit" option as it avoids issues when checking diffs with upstream.

Note on Conflicts ⚠️

In cases of conflicts you can go ahead and resolve it here on Github if it is simple enough. However if it is a more complicated conflict please follow the steps below:

  1. Check out sync-open-release/palm.master-20230911-1694390586 locally:
  2. Pull latest changes from opencraft-release/palm.1 into that branch, make sure your [REMOTE] is pointing to opencraft-release/palm.1:
git pull [REMOTE] opencraft-release/palm.1
  1. Resolve the conflicts locally, then commit the result. This will create a new merge commit.
  2. Push the new merge commit to sync-open-release/palm.master-20230911-1694390586 to update this PR
  3. Review the PR again and merge when ready!
    Note: Please use the "Create a merge commit" option as it avoids issues when checking diffs with upstream.

dyudyunov and others added 3 commits September 5, 2023 09:11
…dx#33150)

This is a backport from the master branch:
openedx#30954

The course is visible on the main page right after creation.

So anonymous users can see them and access the course about page
for the courses without valid data (e.g. they will see the default
course overview)

When courses list filtering is processed it checks the `see_exists`
permission for the anonymous user.
Actually, `see_exists` means `can_load` OR `can_enroll`.

`can_load` is False in our case because the course start in the future.

But `can_enroll` returns True because the course's enrollment_start
and enrollment_end dates are blank:
```
enrollment_start = courselike.enrollment_start or datetime.min.replace(tzinfo=UTC)
enrollment_end = courselike.enrollment_end or datetime.max.replace(tzinfo=UTC)
if enrollment_start < now < enrollment_end:
    debug("Allow: in enrollment period")
    return ACCESS_GRANTED
```

Set the enrollment_start the same as a course start by default
if the CREATE_COURSE_WITH_DEFAULT_ENROLLMENT_START_DATE
feature toggle is enabled (default is False).
@Agrendalath Agrendalath merged commit 98944d2 into opencraft-release/palm.1 Sep 11, 2023
41 checks passed
@Agrendalath Agrendalath deleted the sync-open-release/palm.master-20230911-1694390586 branch September 11, 2023 16:01
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.

4 participants