Skip to content

Unable to create/ignore a term longer than the parsed by MeCab #34

Closed

Description

@rc-ops

Extracted from #31

  • When reading imported text, if I select I KNOW ALL, a message appears asking if I'm sure, even though I am, it doesn't save any terms.
  • If I click on any words, the sidebar to create a new term doesn't appear.
  • The buttons marked in red don't work.

4

Desktop (please complete the following information):

  • Same setup as last time, except this time Chromium has another version
  • OS: Windows 11 21H2 and Windows 10 20H2
  • Browser: Chromium 101.0.4951.64
  • EasyPHPDevserver-17 PHP 7.1.3

Activity

  1. added
    bugSomething isn't working
    uiAny problem related to the User Interface
    uxUser Experience could be better
    and removed
    uiAny problem related to the User Interface
    on May 31, 2022
  2. HugoFara commented on May 31, 2022

    @HugoFara
    Owner

    After some tests, I think that the problem may be a bit different. Clicking "I KNOW ALL" should work, but to see it you have to manually reload the page. This is a UX problem as things may be better, but hopefully not something really annoying.

    For the sidebar and the "Read in browser" button, I think that your JavaScript is disabled for local files. A lot of functionalities won't work then so try enabling it in your browser settings (Settings → Privacy and Security → Site Settings → JavaScript). Hope it solves your problem ;)

  3. rc-ops commented on May 31, 2022

    @rc-ops
    Author

    Hi!
    So after removing everything related to LWT, truncating the database (which I did before upgrading) and restarting EasyPHP in the process, I checked my browser console log, turns out it wasn't a javascript problem, which didn't make sense since I had been developing some JS stuff this week. Apparently ublock was blocking some 3rd party website, in this case jisho.org and google's tracking triggered by it. That's strange, because I hadn't problems with it before.
    Apparently it also closes #32
    Sorry. I should've tested it with a clean browser! :P

  4. rc-ops commented on May 31, 2022

    @rc-ops
    Author

    Ok... I'm still having problems saving/ignoring some terms

    New Term: さかまきいざよい
    Fatal Error in SQL Query: SELECT WoID, WoTextLC FROM words WHERE WoLgID in(@m) AND WoWordCount = 0 into outfile 'C:\\Users\\USER\\AppData\\Local\\Temp\\db_440E.tmp'
    
    Error Code & Message: [1290] The MySQL server is running with the --secure-file-priv option so it cannot execute this statement
    
    Backtrace:
    
    #0  do_mysqli_query(SELECT WoID, WoTextLC FROM words 
                WHERE WoLgID in(@m) AND WoWordCount = 0 
                into outfile 'C:\\Users\\USER\\AppData\\Local\\Temp\\db_440E.tmp') called at [C:\Program Files (x86)\EasyPHP-Devserver-17\eds-www\lwt\inc\database_connect.php:585]
    #1  set_word_count() called at [C:\Program Files (x86)\EasyPHP-Devserver-17\eds-www\lwt\edit_mword.php:53]
    

    chrome_sYfUdQWnyy

    • I can sometimes trigger this error by doing:
    1. Go to some other LWT page
    2. Open the text to read
    3. Look for a word that is longer than the parsed by MeCab
    4. Click and drag from the beginning to the end of the word, like mentioned in Phrase select broken? #21,
    5. Select any word status and Save the term.

    If I delete the saved term I can trigger it again.

    • It gets trigged whenever I try to create a term longer than the parsed by MeCab. In this case Mecab parsed |さ|か|ま|き| い|ざ|よ|い| so if I wanted to create/ignore the word as a whole, it throws an error. Also if I tried to create a word from 逆廻十六夜, which got parsed as |逆|廻|十|六|夜|, same thing happens.

    (逆廻十六夜(さかまき いざよい))
    何か面白いことねえかなあ

    • Another example with 佐藤和真, Mecab parses the word as |佐|藤|和|真|
                佐藤和真(さとうかずま)さん            
    
    New Term: 佐藤和真
    Fatal Error in SQL Query: SELECT WoID, WoTextLC FROM words WHERE WoLgID in(@m) AND WoWordCount = 0 into outfile 'C:\\Users\\USER\\AppData\\Local\\Temp\\db_750.tmp'
    
    Error Code & Message: [1290] The MySQL server is running with the --secure-file-priv option so it cannot execute this statement
    
    Backtrace:
    
    #0  do_mysqli_query(SELECT WoID, WoTextLC FROM words 
                WHERE WoLgID in(@m) AND WoWordCount = 0 
                into outfile 'C:\\Users\\USER\\AppData\\Local\\Temp\\db_750.tmp') called at [C:\Program Files (x86)\EasyPHP-Devserver-17\eds-www\lwt\inc\database_connect.php:585]
    #1  set_word_count() called at [C:\Program Files (x86)\EasyPHP-Devserver-17\eds-www\lwt\edit_mword.php:53]
    
  5. reopened this on May 31, 2022
  6. changed the title [-]Unable to mark all terms as known or create new terms[/-] [+]Unable to create term inside specific sentences[/+] on May 31, 2022
  7. changed the title [-]Unable to create term inside specific sentences[/-] [+]Unable to create/ignore a term longer than the parsed by MeCab[/+] on May 31, 2022
  8. rc-ops commented on May 31, 2022

    @rc-ops
    Author

    Ok. I was able to fix the above error by editing mysql config.

    [mysqld]
    secure-file-priv = ""
    
    • It's able to create the term without errors, but it doesn't seem to get updated
      image
    • Here for instance I've created the term 不幸にも, but it still appears blue instead of concatenating the characters and changing color
  9. HugoFara commented on Jun 9, 2022

    @HugoFara
    Owner

    I was able to fix your issue with version 2.4.1, saving the file in the SQL folder instead of the server's "temp" directory, so that the "secure-file-priv" flag should no longer be necessary. For the markup referenced in #21, it is a broader issue, still being investigated, any help would be appreciated!

    I'm closing this issue as the problem specific to Japanese is fixed, but I'm aware that things still need a patch...

  10. added 2 commits that reference this issue on Jun 13, 2022
    b40b889
    8279b60
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinguxUser Experience could be better

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions