From the to-do list: MPA V1.0: Older issues and tasks
✔ Sound library: Add import files modal window and functionalities
(Completed by Pierre henri Seylan on May 28, 2018)
Comments
Pierre henri Seylan on January 10, 2018:
In Daniel's branch, a modal window has been created for importing files. This should allow to simplify the files import into the app, by offering the following options when importing files:
add to collection
add to folder
create new collection
create new folder
1. General:
1.1 Displaying the window: The modal window should appear when files are being imported to the sound library via drag and drop, for the following cases:
Imported to the personal section
It should not appear when files are imported directly to a folder's detail page.
1.2 Limitations: The options are not mandatory, if the user clicks "Continue" or closes the window without selecting any options, the files are imported normally...
1.3 Progress display: On the top of the window, the sync icon is displayed along with a line "importing X files"
Let's make the sync icon to spin while the files are being imported.
The number of files being imported should be displayed in the description. The import step is encompassing both local registration and upload. If uploads are deactivated, the sync icon should stop spinning once all the files are registered locally.
2. Details for each options:
2.1 add to a folder or collection In the dropdown list, all user's folders and collections should be displayed. The user can select either a folder or a collection, which allows to add the files to the selected folder/collection directly during the import.
2.2 create new collection When clicking this option, the "create new collection" modal window should be opened (and replace the files import window)
If the user creates a new collection, the imported files should be added to this collection once created.
2.3 create new folder Similar to the collection option, this option opens the "new folder" modal window when being clicked.
If the user creates a new folder, the imported files should be moved to this folder once created.
Pierre henri Seylan on February 15, 2018:
Feedback 1:
This is some initial feedback for this task, because of some crashes it is currently hard to test.
1. Import to first level of sound library. (done)
When importing files and not selecting any of the proposed options (import to collection ect) and clicking the "continue button", an error message appears, asking to select a folder or a collection.
When no options are selected, the files should be added to the first level of the sound library, like the previous behavior when doing a simple drag and drop.
2. Crash when adding files and folders: When importing files, a crash occurs often right after that the modal window is being displayed.
This has happened when trying to import a folder, but also when trying to import some files.
3. Message when import is completed: (done) When the import is completed and the modal window is still visible, the status of the import should be updated, the "in progress" should be replaced by "completed" It should display "Import of X files completed"
4. Collections not appearing after creation: This issue had been fixed before but has appeared again. When creating a new collection, the collection doesn't appear in the side menu and personal section unless the app is restarted.
NOTE: When creating packs, the pack is displayed right after the creation, without needing to restart the app. I think this is related to the issue 5 described below.
5.Corrupted collections: You have recently mentioned that the server doesn't let you create collections anymore. I think i have a similar issue. Now when creating new collections, i can't add datas to it, when clicking on the collection to show the details page, the spinning wheel keeps spinning, so that no datas are displayed but it also doesn't mention that the collection is empty.
This makes it hard to test the implementation of this task. However, i'm not sure that this is a server bug since it used to work well before, and the issue has appeared only recently when working on this task. Can you double check to see if the problem doesn't come form the app side?
One hint, it seems that the datas created is actually a pack and not a collection (or a pack created with an incorrect method) This is visible because the header for collections is different than the one for packs, but for those "corrupted" collections, it actually displays the pack's header. Also, as mentioned in point 4, the collections are not appearing after the creation, while packs appear correctly.
Pack's header:
Collections header:
Karim Alabtakh on February 23, 2018:
1- about problem with collection:
I checked the commit history and I a have detected that “IsVisible” was removed, so collections is created as invisible by default which case premises error. (55639ee Thanapong on 1/15/18 at 9:02 AM ). in this case server return {“error”:true,“errorDescription”:“Don’t have rights.“}
2- about crashes:
I tested it hard, and I am unable to get any crashes. so I will send you a build in debug mode to test and give me please the crash reports.
Pierre henri Seylan on February 23, 2018:
Feedback 2:
It looks like all issues of the previous feedback are fixed. There is only 2 problems left when adding files to a new collection:
1. Import to a new collection: When selecting the option "create new collection", the files are not added to this collection after the import is completed. The collection remains empty. However, when manually adding files to this collection, they are added correctly.
2. Imports for local mode: If the uploads are deactivated and the user is working only in local mode, it seems that the import functionalities are not active. I have tested only the case of "import to existing" collection:
The uploads were de-activated and i have imported files closing the option "import to existing collection" The files have not been added to the collection.
Pierre henri Seylan on February 25, 2018:
Feedback 3:
After testing the latest build, an issue is remaining for the local files.
1. Import to new collection in local mode: If uploads are deactivated and the user selects "create new collection", the files are not being imported to the collection.
2. Import to existing folder in local mode: If uploads are deactivated and the user selects an existing folder, the files are not being imported to the folder.
Test cases: Online:
import to new collection (working)
import to existing collection (working)
import to new folder (working)
import to existing folder (working)
Offline:
import to new collection (to fix)
import to existing collection (working)
import to new folder (working)
import to existing folder (working)
Pierre henri Seylan on April 22, 2018:
In the recent build, most of the functionalities related to importing files are broken. I have not tested all of them again since there is clearly an issue, and hopefully all problems will be fixed at once when we find the root of the issue.
Below is a list of issues noticed so far:
1. Collection not created and files not added: When the option "create new collection" is selected, the collection is not created and the files not imported.
3. Dropdown list crash: Not a pack/collection functionality, but maybe related. When clicking the sorting dropdown list in any page of the sound library, only the "name" option can be selected. When clicking on this option, the app crashes. https://www.dropbox.com/s/0ijqz7j0sbswbsl/MPA%20dropdown%20list%20crash.rtf?dl=0
4. Files not uploaded after restart: After the crash mentioned in point 2, i have restarted the app, but the remains files not uploaded before the crash have not been uploaded after the restart.
5. Import sequence: When importing files to a collection, it now first upload the files before displaying them in the collection. It seems that we had implemented it so that the files are first imported locally (and displayed), and then progressively uploaded
6. Files outside folders: When importing folders to collections, the files are displayed in a plain list inside the collection, but also inside the folders in the collection. So they are actually appearing twice in the collection, both as plain files and inside the folders.
Karim Alabtakh on April 26, 2018:
Actually some of issues was exist also in old builds. 1. After a lot of tests I could not get this issue( 2. I have got crashes 2 times, when opening packs and folder detail pages it's related to last navbar changes by Vitaly on 17.4.2018. also navbar become broken when opening packs then folders. so let me know if Vitaly will fix this bugs, or I should should do that? 3. This bug related to my last changes for popup menu which produce incompatible behavior, I have refactored and fixed it. 4. the files can be uploaded only if exist in the local db. so please provide me more info with local db if you get this problem again. 5. This functionality was not implemented before (I mean display in packs view), so it's not a bug. Done 6. Fixed
Pierre henri Seylan on April 27, 2018:
Additional feedback.
1. Collection not created and files not added: The collections are now created but the files not always added. It seems that this happens only for files i have tried to add to the sound library before, but which have not been properly registered because of a crash or another issue.
Is it possible that the local DB is corrupted because of failed imports, which leads to not import the files properly when trying again with the same files?
Another way to test:
Import some files to the library
Import those files again and select add to a new collection
The files will not be added to the new collection, so when files are already present in the library and re-imported, they are not being added to the wished collection. This behavior would be needed as when importing many files it can often fails, so the imports can be done iteratively
4. Duplicated collections: The new collections i c create are being duplicated. This is noticeable when restarting the app.
To test you can try those steps:
create some collections
close and re-open the app
You might find your most recent collections duplicated The duplicate version is corrupt and doesn't contain files, i couldn't delete them neither, they are disappearing but re-appear when restarting the app
5. Tagging offline sounds: I have deactivated the uploads and created an offline collection (importing new files) It worked well, but when tagging the files of the collection, i've received a "media library error" notification. The tagging has worked correctly, but the error notification is probably just a glitch. Something like it is sending a server request to tag sounds which are only local.
Pierre henri Seylan on May 11, 2018:
All the issues mentioned above are fixed
Pierre henri Seylan on May 12, 2018:
After testing, it seems that one issue is remaining.
The collections are still being duplicated, this is now visible when restarting the app.
You can test following those steps:
Create a new collection (preferably by importing files)
Verify that the collection is present only once (it should be the case)
Comments
Pierre henri Seylan on January 10, 2018:
This should allow to simplify the files import into the app, by offering the following options when importing files:
1. General:
1.1 Displaying the window:
The modal window should appear when files are being imported to the sound library via drag and drop, for the following cases:
It should not appear when files are imported directly to a folder's detail page.
1.2 Limitations:
The options are not mandatory, if the user clicks "Continue" or closes the window without selecting any options, the files are imported normally...
1.3 Progress display:
On the top of the window, the sync icon is displayed along with a line "importing X files"
Let's make the sync icon to spin while the files are being imported.
The number of files being imported should be displayed in the description.
The import step is encompassing both local registration and upload.
If uploads are deactivated, the sync icon should stop spinning once all the files are registered locally.
2. Details for each options:
2.1 add to a folder or collection
In the dropdown list, all user's folders and collections should be displayed.
The user can select either a folder or a collection, which allows to add the files to the selected folder/collection directly during the import.
2.2 create new collection
When clicking this option, the "create new collection" modal window should be opened (and replace the files import window)
If the user creates a new collection, the imported files should be added to this collection once created.
2.3 create new folder
Similar to the collection option, this option opens the "new folder" modal window when being clicked.
If the user creates a new folder, the imported files should be moved to this folder once created.
Pierre henri Seylan on February 15, 2018:
This is some initial feedback for this task, because of some crashes it is currently hard to test.
1. Import to first level of sound library. (done)
When importing files and not selecting any of the proposed options (import to collection ect) and clicking the "continue button", an error message appears, asking to select a folder or a collection.
When no options are selected, the files should be added to the first level of the sound library, like the previous behavior when doing a simple drag and drop.
2. Crash when adding files and folders:
When importing files, a crash occurs often right after that the modal window is being displayed.
This has happened when trying to import a folder, but also when trying to import some files.
3. Message when import is completed: (done)
When the import is completed and the modal window is still visible, the status of the import should be updated, the "in progress" should be replaced by "completed"
It should display "Import of X files completed"
4. Collections not appearing after creation:
This issue had been fixed before but has appeared again.
When creating a new collection, the collection doesn't appear in the side menu and personal section unless the app is restarted.
NOTE: When creating packs, the pack is displayed right after the creation, without needing to restart the app.
I think this is related to the issue 5 described below.
5.Corrupted collections:
You have recently mentioned that the server doesn't let you create collections anymore.
I think i have a similar issue.
Now when creating new collections, i can't add datas to it, when clicking on the collection to show the details page, the spinning wheel keeps spinning, so that no datas are displayed but it also doesn't mention that the collection is empty.
This makes it hard to test the implementation of this task.
However, i'm not sure that this is a server bug since it used to work well before, and the issue has appeared only recently when working on this task.
Can you double check to see if the problem doesn't come form the app side?
One hint, it seems that the datas created is actually a pack and not a collection (or a pack created with an incorrect method)
This is visible because the header for collections is different than the one for packs, but for those "corrupted" collections, it actually displays the pack's header.
Also, as mentioned in point 4, the collections are not appearing after the creation, while packs appear correctly.
Pack's header:
Collections header:
Karim Alabtakh on February 23, 2018:
1- about problem with collection:
I checked the commit history and I a have detected that “IsVisible” was removed, so collections is created as invisible by default which case premises error. (55639ee Thanapong on 1/15/18 at 9:02 AM ). in this case server return {“error”:true,“errorDescription”:“Don’t have rights.“}
2- about crashes:
I tested it hard, and I am unable to get any crashes. so I will send you a build in debug mode to test and give me please the crash reports.
Pierre henri Seylan on February 23, 2018:
It looks like all issues of the previous feedback are fixed.
There is only 2 problems left when adding files to a new collection:
1. Import to a new collection:
When selecting the option "create new collection", the files are not added to this collection after the import is completed.
The collection remains empty.
However, when manually adding files to this collection, they are added correctly.
2. Imports for local mode:
If the uploads are deactivated and the user is working only in local mode, it seems that the import functionalities are not active.
I have tested only the case of "import to existing" collection:
The uploads were de-activated and i have imported files closing the option "import to existing collection"
The files have not been added to the collection.
Pierre henri Seylan on February 25, 2018:
After testing the latest build, an issue is remaining for the local files.
1. Import to new collection in local mode:
If uploads are deactivated and the user selects "create new collection", the files are not being imported to the collection.
2. Import to existing folder in local mode:
If uploads are deactivated and the user selects an existing folder, the files are not being imported to the folder.
Test cases:
Online:
Offline:
Pierre henri Seylan on April 22, 2018:
I have not tested all of them again since there is clearly an issue, and hopefully all problems will be fixed at once when we find the root of the issue.
Below is a list of issues noticed so far:
1. Collection not created and files not added:
When the option "create new collection" is selected, the collection is not created and the files not imported.
2. Folders page crash:
While some files were uploading, i have opened the detail page of the folder being uploaded, the app has crashed.
There was other crashes, but i guess they are all related to the same issue.
https://www.dropbox.com/s/fl63s0oyyhng8ou/MPA%20crash%20opening%20folder%20during%20upload%20.rtf?dl=0
3. Dropdown list crash:
Not a pack/collection functionality, but maybe related.
When clicking the sorting dropdown list in any page of the sound library, only the "name" option can be selected.
When clicking on this option, the app crashes.
https://www.dropbox.com/s/0ijqz7j0sbswbsl/MPA%20dropdown%20list%20crash.rtf?dl=0
4. Files not uploaded after restart:
After the crash mentioned in point 2, i have restarted the app, but the remains files not uploaded before the crash have not been uploaded after the restart.
5. Import sequence:
When importing files to a collection, it now first upload the files before displaying them in the collection.
It seems that we had implemented it so that the files are first imported locally (and displayed), and then progressively uploaded
6. Files outside folders:
When importing folders to collections, the files are displayed in a plain list inside the collection, but also inside the folders in the collection.
So they are actually appearing twice in the collection, both as plain files and inside the folders.
Karim Alabtakh on April 26, 2018:
1. After a lot of tests I could not get this issue(
2. I have got crashes 2 times, when opening packs and folder detail pages it's related to last navbar changes by Vitaly on 17.4.2018. also navbar become broken when opening packs then folders. so let me know if Vitaly will fix this bugs, or I should should do that?
3. This bug related to my last changes for popup menu which produce incompatible behavior, I have refactored and fixed it.
4. the files can be uploaded only if exist in the local db. so please provide me more info with local db if you get this problem again.
5. This functionality was not implemented before (I mean display in packs view), so it's not a bug. Done
6. Fixed
Pierre henri Seylan on April 27, 2018:
1. Collection not created and files not added:
The collections are now created but the files not always added.
It seems that this happens only for files i have tried to add to the sound library before, but which have not been properly registered because of a crash or another issue.
Is it possible that the local DB is corrupted because of failed imports, which leads to not import the files properly when trying again with the same files?
Another way to test:
- Import some files to the library
- Import those files again and select add to a new collection
The files will not be added to the new collection, so when files are already present in the library and re-imported, they are not being added to the wished collection.This behavior would be needed as when importing many files it can often fails, so the imports can be done iteratively
2. Crash when importing files:
I've tried to import files and got some crashes.
This doesn't happen all the time
The second crash has occurred while the file import panel was opened, the files had all been imported locally and then it has crashed.
https://www.dropbox.com/s/li10u6xluqc89wn/MPA%20crash%20importing%20files.rtf?dl=0
https://www.dropbox.com/s/pi2x7zk5aefev15/MPA%20crash%20importing%20files%202.rtf?dl=0
3. Crash opening packs:
Mostly after having uploaded some files, i get a crash when opening a factory library pack.
This doesn't seems to be related to the header/folder issue, but more to some threads conflicts.
https://www.dropbox.com/s/et08an91xfcvb22/MPA%20crash%20opening%20pack.rtf?dl=0
4. Duplicated collections:
The new collections i c create are being duplicated.
This is noticeable when restarting the app.
To test you can try those steps:
- create some collections
- close and re-open the app
You might find your most recent collections duplicatedThe duplicate version is corrupt and doesn't contain files, i couldn't delete them neither, they are disappearing but re-appear when restarting the app
5. Tagging offline sounds:
I have deactivated the uploads and created an offline collection (importing new files)
It worked well, but when tagging the files of the collection, i've received a "media library error" notification.
The tagging has worked correctly, but the error notification is probably just a glitch.
Something like it is sending a server request to tag sounds which are only local.
Pierre henri Seylan on May 11, 2018:
Pierre henri Seylan on May 12, 2018:
The collections are still being duplicated, this is now visible when restarting the app.
You can test following those steps: