# Red Squiggles under imported modules for separated trigger

**URL:** <https://forum.canton.network/t/red-squiggles-under-imported-modules-for-separated-trigger/4276>\
**Category:** App Development\
**Tags:** trigger, damlhub\
**Created:** [April 8, 2022, 2:51am UTC](https://forum.canton.network/t/red-squiggles-under-imported-modules-for-separated-trigger/4276 "2022-04-08T02:51:19Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Max](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/max/32/2128_2.png) [@Max](https://forum.canton.network/u/Max)\
**Post date:** [April 8, 2022, 2:51am UTC](https://forum.canton.network/t/red-squiggles-under-imported-modules-for-separated-trigger/4276/1 "2022-04-08T02:51:19Z")

</div>

My directory structure now looks like

```haskell
- wallet-refapp (parent)
   - triggers (daml project)
      - daml
       - Trigger.daml
   - wallet (daml project)
      - daml
       - Asset.daml

```

![Screenshot 2022-04-07 at 7.43.49 PM](https://canada1.discourse-cdn.com/flex028/uploads/daml/original/2X/9/942e93cdc6e2a7d6284ea40361ff68cff399b1f1.png)

1. to run the trigger locally, do I need to be in the trigger directory, and run

```haskell
daml trigger --dar .daml/dist/triggers-0.0.1.dar \
             --trigger-name Trigger:autoSendExampleAssetAccountProposal \
             --ledger-host localhost \
             --ledger-port 6865 \
             --ledger-party "a"

```

I get the error message

```haskell
Exception in thread "main" com.daml.lf.archive.Error$IO: IO error: java.io.FileNotFoundException: .daml/dist/triggers-0.0.1.dar (No such file or directory)

```

However, I do have the file, I’m able to build everything, and upload everything onto Daml hub though.  
 ![Screenshot 2022-04-07 at 7.50.46 PM](https://canada1.discourse-cdn.com/flex028/uploads/daml/original/2X/f/fa9a20e8a58ef0fe79b55aa92711b44851730a05.png)

---

<div class="post-metadata">

**Author:** ![Max](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/max/32/2128_2.png) [@Max](https://forum.canton.network/u/Max)\
**Post date:** [April 8, 2022, 6:05am UTC](https://forum.canton.network/t/red-squiggles-under-imported-modules-for-separated-trigger/4276/2 "2022-04-08T06:05:44Z")

</div>

Resolved, I think. Red lines are still there, but I can run the trigger locally now.  
Not entirely sure what fixed it, but following steps in

> <https://github.com/digital-asset/daml/issues/5455>
>
> To reproduce:
> 
> \`\`\`
> mkdir /tmp/foo && cd /tmp/foo
> daml new bar
> code .
> \`\`\`
> …
> Then open either of the \`.daml\` files inside \`bar\`. The whole file is underlined red, and the error shown is
> 
> \`\`\`
> \<command line\>: cannot satisfy --package daml-script-0.0.1
> (use -v for more information)
> \`\`\`
> 
> \<!--
> 
> This issue tracker is only for technical issues related to the DAML SDK.
> 
> If you suspect that your issue has a security impact, do not use this issue tracker. In that case, please contact security@digitalasset.com and follow our responsible disclosure policy: https://digitalasset.com/security/ .
> 
> For general questions about DAML and/or support request you should use Stack Overflow: https://stackoverflow.com/questions/tagged/daml .
> 
> \--\>

I didn’t have a daml.yaml file in my root. Added that.  
`daml build` for each daml project, then `daml studio`

---

<div class="post-metadata">

**Author:** ![cocreature](https://yyz2.discourse-cdn.com/flex034/user_avatar/forum.canton.network/cocreature/32/36_2.png) [@cocreature](https://forum.canton.network/u/cocreature)\
**Post date:** [April 8, 2022, 6:44am UTC](https://forum.canton.network/t/red-squiggles-under-imported-modules-for-separated-trigger/4276/3 "2022-04-08T06:44:33Z")

</div>

For the red lines, that’s the right fix but it should be completely unrelated to the trigger issue. My only guess there is that maybe you started `daml trigger` from the root directory rather than the `triggers` directory.
