Code Monkey home page Code Monkey logo

frontend-app-gradebook's Issues

Wrong/Deprecated bulk update history URL being used

While looking into an issue related to grade book MFE, We noticed that one of the URLs was throwing 404. That's the /bulk-update-history. Our assumption is that the bulk update URL might also be wrong.

Steps to reproduce

  • Enable grades.bulk_management Waffle flag in Django Admin (LMS)
  • Run the grade book and monitor the network tab.
  • Notice that It would hit the URL(api/grades/v1/gradebook/course-v1:MITx+Template.Mac+07_25_2023/bulk-updatehistory/) to fetch the bulk update history that ends up in 404 because this URL doesn't seem to exist anywhere. (Here is the code reference from the gradebook MFE).

Possible Solution:

We think that the gradebook MFE should probably use api/bulk_grades/course/course-v1:Arbisoft+ARB_1+1/history/ instead of api/grades/v1/gradebook/course-v1:MITx+Template.Mac+07_25_2023/bulk-updatehistory/.

Switch to Ansible-free Docker image

In order to advance implementation of both OEP-45: Configuring and Operating Open edX and openedx/public-engineering#51, we would like to switch devstack from using primarily Docker images built with Ansible code from the configuration repository to images built from Dockerfiles in each service's repository. We hope this will also help simplify Tutor by providing better base images to derive from, with fewer workarounds and duplicated code blocks required in Tutor.

A/C

Ensure that the repo's Dockerfile can create a base image which is appropriate for small production installations
Ensure that the repo's Dockerfile also defines an additional image derived from the base which adds dependencies and configuration changes needed for development environments
Check with the Tutor developers during code review to see if any further changes to the Dockerfile would help simplify Tutor
Automate uploads of both images when code changes are merged
Switch devstack to use the new Ansible-free development image, and do some basic testing to ensure it works before merging

Adjusted grades should not greater than 100%

Expected behavior

There should be a validation check that the value is not greater than 100%, and it should show the updated value.

Actual behavior

Incorrect value and validation is missing

Steps to reproduce

  1. Go to instructor's tab of a course with staff access
  2. Go to student admin tab
  3. click on view gradebook button
  4. update student's grade to 99 and check if its updated correctly.

Additional information

Screenshot 2024-05-22 at 1 19 02 PM Screenshot 2024-05-22 at 1 19 15 PM Screenshot 2024-05-22 at 1 21 37 PM

Original issue: openedx/wg-build-test-release#357

A11y: spinner issue

"a11y noting the need for exposing the state programmatically, and focus management. And is should announce "ready" to screen reader users when removed. We should make a Paragon component for this. OK to defer a proper fix until that component is created, for this specific case, as it is low-risk UX scenario." ~ Jeff Witt

Considerations

  • Focus management
  • Text alternatives (and labels)
  • 3:1 contrast for the colors
  • messages to visually impaired users
    • off!
    • waiting...
    • done!

This will always be scoped to a GLOBAL SPINNER

Update README configuration filepath

Hello!

On the README, it says:

by putting this settings in lms/env/private.py

Seeing that settings are now in different files, could we update it to something like:

by putting this settings in /edx/etc/lms.yml (or /edx-platform/lms/envs/common.py?)

(This was tested and it works as expected on a devstack)

I'd love to make the PR but maybe the change should include both paths? I prefer asking firsthand.

Anyways, thank you for your work!!

Uncaught TypeError when trying to re-edit grade

Description

When editing a grade immediately after a first successful change, an uncaught TypeError is thrown. See the video:

Gradebook.bug.webm

The error is thrown on this line:

https://github.com/openedx/frontend-app-gradebook/blob/9c7c848/src/components/GradesView/EditModal/OverrideTable/index.jsx#L27

With this message:

TypeError: data is undefined
    OverrideTable index.jsx:27
    React 12
    unstable_runWithPriority scheduler.development.js:468
    React 6
 
Object { stack: "\nOverrideTable@webpack-internal:///./src/components/GradesView/EditModal/OverrideTable/index.jsx:38:57\ndiv\ndiv\ndiv\nModalDialogBody@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/ModalDialogBody.js:31:12\ndiv\ndiv\nModalContentContainer@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/ModalLayer.js:45:18\ndiv\nRemoveScroll<@webpack-internal:///./node_modules/react-remove-scroll/dist/es2015/UI.js:22:50\nFocusLockUI@webpack-internal:///./node_modules/react-focus-lock/dist/es2015/Lock.js:25:60\nFocusOn<@webpack-internal:///./node_modules/react-focus-on/dist/es2015/UI.js:22:49\nPortal@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/Portal.js:30:20\nModalContextProvider@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/ModalContext.js:15:17\nModalLayer@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/ModalLayer.js:64:18\nModalDialog@webpack-internal:///./node_modules/@openedx/paragon/dist/Modal/ModalDialog.js:44:18\nEditModal@webpack-internal:///./src/components/GradesView/EditModal/index.jsx:45:78\nGradesView@webpack-internal:///./src/components/GradesView/index.jsx:53:7\ndiv\ndiv\ndiv\nWithSidebar@webpack-internal:///./src/components/WithSidebar/index.jsx:43:1\nConnectFunction@webpack-internal:///./node_modules/react-redux/es/components/connectAdvanced.js:233:68\nGradebookPage@webpack-internal:///./src/containers/GradebookPage/index.jsx:52:5\nWithLocationComponent@webpack-internal:///./src/utils/hoc.jsx:51:83\nWithNavigateComponent@webpack-internal:///./src/utils/hoc.jsx:37:83\nWithParamsComponent@webpack-internal:///./src/utils/hoc.jsx:26:189\nConnectFunction@webpack-internal:///./node_modules/react-redux/es/components/connectAdvanced.js:233:68\nRenderedRoute@webpack-internal:///./node_modules/react-router/dist/index.js:557:7\nRoutes@webpack-internal:///./node_modules/react-router/dist/index.js:1187:7\nmain\ndiv\ndiv\nRouter@webpack-internal:///./node_modules/react-router/dist/index.js:1129:7\nBrowserRouter@webpack-internal:///./node_modules/react-router-dom/dist/index.js:403:7\ndiv\nProvider@webpack-internal:///./node_modules/react-redux/es/components/Provider.js:18:15\nOptionalReduxProvider@webpack-internal:///./node_modules/@edx/frontend-platform/react/OptionalReduxProvider.js:18:15\nErrorBoundary@webpack-internal:///./node_modules/@edx/frontend-platform/react/ErrorBoundary.js:139:20\nIntlProvider@webpack-internal:///./node_modules/@edx/frontend-platform/node_modules/react-intl/lib/src/components/provider.js:97:47\nAppProvider@webpack-internal:///./node_modules/@edx/frontend-platform/react/AppProvider.js:110:15\nApp" }
NewRelicLoggingService.js:36:12
    sendError NewRelicLoggingService.js:36
    logError NewRelicLoggingService.js:168
    logError interface.js:71
    componentDidCatch ErrorBoundary.jsx:26
    React 9
    unstable_runWithPriority scheduler.development.js:468
    React 4
    unstable_runWithPriority scheduler.development.js:468
    React 6

Include `paragonMessages` in MFE initialization

@edx/paragon was recently upgraded to v20 in this MFE. v20 added a dependency on react-intl due to Paragon now shipping with already-translated English messages for its components.

Per the release notes, Paragon v20 now exposes a paragonMessages array containing the native translations for Paragon components but the paragonMessages are not yet passed to @edx/frontend-platform via the initialize function for this MFE.

Looks like importing and re-exporting paragonMessages in src/i18n/index.js(source) would do the trick 😃

Tasks

Node 20 upgrade

Description

See the parent ticket for the general description and motivation, openedx/public-engineering#267. Make sure to follow its recommendations for each step of the process.

Tasks

Upgrade React JS to v17

This repo is currently using React JS v16. We need to upgrade it to React 17 before moving to latest React version(v18).
React 17 doesn’t add any new developer-facing features, so its upgrade might not cause any breaking changes. Our end goal is to upgrade React to v18 but v18 no longer support enzyme, so we are upgrading to React 17 and then we’ll migrate from enzyme.

Epic Link

React 17 upgrade

Install in Ironwood.master

Tried to install in ironwood.master. Got some errors:

(edxapp) edxapp@hadoop:~/edx-platform$ npm i --save git+https://[email protected]/edx/frontend-app-gradebook\#open-release/ironwood.master
npm WARN deprecated [email protected]: This project is no longer maintained.
npm WARN deprecated [email protected]: fsevents 1 will break on node v14+ and could be using insecure binaries. Upgrade to fsevents 2.
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.0.0 (node_modules/chokidar/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@^1.2.3 (node_modules/sane/node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for [email protected]: wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
npm WARN [email protected] requires a peer of popper.js@^1.16.0 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of eslint-plugin-import@^2.7.0 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of eslint@^2.9.0 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] requires a peer of selenium-webdriver@^2.44.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of react@^16.4.2 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of redux@^4.0.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of @edx/paragon@^3.8.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of clean-webpack-plugin@^0.1.19 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of copy-webpack-plugin@^4.6.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of html-webpack-plugin@^3.2.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of react@^16.4.2 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of react-dom@^16.2.0 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of webpack@^4.19.1 but none is installed. You must install peer dependencies yourself.
npm WARN @edx/[email protected] requires a peer of webpack-merge@^4.2.1 but none is installed. You must install peer dependencies yourself.
npm WARN [email protected] No repository field.
npm WARN [email protected] No license field.

+ @edx/[email protected]
updated 1 package in 29.124s

Then sets WRITABLE_GRADEBOOK_URL = 'http://localhost:1994' in lms/envs/common.py and restart services, but
sudo lsof -i -P -n | grep 1994 gives empty set and

curl -X GET http://localhost:1994/course-v1:edX+DemoX+Demo_Course
curl: (7) Failed to connect to localhost port 1994: Connection refused

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.