hesstobi / atom-autocomplete-latex-cite

Autocomplete+ Support for Bibtex References in Latex
MIT License
4 stars 8 forks source link

I am also having this exact problem, on the most recent versions of atom and autocomplete-latex-cite: #25

Open mmmikemon opened 4 years ago

mmmikemon commented 4 years ago

I am also having this exact problem, on the most recent versions of atom and autocomplete-latex-cite:

Atom: 1.45.0 x64 Electron: 4.2.7 OS: Mac OS X 10.15.3 Thrown From: autocomplete-latex-cite package 0.3.5

Stack Trace

Failed to activate the autocomplete-latex-cite package

At Total of weights cannot exceed 1

Error: Total of weights cannot exceed 1
    at e.value (/packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:3409)
    at /packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:2634)
    at /packages/autocomplete-latex-cite/lib/cite-manager.coffee:41:13)
    at /packages/autocomplete-latex-cite/lib/cite-provider.coffee:12:16)
    at Object.provide (/packages/autocomplete-latex-cite/lib/main.coffee:21:19)
    at Package.activateServices (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:3224971)
    at Package.activateNow (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:3222013)
    at string.e.trim.length.activationHookSubscriptions.add.packageManager.onDidTriggerActivationHook (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:14:2607)
    at Function.simpleDispatch (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:1214120)
    at Emitter.emit (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:1215561)
    at PackageManager.triggerDeferredActivationHooks (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:382896)
    at activatePromise.Promise.all.then (/Applications/Atom.app/Contents/Resources/app/static/<embedded>:11:381647)

Commands

Non-Core Packages

advanced-open-file 0.16.8 
atom-beautify 0.33.4 
atom-python-run 0.9.7 
autocomplete-latex-cite 0.3.5 
busy-signal 2.0.1 
ex-mode 0.18.0 
Hydrogen 2.14.1 
hydrogen-python 0.0.8 
hydrogen-run 0.1.1 
ide-python 1.5.0 
intentions 1.1.5 
language-fortran 2.1.10 
language-latex 1.2.0 
latex 0.50.2 
linter 2.3.1 
linter-gfortran 1.0.0 
linter-spell 0.15.0 
linter-spell-latex 0.11.0 
linter-ui-default 1.8.1 
python-tools 0.6.9 
vim-mode-plus 1.36.4 
vim-mode-plus-macros 0.1.2 

Originally posted by @mmmikemon in https://github.com/hesstobi/atom-autocomplete-latex-cite/issues/19#issuecomment-602254639

chatox commented 4 years ago

Same issue here. I tried uninstalling autocomplete-bibtex and autocomplete-latex-cite reinstalling them again, problem is still there.

To reproduce:

  1. Open atom
  2. Open a .tex file

Atom: 1.29.0 x64 Electron: 2.0.5 OS: Ubuntu 18.04.4 Thrown From: autocomplete-latex-cite package 0.3.5

Stack Trace

Failed to activate the autocomplete-latex-cite package

At Total of weights cannot exceed 1

Error: Total of weights cannot exceed 1
    at e.value (/packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:3409)
    at /packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:2634)
    at /packages/autocomplete-latex-cite/lib/cite-manager.coffee:41:13)
    at /packages/autocomplete-latex-cite/lib/cite-provider.coffee:12:16)
    at Object.provide (/packages/autocomplete-latex-cite/lib/main.coffee:21:19)
    at Package.activateServices (/usr/share/atom/resources/app/src/package.js:394:73)
    at Package.activateNow (/usr/share/atom/resources/app/src/package.js:233:20)
    at activationHookSubscriptions.add.packageManager.onDidTriggerActivationHook (/usr/share/atom/resources/app/src/package.js:901:81)
    at Function.module.exports.Emitter.simpleDispatch (/usr/share/atom/resources/app/node_modules/event-kit/lib/emitter.js:27:20)
    at Emitter.module.exports.Emitter.emit (/usr/share/atom/resources/app/node_modules/event-kit/lib/emitter.js:156:34)
    at PackageManager.triggerActivationHook (/usr/share/atom/resources/app/src/package-manager.js:732:40)
    at Workspace.handleGrammarUsed (/usr/share/atom/resources/app/src/workspace.js:1285:38)
    at TextEditor.observeGrammar (/usr/share/atom/resources/app/src/text-editor.js:752:11)
    at onDidAddPaneItem (/usr/share/atom/resources/app/src/workspace.js:527:24)
    at Function.module.exports.Emitter.simpleDispatch (/usr/share/atom/resources/app/node_modules/event-kit/lib/emitter.js:27:20)
    at Emitter.module.exports.Emitter.emit (/usr/share/atom/resources/app/node_modules/event-kit/lib/emitter.js:156:34)
    at PaneContainer.didAddPaneItem (/usr/share/atom/resources/app/src/pane-container.js:271:24)
    at Pane.addItem (/usr/share/atom/resources/app/src/pane.js:640:48)
    at Pane.activateItem (/usr/share/atom/resources/app/src/pane.js:582:18)
    at Workspace.open (/usr/share/atom/resources/app/src/workspace.js:1063:20)
    at <anonymous>

Commands

Non-Core Packages

atom-xterm 6.5.0 
autocomplete-bibtex 1.2.7 
autocomplete-latex-cite 0.3.5 
autocomplete-latex-references 0.3.2 
autocomplete-paths 2.12.2 
busy-signal 2.0.1 
flex-tool-bar 2.2.0 
grammar-token-limit 0.1.1 
intentions 1.1.5 
language-latex 1.2.0 
latex 0.50.2 
latex-autocomplete 1.1.1 
linter 2.3.1 
linter-python 3.1.2 
linter-spell 0.15.0 
linter-spell-latex 0.11.0 
linter-ui-default 1.8.1 
minimap 4.29.9 
open-unsupported-files 1.0.20 
tool-bar 1.2.2 
vim-mode-plus 1.34.0 
wordcount 3.1.0 
chatox commented 4 years ago

After upgrading to Atom 1.45, still the same problem.

Atom: 1.45.0 x64 Electron: 4.2.7 OS: Ubuntu 18.04.4 Thrown From: autocomplete-latex-cite package 0.3.5

Stack Trace

Failed to activate the autocomplete-latex-cite package

At Total of weights cannot exceed 1

Error: Total of weights cannot exceed 1
    at e.value (/packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:3409)
    at /packages/autocomplete-bibtex/node_modules/fuse.js/dist/fuse.js:9:2634)
    at /packages/autocomplete-latex-cite/lib/cite-manager.coffee:53:19)
    at /packages/autocomplete-latex-cite/lib/cite-provider.coffee:18:22)
    at Object.provide (/packages/autocomplete-latex-cite/lib/main.coffee:23:25)
    at Package.activateServices (<embedded>:11:3222650)
    at Package.activateNow (<embedded>:11:3219692)
    at string.e.trim.length.activationHookSubscriptions.add.packageManager.onDidTriggerActivationHook (<embedded>:14:2607)
    at Function.simpleDispatch (<embedded>:11:1214120)
    at Emitter.emit (<embedded>:11:1215561)
    at PackageManager.triggerDeferredActivationHooks (<embedded>:11:382896)
    at activatePromise.Promise.all.then (<embedded>:11:381647)

Commands

Non-Core Packages

atom-xterm 6.5.0 
autocomplete-bibtex 1.2.7 
autocomplete-latex-cite 0.3.5 
autocomplete-latex-references 0.3.2 
autocomplete-paths 2.12.2 
busy-signal 2.0.1 
flex-tool-bar 2.2.0 
grammar-token-limit 0.1.1 
intentions 1.1.5 
language-latex 1.2.0 
latex 0.50.2 
latex-autocomplete 1.1.1 
linter 2.3.1 
linter-python 3.1.2 
linter-spell 0.15.0 
linter-spell-latex 0.11.0 
linter-ui-default 1.8.1 
minimap 4.29.9 
open-unsupported-files 1.0.20 
tool-bar 1.2.2 
vim-mode-plus 1.34.0 
wordcount 3.1.0 
naidoo88 commented 4 years ago

I am also experiencing this issue, on Centos7 and Ubuntu 18.04 LTS.

[Enter steps to reproduce:]

  1. ...
  2. ...

Atom: 1.46.0 x64 Electron: 4.2.7 OS: "CentOS Linux Thrown From: autocomplete-latex-cite package 0.3.5

Stack Trace

Failed to activate the autocomplete-latex-cite package

At Total of weights cannot exceed 1

Error: Total of weights cannot exceed 1
    at e.value (/packages/autocomplete-latex-references/node_modules/fuse.js/dist/fuse.js:9:3409)
    at /packages/autocomplete-latex-references/node_modules/fuse.js/dist/fuse.js:9:2634)
    at /packages/autocomplete-latex-cite/lib/cite-manager.coffee:41:13)
    at /packages/autocomplete-latex-cite/lib/cite-provider.coffee:12:16)
    at Object.provide (/packages/autocomplete-latex-cite/lib/main.coffee:21:19)
    at Package.activateServices (/usr/share/atom/resources/app/static/<embedded>:11:3186161)
    at Package.activateNow (/usr/share/atom/resources/app/static/<embedded>:11:3183203)
    at string.e.trim.length.activationHookSubscriptions.add.packageManager.onDidTriggerActivationHook (/usr/share/atom/resources/app/static/<embedded>:14:2607)
    at Function.simpleDispatch (/usr/share/atom/resources/app/static/<embedded>:11:1215907)
    at Emitter.emit (/usr/share/atom/resources/app/static/<embedded>:11:1217348)
    at deferredActivationHooks.triggeredActivationHooks.forEach.e (/usr/share/atom/resources/app/static/<embedded>:11:382990)
    at Set.forEach (<anonymous>)
    at PackageManager.activatePackage (/usr/share/atom/resources/app/static/<embedded>:11:382952)
    at /usr/share/atom/resources/app/static/<embedded>:11:943557
    at r (/usr/share/atom/resources/app/static/<embedded>:11:938163)
    at o (/usr/share/atom/resources/app/static/<embedded>:14:1122261)
    at e.bufferStream (/usr/share/atom/resources/app/static/<embedded>:14:1122349)
    at Socket.e.on (/usr/share/atom/resources/app/static/<embedded>:14:1121017)
    at Socket.emit (events.js:187:15)
    at Pipe._handle.close (net.js:606:12)

Commands

Non-Core Packages

atom-ide-terminal 5.0.1 
atom-material-syntax 1.0.8 
atom-material-ui 2.1.3 
autocomplete-clang 0.13.1 
autocomplete-latex 0.9.2 
autocomplete-latex-cite 0.3.5 
autocomplete-latex-references 0.3.2 
autocomplete-paths 2.12.2 
bracket-colorizer 1.4.0 
busy-signal 2.0.1 
file-icons 2.1.41 
hey-pane 1.2.0 
highlight-selected 0.17.0 
intentions 1.1.5 
language-latex 1.2.0 
latex 0.50.2 
latex-autocomplete 1.1.1 
linter 2.3.1 
linter-chktex 1.4.0 
linter-spell 0.15.0 
linter-spell-latex 0.11.0 
linter-ui-default 1.8.1 
monokai 0.24.0 
multi-cursor 3.0.0 
nucleus-dark-ui 0.12.3 
pdf-view 0.72.0 
pen-paper-coffee-syntax 0.17.0 
Sublime-Style-Column-Selection 1.7.5 
maurice-schleussinger commented 4 years ago

This project seems inactive. https://github.com/mayhewsw/atom-autocomplete-latex-cite works for me.

hesstobi commented 4 years ago

Sorry I'm currently really busy with other work and not using atom currently. It is an issue with the fuse library. If someone can prepare an PR i will release a new version.

maurice-schleussinger commented 4 years ago

No worries! My link is actually a PR for this repo if I’m not mistaken.

du-a-new commented 3 years ago

@maurice-schleussinger you have linked a fork not a PR, but it does work for me as well. Maybe you could add a PR for @hesstobi ? As is, Atom wants to update to the current version, which does not work correctly.

xavoh commented 3 years ago

Normalising the weights to 1 in autocomplete-latex-cite/lib/cite-manager.coffee fixes this for me. I've added a pull request: https://github.com/hesstobi/atom-autocomplete-latex-cite/pull/27

Asphod commented 3 years ago

@xavoh I implemented your fix and it also works for me. Very nice to have that feature now! Thank you

To be more precise, I don't know the syntax of .coffee files so I did it "the ugly way"


keys: [{
        "name": "title",
        "weight": 0.3/(0.3+0.6+0.6+0.1)
    },   
    {
        "name": "author.family",
        "weight": 0.6/(0.3+0.6+0.6+0.1)
    },
    {
        "name": "author.given",
        "weight": 0.6/(0.3+0.6+0.6+0.1)
    },
    {
        "name": "id",
        "weight": 0.1/(0.3+0.6+0.6+0.1)
    }]```
unitedtimdom commented 2 years ago

@xavoh fix works for me as well. Thank you!

maybemkl commented 2 years ago

tried the fixes by @xavoh and @Asphod but still getting the same error. anyone else experiencing this?

gabrielarpino commented 2 years ago

@xavoh 's fix worked for me! thanks.

xavoh commented 2 years ago

Hi Gabriel, Have you tried my fix? best wishes

On Thu, 4 Aug 2022, 16:51 Gabriel Arpino, @.***> wrote:

Also experiencing this, so far have not found a solution.

— Reply to this email directly, view it on GitHub https://github.com/hesstobi/atom-autocomplete-latex-cite/issues/25#issuecomment-1205439931, or unsubscribe https://github.com/notifications/unsubscribe-auth/AIZ6ZUFOG3TURZEO747UVKDVXPRINANCNFSM4LRMTBLQ . You are receiving this because you were mentioned.Message ID: @.***>