-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Errors should be "click on-able" #170
Comments
I have a proposal for a solution in there: #196 I struggled a little to find a way to avoid any duplicated code, to be able to act at one point only. But the only way that gave me some results is from my PR: by passing the original path from a I did it for the cli deployments script, but if it is an accepted solution, I can do the others. (I'll try to do them later) Also, not really satisfied by the fact that it can duplicate the console output (one with the original and the temp), since traceback is immutable, apparently. EDIT: I reworked what I did so... Let's see if it fits the requirements! |
Thanks for working on this! It looks like there is actually a lot of good stuff we can use in this PR! Some nice reworking of these tests - they were pretty messy and this is a nice clean up. I'm struggling to see how this fixing the issue though? I'm a bit upset I didn't give enough direction on this :( What the issue is trying to solve, is that when you run something like:
And you get an error, the error is "clickable" meaning you can What do you think? I feel like we should merge in your refactor where you clean up the architecture, but keep the issue open with more details? |
Yeah my bad on this, I jumped into my assumptions that it was related to We can add what I have done as a refacto, but I think I'll remove the I'll try to add I think I'll close this PR #196 and cleanup the commit history from the wip and reworks. It will be nicer to arrange this in one clean commit. Also renaming the branch will be better I think... Then I will come up with a solution for this issue specifically! 👍
|
On my Linux, I still have the clear path of the error after vyper.exceptions.StructureException: Expressions without assignment are disallowed
(hint: did you mean to assign the result to a variable?)
contract "/home/<PATH>/my_project/src/Counter.vy:9", function "set_number", line 9:4
8 self.number = new_number
---> 9 hello
-----------^
10 It opens the right file, but maybe there is a specific way to trigger this... 🤔 |
When you CTRL + Click this line |
Yes, I can get the exact path of the file and when vyper.exceptions.StructureException: Expressions without assignment are disallowed
(hint: did you mean to assign the result to a variable?)
contract "<MY_HOME_PATH>/mox-cu/mox-fav-cu/src/favorites.vy:32", function "store", line 32:4
31 self.my_favorite_number = favorite_number
---> 32 Bad
------------^
33 # log Transfer() But it depends on the error, I tried yours from your screenshot with a event Transfer:
sender: indexed(address)
to: indexed(address)
value: uint256
@external
def store(favorite_number: uint256):
self.my_favorite_number = favorite_number
# Bad
log Transfer() vyper.exceptions.ArgumentException: Invalid argument count for call to 'Transfer': expected 3, got 0
contract "<MY_HOME_PATH>/mox-cu/mox-fav-cu/src/favorites.vy:33", function "store", line 33:8
32 # Bad
---> 33 log Transfer()
----------------^
34 It opens on the exact line, but with a syntax exception: event Transfer:
from: indexed(address) #--> here is the error
to: indexed(address)
value: uint256 vyper.exceptions.SyntaxException: invalid syntax (<unknown>, line 19)
line 19:9
18 event Transfer:
---> 19 from: indexed(address)
-----------------^
20 to: indexed(address) I do not have the path. But I always have the traceback from my home folder, not from the Linux ## macOS:
**System-Wide Temporary Directories:**
- /tmp (linked to /private/tmp): This directory is accessible system-wide and is typically cleared upon system reboot. Additionally, macOS includes maintenance scripts that periodically clean up this directory.
-/var/tmp (linked to /private/var/tmp): Unlike /tmp, this directory is intended for temporary files that need to persist across reboots. It is not cleared automatically upon reboot and retains its contents for longer periods.
APPLE.STACKEXCHANGE.COM
**User-Specific Temporary Directory:**
- $TMPDIR: This environment variable points to a user-specific temporary directory, typically located at /var/folders/.../T/. Files in this directory are usually cleared upon reboot, and macOS may also perform periodic cleanups to remove stale files.
---
## Linux:
**System-Wide Temporary Directories:**
- /tmp: This directory is used for temporary files needed during system operation. It is often cleared upon system reboot, and some systems may mount /tmp as a tmpfs (RAM-based filesystem), meaning its contents are stored in volatile memory.
- /var/tmp: This directory is intended for temporary files that should persist across reboots. It is generally not cleared automatically upon reboot and is used for files that need to remain available for a longer duration. |
Putting them in a temp folder makes it difficult to view them in my text editor.
The text was updated successfully, but these errors were encountered: