Skip to content

custom.js not recognised unless graph is unlinked and re-added #10270

@adxsoft

Description

@adxsoft

Search first

  • I searched and no similar issues were found

What Happened?

I have an existing graph which has a custom.js script that was executed without any issues on previous versions of Logseq. After upgrading to 0.9.15 it was not being recognised by Logseq until I unlinked the graph and then re-added it. When I re-added the graph I got the warning tip as expected. Now the custom.js is working again.

Logseq seems to 'forget' the the custom.js exists and re-adding the graph makes it aware of the custom.js existence.

Previously the warning about custom.js always occurred any time the graph was opened now it seems it only occurs ONCE at the initial load of a graph and not on subsequent opens. So I think the warning functionality is where the custom.js is recognised and not the open graph functionality

Same behaviour is occurring on Android Mobile 0.9.10. Unlink and re-add graph workaround was successful on mobile and Desktop

Note the custom.js permissions are 777

Reproduce the Bug

Only easy I can think of recreating is test with an old graph that has a custom.js in ./logseq folder

Expected Behavior

Opening a graph should detect a custom.js automatically if it has answered the initial load of the graph previously

Screenshots

No response

Desktop or Mobile Platform Information

OSX 10.13.6 logseq 0.9.15

Android 12 pixel 5 logseq 0.9.10

Additional Context

No response

Are you willing to submit a PR? If you know how to fix the bug.

  • I'm willing to submit a PR (Thank you!)

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions