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

Assignment without due dates are not being imported into Notion #251

Closed
migszu opened this issue Sep 7, 2023 · 2 comments · Fixed by #384
Closed

Assignment without due dates are not being imported into Notion #251

migszu opened this issue Sep 7, 2023 · 2 comments · Fixed by #384
Assignees
Labels
bug Something isn't working

Comments

@migszu
Copy link

migszu commented Sep 7, 2023

Screenshot 2023-09-07 210634

@JamesNZL JamesNZL self-assigned this Sep 8, 2023
@JamesNZL JamesNZL added the bug Something isn't working label Sep 8, 2023
@JamesNZL
Copy link
Owner

JamesNZL commented Sep 8, 2023

  • Matthew's PR will mutate all assignment due dates
  • If the assignment due date does not exist, it will assign it to the Unix epoch
  • This will cause assignments without due dates to be treated as past assignments, and hence ignored on import

@JamesNZL
Copy link
Owner

JamesNZL commented Apr 4, 2024

In the meantime, a workaround:

  1. Right click in the popup window, and click Inspect

  2. Go to the Console tab for the extension popup, and paste the following:

await chrome.storage.local.set({
  savedAssignments: Object.fromEntries(
    Object.entries((await chrome.storage.local.get()).savedAssignments)
      .map(([key, value]) => [
        key,
        value.map(assignment => {
          if (assignment.due !== "1970-01-01T12:00:00.000Z") {
              return assignment;
          }

          console.log(`skipping ${assignment.name}`);
          assignment.due = "2024-12-12T12:00:00.000Z";
          return assignment;
        })
      ]),
  ),
});
  1. Hit Enter

That will make all of your assignments that don't have due dates be imported into Notion as being due in December (right now, it's due in 1970, which is in the past, so it's ignored by the importer).

You can then click+drag (or shift+click) in Notion (probably easiest in a table view) to clear all of the placeholder due dates at once.

JamesNZL added a commit that referenced this issue Jul 4, 2024
* fix(canvas): 🐛 do not store absence of due date as unix epoch (#251)

* fix(import): 🐛 correctly import assignments without due dates to notion (#251)
JamesNZL added a commit that referenced this issue Jul 4, 2024
* fix(canvas): 🐛 do not store absence of due date as unix epoch (#251)

* fix(import): 🐛 correctly import assignments without due dates to notion (#251)
JamesNZL added a commit that referenced this issue Jul 4, 2024
… (#387)

* Fix import of assignments without due dates (#251) (#384)

* fix(canvas): 🐛 do not store absence of due date as unix epoch (#251)

* fix(import): 🐛 correctly import assignments without due dates to notion (#251)

* refactor(types): 🏷️ refactor type declaration files

change to regular typescript files

* fix(validator): 🐛 fix timezone validation (#252)

* build(notion): 👽 pin notion api version

* feat(notion): ✨ parse notion page properties

* feat(options): ✨ add `notion.importChanges` options

* fix(interface): 💄 properly hide segmented controls

* refactor(types): 🧑‍💻 strongly type `Storage` key methods

* docs(readme): 📝 update `readme`

* docs(readme): 📝 update advanced options heading size

* feat(import)!: ✨ update existing pages if assignment has changed (#385)

BREAKING CHANGE: This requires a new previously unheld capability on the integration. Existing users must reauthorise with Notion.

* build(actions): 💚 fix gulp build
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants