-
Notifications
You must be signed in to change notification settings - Fork 375
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
feat(gnomod): forbid require and find dependencies without it #3123
base: master
Are you sure you want to change the base?
Conversation
Signed-off-by: Norman Meier <norman@samourai.coop>
…ould be reverted) Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
Signed-off-by: Norman Meier <norman@samourai.coop>
|
||
res := ctypes.ResultABCIQuery{} | ||
|
||
finfo, err := os.Stat(target) |
Check failure
Code scanning / CodeQL
Incorrect conversion between integer types High
strconv.Atoi
Incorrect conversion of an integer with architecture-dependent bit size from
strconv.Atoi
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
wtf github
} | ||
|
||
if finfo.IsDir() { | ||
entries, err := os.ReadDir(target) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression
} | ||
res.Response.Data = []byte(strings.Join(files, "\n")) | ||
} else { | ||
content, err := os.ReadFile(target) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression
|
||
res := ctypes.ResultABCIQuery{} | ||
|
||
finfo, err := os.Stat(target) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression High
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
} | ||
|
||
if finfo.IsDir() { | ||
entries, err := os.ReadDir(target) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression High
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
} | ||
res.Response.Data = []byte(strings.Join(files, "\n")) | ||
} else { | ||
content, err := os.ReadFile(target) |
Check failure
Code scanning / CodeQL
Uncontrolled data used in path expression High
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
This path depends on a
user-provided value
Signed-off-by: Norman Meier <norman@samourai.coop>
@@ -35,6 +36,11 @@ func IsStdlib(s string) bool { | |||
return !strings.HasPrefix(s, "gno.land/") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For your information, this will become dynamic in #2911, which will be finished soon.
I recommend waiting for #2911 to be completed and merged before making any further hardcoded changes to the domain.
Edit: I believe it's fine; the potential conflict should be easy to resolve from any direction. There's no need to wait for #2911.
|
Signed-off-by: Norman Meier <norman@samourai.coop>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #3123 +/- ##
==========================================
- Coverage 63.80% 63.68% -0.13%
==========================================
Files 549 552 +3
Lines 78833 78748 -85
==========================================
- Hits 50301 50152 -149
- Misses 25143 25202 +59
- Partials 3389 3394 +5
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚨 Try these New Features:
|
seems some tests are failing after merging master, my bad, will fix asap |
Signed-off-by: Norman Meier <norman@samourai.coop>
fixed |
Signed-off-by: Norman Meier <norman@samourai.coop>
A step towards the importer package (#2932) and future of
gno.mod
(#2904)require
statement support fromgno.mod
.gno
filesimport
statements to find dependenciesgnovm/pkg/gnopkgfetch
gnovm/pkg/gnoimports
I decided to do this first to avoid having multiple ways to resolve dependencies lying around in the codebase and causing confusion in subsequent steps
Contributors' checklist...
BREAKING CHANGE: xxx
message was included in the description