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

Tasks without section sometimes still display a section on the list command #161

Open
andreoliwa opened this issue Mar 26, 2021 · 2 comments

Comments

@andreoliwa
Copy link
Contributor

Hi!

There are tasks without a section that still display a section when I use the list command.

This bug doesn't happen with all tasks.
Steps to reproduce:

  1. Create a new project called "Example".
  2. Add a task called "Some task" without a section.
  3. Run todoist sync && todoist list -f '#example': the project shows as #Example. ✅
  4. Create a new section called "My Section".
  5. Move "Some task" to "My Section".
  6. Run todoist sync && todoist list -f '#example': the project shows as #Example/My Section. ✅
  7. Move "Some task" out of "My Section", back to the "(No Section)" area.
  8. Run todoist sync && todoist list -f '#example': the project still shows as #Example/My Section. ❌
  9. The correct output is displayed with the show command.

In the details below: a (clean) transcript of my terminal output and some screenshots.

$ todoist sync && todoist list -f '#example'

$ todoist sync && todoist list -f '#example'
4693482710 p4  #Example  Some task

$ todoist sync && todoist list -f '#example'
4693482710 p4  #Example/My Section  Some task

$ todoist sync && todoist list -f '#example'
4693482710 p4  #Example/My Section  Some task

$ todoist sync && todoist show 4693482710
ID       4693482710
Content  Some task
Project  #Example
Labels
Priority p4
DueDate
URL

Screenshot 2021-03-26 at 19 55 12
Screenshot 2021-03-26 at 19 55 02
Screenshot 2021-03-26 at 19 54 47

@andreoliwa
Copy link
Contributor Author

I found out that removing the local cache is a temporary solution for this problem:

$ rm -rvf ~/.cache/todoist
/Users/aa/.cache/todoist/cache.json
/Users/aa/.cache/todoist

So maybe it's something related to loading or saving empty/null sections in the cache. 🤔

@dwrdx
Copy link
Contributor

dwrdx commented Mar 31, 2021

Yes, you are right about that, It's a bug that will happen when there are null sections. Pull request #162 is to solve this issue.

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

No branches or pull requests

2 participants